75

I just had an occasion where someone reformatted the code in my question, not because it was ill-formatted, but to match his preferred style. I would have liked to be able to type a reason for rolling back the edits when I did so - could the ability to do that be added?

1

5 Answers 5

61

This feature already exists!

  1. Open up the revision history on the post you wish to roll back.

  2. Click "edit" on the revision you wish to roll back to. Note the message at the top-right of the page:

    Warning!

    You're editing an old revision. If you save it, you will effectively roll back to this old version of the post.

  3. Type your reason for rolling back into the "Edit Summary" field.

  4. Click "Save edits". Note that you never click "Rollback".

22
  • 63
    Well, I'll be! That's far from obvious. Commented Mar 12, 2010 at 0:10
  • @SoftMon: it might not be an obvious feature, but it's there nonetheless.
    – perbert
    Commented Mar 12, 2010 at 0:11
  • 2
    IMHO, the feature itself is reasonably obvious... It's just that it allows so much more than simply leaving a comment on a rollback that thinking of it in those terms can be a bit difficult.
    – Shog9
    Commented Mar 12, 2010 at 0:31
  • If you weren't aware of the 5-minute grace period on edits, there's no way you would know that this is the case. Commented Mar 12, 2010 at 0:45
  • 3
    @Farseeker: Eh? The grace period only matters when you made the last edit (vs. a straight rollback, which completely ignores/obliterates any grace period). It made demonstrating this a bit more involved, but in normal use you'd be rolling back someone else's edit and the grace period wouldn't apply.
    – Shog9
    Commented Mar 12, 2010 at 0:49
  • 7
    This is very not obvious as the 'edit' button is next to the 'rollback' button, and if I had to guess which one a user would press when they want to roll something back I'd place my bets on... well, no no, I don't want to give it away.
    – Jason C
    Commented Aug 14, 2013 at 2:26
  • 5
    Maybe I'm an uncommon user? I've wanted to leave at least a brief explanation of every single rollback I've ever done (and now I know how).
    – Jason C
    Commented Aug 14, 2013 at 2:57
  • 2
    Heh... Yeah, I've known about this for years and, while it's certainly nice in certain situations, I wouldn't consider it particularly essential, @Jason. But hey - now you know!
    – Shog9
    Commented Aug 14, 2013 at 2:58
  • 1
    @Shog9 Thanks; it initially wasn't clear to me whether you needed to add that “Rollback to Revision 1” text yourself or whether it was automatic. Commented Jun 21, 2017 at 17:41
  • 1
    Yeah, it's automatic 'cause the system still considers it a rollback.
    – Shog9
    Commented Jun 21, 2017 at 17:49
  • 1
    You forgot 4. edit something else in the post. I'm getting reports that just editing the edit reason does not result in a successful edit to the edit reason.
    – Catija
    Commented Apr 11, 2018 at 20:33
  • 1
    A rollback that doesn't change the post isn't a rollback, @catija; if you edit the current revision, then it isn't a rollback even if you do change something.
    – Shog9
    Commented Apr 11, 2018 at 21:10
  • 1
    No... the user rolled back the post, went to the edit history, edited the reason, saved it... and it didn't change.... or they just mis-read the instructions... bah.
    – Catija
    Commented Apr 11, 2018 at 21:12
  • 2
    That's fair. I just requires that you know this process before you roll something back. Otherwise, you have to start doing weird things, unless you have a diamond and can edit the reason independently of anything else.
    – Catija
    Commented Apr 11, 2018 at 21:18
  • 1
    As I wrote... 13 years ago... In response to a similar comment, @This_is_NOT_a_forum: the function is obvious enough, it's this use-case that is obscure - and I mean that in both senses. The obvious way to do this is to just... Leave a comment. And occasionally that happens, but most of the time it doesn't - most rollbacks, heck, most edits get precious little in the way of explanation from their author. Folks are also generally terrible about writing useful commit messages. There's not much point in making a particular use of a tool more obvious in that case.
    – Shog9
    Commented Apr 19, 2023 at 22:07
24

I agree, clicking rollback should definitely have an rollback-reason or comment input, same as editing does

While you can workaround this by using the "edit" button on an older revision, the rollback button is what I would naturally click in such a situation

I guess a slightly more drastic solution would be to remove the rollback button, and rename "edit" button the revisions page to "revert to this revision". Not only would it inherently prompt for a reason when "rolling back", it better describes what the edit button does (plus gives a nice preview of what the rolled-back question will look like)

1
  • 1
    This is the crux of it. "Rollback" is exactly what I want to do, and so a workflow where the best path is for me to click a button besides Rollback is asking me to know mysterious StackExchange lore, akin to (but worse than) typing feline commands to view the contents of a file in Linux. :-) Commented Oct 18, 2016 at 14:30
1

Having the possibility to specify immediately the reason of rollback would be a beneficial feature. With no drawback. Leaving a motivation note should be in fact an encouraged behaviour.

The proposed workaround also doesn't work at all if the rollback happened too long in the past, with no error notification (I am allowed to edit and to save, but the change is not there afterwards). For example, I cannot specify anymore the rollback reason for this.

1
  • 1
    Just to clarify this answer: there's no time-limit on leaving a comment with a rollback if you remember to do it; if you roll back first and then later think "I should've explained that", you're stuck having to leave a comment on the post itself (or submit a new edit).
    – Shog9
    Commented Jun 21, 2017 at 17:48
-2

I think the feature should be added. One reason, as already mentioned, is that the approach of clicking Edit on an old revision is not obvious. A related problem not yet seen discussed is that if you click Rollback (not knowing about the Edit trick), notice the summary isn't what you want, research the right way to do it, and finally learn about the Edit trick, you end up in a state where you can't use the Edit trick. Since the post content at this point matches the content you desire it to have, if you click Edit, enter a summary, and click Save Edits, the edit, along with your summary, is discarded.

You can work around the problem by making an artificial change, for example by rolling back to the edit you want to roll back from. Now Edit changes the post content and your summary is saved. It's a cumbersome process, however, and adds noise to the edit history.

-4

This whole issue would be averted if we could just comment on edits in the edit page of a question. This way we could have discussions about edits (which would be nice) and you could comment on why you reverted to a version.

2
  • 3
    I guess one potential side effect is people might end up using it as folks use wikipedia talk... or start discussing things, which would be noisy, even if hidden away. Commented Mar 31, 2018 at 1:14
  • I don't see anything wrong with that personally. If someone is coming in and changing something that you wrote it is natural to want to discuss things, and hopefully end up making the answer better
    – real_ate
    Commented Mar 31, 2018 at 12:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .