Last modified: 2013-06-26 23:57:03 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T52068, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 50068 - Parsoid: selser drops last three apostrophes in '''''foo'''''
Parsoid: selser drops last three apostrophes in '''''foo'''''
Status: RESOLVED FIXED
Product: Parsoid
Classification: Unclassified
serializer (Other open bugs)
unspecified
All All
: High normal
: ---
Assigned To: Gabriel Wicke
:
: 50258 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-06-24 00:31 UTC by Oliver Keyes
Modified: 2013-06-26 23:57 UTC (History)
6 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Oliver Keyes 2013-06-24 00:31:52 UTC
See https://en.wikipedia.org/w/index.php?title=Port_of_Hull&diff=561131671&oldid=561056099 - an attempt to enter a dash led to bolding vanishing. Not sure what's going on there.
Comment 1 James Forrester 2013-06-24 01:25:16 UTC
Roan, can you tell how we're dirtying the DOM such that Parsoid changes these at all?
Comment 2 Roan Kattouw 2013-06-26 03:03:33 UTC
We've seen this come up a number of times in our testing; I haven't investigated this one yet.
Comment 3 Roan Kattouw 2013-06-26 03:30:10 UTC
This turns out to be a Parsoid bug:

$ echo "Foo '''''bar''''' baz" > wt
$ node parse.js --wt2html < wt | tee html
<body><p data-parsoid='{"dsr":[0,21,0,0]}'>Foo <i data-parsoid='{"dsr":[4,14,2,2]}'><b data-parsoid='{"autoInsertedEnd":true,"dsr":[6,12,3,0]}'>bar</b></i> baz</p>
</body>
$ sed 's/baz/baaz/g' < html | tee html2
<body><p data-parsoid='{"dsr":[0,21,0,0]}'>Foo <i data-parsoid='{"dsr":[4,14,2,2]}'><b data-parsoid='{"autoInsertedEnd":true,"dsr":[6,12,3,0]}'>bar</b></i> baaz</p>
</body>
$ node parse.js --html2wt --selser --oldtextfile wt --oldhtmlfile html < html2
Foo '''''bar'' baaz

Note that this doesn't break if there is no DOM change (i.e. if you pipe in html rather than html2 in the last step), and it also doesn't break if selser is disabled (i.e. if you omit --selser in the last step).
Comment 4 Gabriel Wicke 2013-06-26 03:43:23 UTC
Here are actually two bugs:

1) a VE bug that causes that paragraph to be dirtied
2) a Parsoid bug that does not round-trip the bolding properly when using selser on bold elements

Should I open a separate bug for VisualEditor, or do you have one for this already?
Comment 5 Roan Kattouw 2013-06-26 03:49:01 UTC
I can't reproduce the dirtying of the paragraph locally. If I make a null change, I get a null diff. If I change anything outside the bold+italic text, I get the bad diff.

There are some dirtying issues with the code that was in production at the time, and still one left for which the fix is not deployed. That said, the minimal test case for this ( https://en.wikipedia.org/w/index.php?title=User:JohnCD/VEtest5&diff=next&oldid=561489465 ) does have a neighboring change.
Comment 6 James Forrester 2013-06-26 22:07:34 UTC
*** Bug 50258 has been marked as a duplicate of this bug. ***
Comment 7 Gerrit Notification Bot 2013-06-26 22:59:35 UTC
Related URL: https://gerrit.wikimedia.org/r/70768 (Gerrit Change I69bda7db141a3302cee6ece5af5ffdc57e748d89)
Comment 8 Gerrit Notification Bot 2013-06-26 22:59:38 UTC
Related URL: https://gerrit.wikimedia.org/r/70768 (Gerrit Change I69bda7db141a3302cee6ece5af5ffdc57e748d89)
Comment 9 Gerrit Notification Bot 2013-06-26 23:57:03 UTC
https://gerrit.wikimedia.org/r/70768 (Gerrit Change I69bda7db141a3302cee6ece5af5ffdc57e748d89) | change APPROVED and MERGED [by jenkins-bot]

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links