Page MenuHomePhabricator

Deploy HTML5 sections to WMF production
Closed, ResolvedPublic5 Estimated Story Points

Description

T152540: Migrate to HTML5 section ids is concluded on my books, as far as MediaWiki support goes. Now we need to roll it out to WMF. I'm going to flip migration mode on test wikis today, the rest of the timeline is up for discussion.

Related Objects

Event Timeline

Change 377527 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[operations/mediawiki-config@master] Start migration to HTML5 sections on test wikis

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

Change 377527 merged by jenkins-bot:
[operations/mediawiki-config@master] Start migration to HTML5 sections on test wikis

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

Mentioned in SAL (#wikimedia-operations) [2017-09-12T21:49:13Z] <maxsem@tin> Synchronized wmf-config/InitialiseSettings.php: https://gerrit.wikimedia.org/r/#/c/377527/2 T175725 (duration: 00m 49s)

DannyH triaged this task as Medium priority.
DannyH set the point value for this task to 5.
DannyH moved this task from New & TBD Tickets to Up Next (June 3-21) on the Community-Tech board.

Change 386553 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[operations/mediawiki-config@master] Enable Unicode section links on Russian projects

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

Change 386710 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[operations/mediawiki-config@master] Enable Unicode section links on mediawiki.org

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

Change 386553 merged by jenkins-bot:
[operations/mediawiki-config@master] Enable Unicode section links on Russian projects

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

Change 386710 merged by jenkins-bot:
[operations/mediawiki-config@master] Enable Unicode section links on mediawiki.org

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

Hey, the following problems have emerged:

  1. <ref>'s with [] in name parameter are rendered incorrectly, while everything was ok before the change.

<ref name="[]">text</ref> is displayed like this:

image.png (56×209 px, 2 KB)

{} works fine. <> doesn't work fine, but it didn't work fine before the change too.

Section headings with [] work fine.

  1. I guess, not the problem of this task, but still. Non-breaking spaces in the same parameter worked fine before, don't work now. We have T90902: Non-breaking space in header ID breaks anchor about this.

<ref name="smth smth">text</ref> (non-breaking space between smth) doesn't work now.

We should probably limit the characters allowed for reference names explicitly in Cite.

A little correction. I said, "<> doesn't work fine, but it didn't work fine before the change too", but when used via Scribunto (frame:extensionTag), <> can be used. And it works.

One more point. Given the fact that [] and {} can't be used in wikilinks, should {{#anchorencode}} & mw.uri.anchorEncode convert them to percent-encoding (or HTML entities)?

...Note that [[#%5B%5D]] and [[#&#91;&#93;]] are both rendered as "#[]" in the browser and point to #[] fragment.

Next one. After saving a section, you are redirected to a page with an anchor percent-encoded, like https://ru.wikipedia.org/wiki/<Page_name>#%D0%9F%D1%80%D0%B5%D0%B4%D0%B2%D0%B0%D1%80%D0%B8%D1%82%D0%B5%D0%BB%D1%8C%D0%BD%D1%8B%D0%B9_%D0%B8%D1%82%D0%BE%D0%B3.

"After saving a section" - Yes, after section editing and pressing "Save changes"
before HTML5 sections https://ru.wikipedia.org/wiki/Википедия:Песочница#.D0.9F...
with HTML5 sections https://ru.wikipedia.org/wiki/Википедия:Песочница#%D0%9F...
it's because of the browser or mediawiki?

Links from notifications popup behave the same way and appear percent-encoded.

New links enadled in the ru.wikipedia and ru.wikisource, but link between projects from ru.wikipedia to ru.wikisource generates an old link with an encoding (also from en.wiki to ru.wiki )

[[:s:Уголовный кодекс Российской Федерации/Глава 1#Статья 2]]
https://ru.wikisource.org/wiki/Уголовный_кодекс_Российской_Федерации/Глава_1#.D0.A1.D1.82.D0.B0.D1.82.D1.8C.D1.8F_2

so all projects with html5 sections in their template:anchor should create two links - a new one and an old one with an encoding.

maybe for convenience create a new magic word {{anchorencode:string|OLD}}?

Change 394104 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[operations/mediawiki-config@master] Switch all wikis to HTML5 section IDs

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

Change 394104 merged by jenkins-bot:
[operations/mediawiki-config@master] Switch all wikis to HTML5 section IDs

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

I didn't actually deploy the above change because the wikis are still running wmf.8, it'll have to wait.

Change 394460 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[operations/mediawiki-config@master] Switch all wikis to HTML5 section IDs

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

Change 394460 merged by jenkins-bot:
[operations/mediawiki-config@master] Switch all wikis to HTML5 section IDs

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

kaldari edited projects, added Community-Tech-Sprint; removed Community-Tech.
kaldari moved this task from In Development to Q1 2018-19 on the Community-Tech-Sprint board.
kaldari closed subtask Restricted Task as Resolved.Jan 4 2018, 2:16 AM