Issue 2308 Changes aren't listed when using amend --edit

Title Changes aren't listed when using amend --edit
Priority Status unknown
Milestone Resolved in 2.12.0
Superseder Nosy List owst
Assigned To

Created on 2013-02-28.17:45:37 by owst, last changed 2015-06-22.19:51:25 by bf.

msg16729 (view) Author: owst Date: 2013-02-28.17:45:36
1. Summarise the issue (what were doing, what went wrong?)

When amending a patch's message with amend --edit, there's a line that
says "This patch contains the following changes:" but the changes aren't

2. What behaviour were you expecting instead?

The changes to be listed.

3. What darcs version are you using? (Try: darcs --exact-version)


4. What operating system are you running?

Linux X86_64
msg16731 (view) Author: owst Date: 2013-02-28.17:48:25
I've just sent a patch accepting this issue.
msg18555 (view) Author: bf Date: 2015-06-18.18:29:19
I have been thinking about this. I believe what darcs does here is
correct: What is listed are the the differences between what the patch
already contains and what it should contain. This is consistent with how
darcs behaves in other scenarios and I think it would be wrong to "fix"

All that needs fixing is that it says "This patch contains the following
changes:" which is misleading in case of amend. Instead it should say
"The following changes will be added to the patch:" and, for --unrecord,
"The following changes will be subtracted from the patch:".
msg18557 (view) Author: bf Date: 2015-06-18.18:53:09
This could be done by adding yet another parameter to getLog (and in
turn updatePatchHeader). Another solution is to re-formulate the
offending line so that it is command agnostic. For instance it could say:

# Summary of selected changes:
msg18582 (view) Author: ganesh Date: 2015-06-22.05:45:55
I'm fine with the suggested solution, though I'm not so sure it's 
obviously right; in the editor we are changing the message 
associated with the entire patch, rather than writing a message for 
the new changes, so you might also expect to see all the changes 
associated with the entire patch. But I don't think it's worth the 
effort of implementing that.
msg18588 (view) Author: noreply Date: 2015-06-22.05:51:55
The following patch sent by Ben Franksen <benjamin.franksen@helmholtz-berlin.de> updated issue issue2308 with
status=resolved;resolvedin=2.12.0 HEAD

* resolve issue2308: use command agnostic comment for changes summary 
Ignore-this: 271e4c3d3ba7a4dcef2cdb0df1fa2a89
msg18593 (view) Author: bf Date: 2015-06-22.19:51:24
I agree that you have a point there. I was thinking more like "what use
has the text for the user?", to which "seeing a summary of the changes
just made" sounds like a reasonable answer.
Date User Action Args
2013-02-28 17:45:37owstcreate
2013-02-28 17:48:26owstsetmessages: + msg16731
2015-06-18 18:29:21bfsetmessages: + msg18555
2015-06-18 18:53:10bfsetmessages: + msg18557
2015-06-22 05:45:56ganeshsetmessages: + msg18582
2015-06-22 05:51:56noreplysetstatus: unknown -> resolved
messages: + msg18588
resolvedin: 2.12.0
2015-06-22 19:51:25bfsetstatus: resolved -> unknown
messages: + msg18593