<nowiki/> tag inside a template parameter was removed in this edit: https://ko.wikipedia.org/w/?oldid=27637873&diff=prev&diffmode=source
This is surprising to me. I thought the wikitext in template parameters isn't really processed at all?
<nowiki/> tag inside a template parameter was removed in this edit: https://ko.wikipedia.org/w/?oldid=27637873&diff=prev&diffmode=source
This is surprising to me. I thought the wikitext in template parameters isn't really processed at all?
Status | Subtype | Assigned | Task | ||
---|---|---|---|---|---|
Open | None | T262408 [TRACKING] Selser issues on talk pages | |||
Resolved | ppelberg | T264027 <nowiki/> tag removed inside template parameter |
This issue is annoying me very much, so I tried to do some debugging.
I grepped for <nowiki/> and found this bit of code, which seems to be responsible for this behavior:
// Strip (useless) trailing <nowiki/>s // Interim fix till we stop introducing them in the first place. // // Don't strip |param = <nowiki/> since that pattern is used // in transclusions and where the trailing <nowiki /> is a valid // template arg. So, use a conservative regexp to detect that usage. $replaced_line = preg_replace( '#^([^=]*?)(?:<nowiki\s*/>\s*)+$#D', '$1', $line, 1 );
This interim fix was originally added in 2015: rGPAR06baaf4ff65a: T115717: Strip trailing <nowiki />s
Following a few links from there, I found that it was a workaround for T58381, which has been fixed since 2017.
We should try to remove this…
Change 714375 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):
[mediawiki/services/parsoid@master] Stop stripping trailing <nowiki/>s
Change 714376 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):
[VisualEditor/VisualEditor@master] Fix removing empty annotations when the entire paragraph is removed
These patches seem to work for me when testing, but I'm having trouble with the tests (in both repos). Maybe I'll come back to this some other time.
Change 714375 merged by jenkins-bot:
[mediawiki/services/parsoid@master] Stop stripping trailing <nowiki/>s
Change 715581 had a related patch set uploaded (by Sbailey; author: Sbailey):
[mediawiki/vendor@master] Bump parsoid to 0.14.0.a17
Change 715581 merged by jenkins-bot:
[mediawiki/vendor@master] Bump parsoid to 0.14.0-a17
Change 714376 merged by jenkins-bot:
[VisualEditor/VisualEditor@master] Fix removing empty annotations when the entire paragraph is removed
Change 720478 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):
[mediawiki/extensions/VisualEditor@master] Update VE core submodule to master (eaa1e32b5)
Change 720478 merged by jenkins-bot:
[mediawiki/extensions/VisualEditor@master] Update VE core submodule to master (eaa1e32b5)