Temporary Disabled. :) please Go back ⚓ T303396 Reply widget attached outside of mw-parser-output when viewing old revision and logged out www.fgks.org » Address: [go: up one dir, main page] Include Form Remove Scripts Accept Cookies Show Images Show Referer Rotate13 Base64 Strip Meta Strip Title Session Cookies Page MenuHomePhabricatorSearchConfigure Global SearchLog InCreate Task Maniphest T303396 Reply widget attached outside of mw-parser-output when viewing old revision and logged outClosed, ResolvedPublicActionsEdit TaskEdit Related Tasks...Create SubtaskEdit Parent TasksEdit SubtasksMerge Duplicates InClose As DuplicateEdit Related Objects...Edit CommitsEdit MocksSubscribeMute NotificationsProtect as security issueAward TokenFlag For LaterAssigned TomatmarexAuthored By• EsandersMar 9 2022, 2:43 PM2022-03-09 14:43:46 (UTC+0)TagsDiscussionTools (Triaged)Editing-team (Kanban Board) (Ready for Sign Off)MW-1.38-notes (1.38.0-wmf.26; 2022-03-14)VerifiedReferenced FilesF34993852: image.pngMar 9 2022, 9:51 PM2022-03-09 21:51:36 (UTC+0)SubscribersAklapperEAkinloose• EsandersmatmarexDescriptionVisit https://en.wikipedia.beta.wmflabs.org/w/index.php?title=User_talk:ESanders_(WMF)/Sandbox&oldid=541311 while logged and and hit [reply], Observe a new <dl> is attached to the DOM as a sibling of the main mw-parser-output node. This doesn't happen if you are logged in, or viewing the latest revision of the page (?!) If you use the edit-conflict-reload feature, the "Loading..." message does not get cleared as we only update the mw-parser-output node.DetailsSubjectRepoBranchLines +/-Don't allow the root node to be treated like a comment framemediawiki/extensions/DiscussionToolsmaster+97 -12Customize query in gerritRelated ObjectsMentionsMentioned In T319148: Reply Tool (mobile) remains visible when section is collapsed Event Timeline• Esanders created this task.Mar 9 2022, 2:43 PM2022-03-09 14:43:46 (UTC+0)Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 9 2022, 2:43 PM2022-03-09 14:43:46 (UTC+0)• Esanders updated the task description. (Show Details)Mar 9 2022, 2:46 PM2022-03-09 14:46:00 (UTC+0)matmarex claimed this task.Mar 9 2022, 7:04 PM2022-03-09 19:04:31 (UTC+0)matmarex added a project: Editing-team (Kanban Board).gerritbot added a comment.Mar 9 2022, 9:51 PM2022-03-09 21:51:16 (UTC+0)Comment ActionsChange 769536 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński): [mediawiki/extensions/DiscussionTools@master] Don't allow the root node to be treated like a comment frame https://gerrit.wikimedia.org/r/769536gerritbot added a project: Patch-For-Review.Mar 9 2022, 9:51 PM2022-03-09 21:51:16 (UTC+0)matmarex added a comment.Mar 9 2022, 9:51 PM2022-03-09 21:51:36 (UTC+0)Comment ActionsThis is caused by the code that lets the reply tool (and the real reply) appear outside of a frame like in this example: https://en.wikipedia.beta.wmflabs.org/w/index.php?title=Talk:T303396&oldid=541380 To achieve this, CommentModifier tries to find a set of sibling nodes that almost exactly matches the comment's range. There is some ugly code implementing the "almost exactly" part, basically it ignores various nodes according to various made up rules – for example, our own [reply] buttons and markers, and HTML comments (check the wikitext source for an example). There were two bugs in that code: It was ignoring all headings on the page, just like it ignores the markers, because we add data-mw-comment attribute to them and it was treating it like data-mw-comment-start/data-mw-comment-end If the comment's range almost exactly matched the <div class="mw-parser-output"> node (because it was the only thread item on the page – or the only thread item except for headings, considering the bug above), it would treat it like a regular frame, thus displaying the reply tool outside of it. Also, when saving the real reply, if the range almost exactly matched the <body> node, the reply would actually be placed after the closing </body> tag in the HTML sent to Parsoid. Ssomewhat surprisingly, it copes with that just fine: https://en.wikipedia.beta.wmflabs.org/w/index.php?title=Talk:T303396b&diff=541384&oldid=541383. ppelberg moved this task from Backlog to Triaged on the DiscussionTools board.Mar 10 2022, 4:14 PM2022-03-10 16:14:55 (UTC+0)gerritbot added a comment.Mar 10 2022, 5:50 PM2022-03-10 17:50:35 (UTC+0)Comment ActionsChange 769536 merged by jenkins-bot: [mediawiki/extensions/DiscussionTools@master] Don't allow the root node to be treated like a comment frame https://gerrit.wikimedia.org/r/769536ReleaseTaggerBot added a project: MW-1.38-notes (1.38.0-wmf.26; 2022-03-14).Mar 10 2022, 6:00 PM2022-03-10 18:00:39 (UTC+0)Maintenance_bot removed a project: Patch-For-Review.Mar 10 2022, 6:10 PM2022-03-10 18:10:20 (UTC+0)matmarex moved this task from Incoming to QA on the Editing-team (Kanban Board) board.Mar 10 2022, 7:15 PM2022-03-10 19:15:30 (UTC+0)matmarex added a project: Editing QA.EAkinloose subscribed.Mar 22 2022, 9:16 PM2022-03-22 21:16:23 (UTC+0)Comment ActionsThe number of <dl> elements remain the same after hitting/toggling [reply]. See https://photos.app.goo.gl/9Sp6ofL6bQaoYTHS7 Looks good to me.EAkinloose edited projects, added Verified; removed Editing QA.Mar 23 2022, 12:11 AM2022-03-23 00:11:00 (UTC+0)EAkinloose moved this task from QA to Ready for Sign Off on the Editing-team (Kanban Board) board.ppelberg closed this task as Resolved.Mar 26 2022, 1:19 AM2022-03-26 01:19:47 (UTC+0)matmarex mentioned this in T319148: Reply Tool (mobile) remains visible when section is collapsed.Oct 9 2022, 7:48 PM2022-10-09 19:48:03 (UTC+0)Log In to Comment
Visit https://en.wikipedia.beta.wmflabs.org/w/index.php?title=User_talk:ESanders_(WMF)/Sandbox&oldid=541311 while logged and and hit [reply],
Observe a new <dl> is attached to the DOM as a sibling of the main mw-parser-output node.
This doesn't happen if you are logged in, or viewing the latest revision of the page (?!)
If you use the edit-conflict-reload feature, the "Loading..." message does not get cleared as we only update the mw-parser-output node.
Change 769536 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):
[mediawiki/extensions/DiscussionTools@master] Don't allow the root node to be treated like a comment frame
https://gerrit.wikimedia.org/r/769536
This is caused by the code that lets the reply tool (and the real reply) appear outside of a frame like in this example: https://en.wikipedia.beta.wmflabs.org/w/index.php?title=Talk:T303396&oldid=541380
To achieve this, CommentModifier tries to find a set of sibling nodes that almost exactly matches the comment's range. There is some ugly code implementing the "almost exactly" part, basically it ignores various nodes according to various made up rules – for example, our own [reply] buttons and markers, and HTML comments (check the wikitext source for an example).
There were two bugs in that code:
Change 769536 merged by jenkins-bot:
The number of <dl> elements remain the same after hitting/toggling [reply]. See https://photos.app.goo.gl/9Sp6ofL6bQaoYTHS7 Looks good to me.