What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 134 Stack Exchange communities.

To avoid edit collisions, I would suggest that when an edit is submitted, the server should check if the current version of the post is the same one that the editor has started with (i.e. no one has edited it .. yet). If it's different, it should notify the user that there has been an edit on that post, so that one can modify/cancel their edit.

This happened to me 3 times in the last 2 days: A new question is posted by someone, I edit the question to add tags, remove CAPS, ... etc. I submit my edit. A second later I see that the question was edited by someone else! He/she was editing the original post at the same time I was.

This, for example, happened today:

edit-collision

share|improve this question
1  
I asked something similar to this awhile back meta.stackexchange.com/questions/1577/… and I think dbr's answer was a good suggestion –  Alex Rozanski Sep 6 '09 at 18:14
5  
This "George Stocker" person looks rather dodgy. I'm pretty sure he stole that avatar - no doubt this "edit collision" is somehow key to his as-yet unknown but without a doubt dastardly plan... –  Shog9 Sep 6 '09 at 18:16
    
@perspx: thanks .. I didn't find that when I was searching ... maybe I was using the wrong keywords. That's exactly what I was asking about. –  Aziz Sep 6 '09 at 18:19
    
@Shog9 ................ ahhhhh what? –  Aziz Sep 6 '09 at 18:20
3  
OMG! Gortok is gone! All questions, answers, and comments have vanished, spirited away as though by some sorcery... And this "George" character is wearing his face like a mask! The pod people are taking over!!! –  Shog9 Sep 6 '09 at 18:35
    
We has been haxed? :O –  Aziz Sep 6 '09 at 18:35
1  
Related: meta.stackexchange.com/questions/15635/… –  balpha Sep 6 '09 at 19:52
    
possible duplicate of Preventing conflicting simultaneous edits –  Gnome May 30 '10 at 7:27

4 Answers 4

up vote 4 down vote accepted

We now prevent edit collisions on save.

When you click "Save Edits", if the post changed while you were editing, we now return:

{username} edited {tags / body / title} of this post; try refreshing this post and editing again.

It is specific to the area in question, so one user can edit body and you can edit tags without conflicting. (Or title, etc). It's only when you both edit the same field at the same time this error is returned on save.

share|improve this answer

I think if there was a way to send some type of message to the user notifying that a new edit has taken place (much like the new answer posted notification when you are typing up an answer), that it would help a lot. Merging would also be a good feature.

share|improve this answer
1  
I think this is much easier (and thus more likely to be implemented) than a merge feature. It's almost exactly the same thing as the new answer notification when editing an answer. –  ベレアー アダム Sep 6 '09 at 19:56

Yeah, we really do need a three way merge.

share|improve this answer
1  
Or just a three way...the cool kind. –  Eric Sep 6 '09 at 19:35
5  
@Eric: You need females for the "cool" kind. I'm not sure SO can deliver. ;) –  gnostradamus Sep 6 '09 at 20:16
    
Depends on what way you swing isn't Stackoverflow equal opportunity? –  Jared Sep 6 '09 at 20:21
1  
@Jared: True, my definition of "cool" has a hetero bias. No offense intended. –  gnostradamus Sep 6 '09 at 20:39
1  
@gnovice: Much agreed, and henceforth specified. It's as yet impossible here at SO, but that doesn't change the fact that we really do need a three way (the cool kind). –  Eric Sep 6 '09 at 21:31

Some time later now, a few current details:

Since November 2009, one might get a topbar notification while editing:

Be advised: this post has been edited 1 time by other users while you were editing.

Nice! But indeed when two people save almost simultaneously/concurrently, then this warning is not shown (apparently it's updated every 30 or 45 seconds), and the last edit overwrites the previous one without any notification. (The revision history still shows it, of course.) This can even accidentally overwrite the "duplicate of" links.

The 5 minute grace period makes things even harder: when someone else starts editing within that grace period, and then the first author saves a change within the grace period but before the second editor saves, then no new revision is created. Next, when that other person saves, a new revision is created but the most recent changes are silently overwritten. (Like a post in which Martin changed "10.6" to "10.5.8" within the 5 minute grace period, which was undone when Mehper saved an edit that was started before Martin made that change, but was saved after that.)

(A "new revision" is actually split into title, body, and tags. So maybe the existing automatic merge of these components is the best we can expect? Even then: if someone changed just the title, then edits that someone else made to the body might not be accurate after all, so here a warning might be nice too. And I don't care if the last edit is blocked or can still be saved, but some warning might be great.)

share|improve this answer

You must log in to answer this question.

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