Page MenuHomePhabricator

Autosubscribe to topics via the 2017 wikitext editor doesn't display subscription until a page reload
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • Make sure the auto-subscribe preference is enabled in your editing preferences
  • Enter the 2017 wikitext editor by clicking "edit" on a talk page (not by opening that link in a new tab -- we want the load-in-place behavior)
  • Add a new topic to the page and publish
  • Observe the "subscribe" button by your new topic

What happens?:

The button says "subscribe", implying that you are not yet subscribed. If you reload the page, this will change to show "unsubscribe".

What should have happened instead?:

The button should have immediately shown "unsubscribe".

Other information (browser name/version, screenshots, etc.):

I suspect this is because the auto-sub is handled in a post-save hook (it's deep in the Echo notification hooks stack), and thus the subscription is actually processed after the API save is done and is provided with the new rendered content that it live-replaces the page with.

This would also happen to VisualEditor, if you found a talk page to use it on.

Event Timeline

Per offline discussion, the Editing Team will prioritize work on this issue if/when we come to learn that people are being impacted by it.

Note: we assume there are relatively few people using 2017 WTE on talk pages.

Change #1217159 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/VisualEditor@master] update wgPostEdit before firing postedit hook

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

On investigation this looks like quite a simple fix. We look at wgPostEdit to see if an edit has just been made, so we can just update the 2017 editor to update this variable.

Change #1217159 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@master] update wgPostEdit before firing postedit hook

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

Change #1217241 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/MobileFrontend@master] Update wgPostEdit before firing postedit hook

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

Change #1217241 merged by jenkins-bot:

[mediawiki/extensions/MobileFrontend@master] Update wgPostEdit before firing postedit hook

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

EAkinloose edited projects, added: Verified; removed: Editing QA.