Page MenuHomePhabricator

Make undo fail gracefully for non-main slots.
Closed, ResolvedPublic

Description

The undo action should be able to handle slots other than the main slot. However, since undo is handled by EditPage, and EditPage currently only supports the main slot, the best we can do for now is to fail gracefully when asked to undo an edit of something other than the main slot.

Eventually it should become able to handle multiple slots at once (when they are edit atomically, or when the edit spans multiple edits which changed different slots), see T189808: Make undo work with multiple slots..

Related Objects

StatusAssignedTask
Declineddchen
OpenNone
OpenNone
DuplicateNone
OpenNone
ResolvedAbit
OpenNone
OpenNone
OpenNone
OpenNone
DuplicateNone
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
Resolvedppelberg
ResolvedKrinkle
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
Resolveddaniel
ResolvedAnomie

Event Timeline

CCicalese_WMF triaged this task as Normal priority.May 10 2018, 4:24 PM
CCicalese_WMF created this task.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 10 2018, 4:24 PM
Tgr added a subscriber: Tgr.May 10 2018, 6:47 PM

Note that undo can span multiple revisions; if we go with this we need to disable that somehow. Also single-edit undos where the edit was created in some nonstandard way (e.g. hard revision deletion).

Anomie added a subscriber: Anomie.May 10 2018, 6:52 PM

Why would you need to do that, as long as the whole set of edits only changes one slot?

Tgr added a comment.May 10 2018, 6:55 PM

So just let the user load the undo screen and show an error message if more than one slot changed? I guess that makes more sense.

daniel renamed this task from Make action=undo work properly with multiple slots (phase 1) to Make action=undo work with non-main slots..May 15 2018, 9:54 AM
daniel updated the task description. (Show Details)
daniel updated the task description. (Show Details)May 15 2018, 9:57 AM

Change 441070 had a related patch set uploaded (by Daniel Kinzler; owner: Daniel Kinzler):
[mediawiki/core@master] Make undo fail if more than just the main slot is affected.

https://gerrit.wikimedia.org/r/441070

Change 441070 merged by jenkins-bot:
[mediawiki/core@master] Make undo fail if more than just the main slot is affected.

https://gerrit.wikimedia.org/r/441070

daniel renamed this task from Make action=undo work with non-main slots. to Make action=undo fail gracefully for non-main slots..Jun 23 2018, 9:08 AM
daniel closed this task as Resolved.
daniel updated the task description. (Show Details)
Vvjjkkii renamed this task from Make action=undo fail gracefully for non-main slots. to z6caaaaaaa.Jul 1 2018, 1:10 AM
Vvjjkkii reopened this task as Open.
Vvjjkkii removed daniel as the assignee of this task.
Vvjjkkii raised the priority of this task from Normal to High.
Vvjjkkii updated the task description. (Show Details)
Vvjjkkii removed subscribers: gerritbot, Aklapper.
CommunityTechBot renamed this task from z6caaaaaaa to Make action=undo fail gracefully for non-main slots..Jul 2 2018, 5:54 AM
CommunityTechBot closed this task as Resolved.
CommunityTechBot assigned this task to daniel.
CommunityTechBot lowered the priority of this task from High to Normal.
CommunityTechBot updated the task description. (Show Details)
CommunityTechBot added subscribers: gerritbot, Aklapper.
daniel renamed this task from Make action=undo fail gracefully for non-main slots. to Make undo fail gracefully for non-main slots..Jul 13 2018, 6:48 PM

Change 446606 had a related patch set uploaded (by Anomie; owner: Anomie):
[mediawiki/core@master] WikiPage: Return false from hasDifferencesOutsideMainSlot if no differences at all

https://gerrit.wikimedia.org/r/446606

Change 446606 merged by jenkins-bot:
[mediawiki/core@master] WikiPage: Return false from hasDifferencesOutsideMainSlot if no differences at all

https://gerrit.wikimedia.org/r/446606