Page MenuHomePhabricator

VisualEditor is loading oojs-ui on desktop page load
Closed, ResolvedPublicBUG REPORT

Description

Flagged by performance dashboard:

Screenshot 2025-08-27 at 2.14.37 PM.png (532×1 px, 75 KB)

https://grafana.wikimedia.org/goto/1_Xv2wXNR?orgId=1

There also seems to be a spike in total blocking time:
https://grafana.wikimedia.org/d/c6a56131-dc83-4c9a-8d50-2e687f83ab70/reading-web-performance-peter-h-copy?orgId=1&from=now-30d&to=now&timezone=utc

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

What happens?:
An additional 100kb of uncompressed JS is being loaded.

What should have happened instead?:
The JS should be loaded when needed per our performance guidelines.

Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):

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

Event Timeline

With https://gerrit.wikimedia.org/r/c/mediawiki/extensions/VisualEditor/+/544247 oojs-ui was suddenly loaded on page load

That patch was merged almost 6 years ago.

How did you identify VisualEditor as the cause?

That patch was merged almost 6 years ago.

Sorry wrong patch.
https://gerrit.wikimedia.org/r/c/mediawiki/extensions/VisualEditor/+/1167846

How did you identify VisualEditor as the cause?

I was working on a test with @Catrope - https://gerrit.wikimedia.org/r/c/mediawiki/core/+/1152304 - which I paused why I was on sabbatical. After rebasing it, it alerted me to the fact that oojs-ui is being loaded on page load. If you revert the above patch the test passes.

Change #1182667 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[mediawiki/extensions/VisualEditor@master] Drop oojs-ui from page load

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

Change #1182668 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[VisualEditor/VisualEditor@master] Switch to using mw.util rather than OO.ui

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

ppelberg triaged this task as Unbreak Now! priority.Aug 27 2025, 11:13 PM

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

[mediawiki/extensions/VisualEditor@master] Restore ext.visualEditor.track module

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

Test wiki created on Patch demo by ESanders (WMF) using patch(es) linked to this task:
https://ed7a613ead.catalyst.wmcloud.org/w/

Change #1183088 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@master] Restore ext.visualEditor.track module

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

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

[mediawiki/extensions/VisualEditor@wmf/1.45.0-wmf.16] Restore ext.visualEditor.track module

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

That did it! I'm out Monday but can help backport it Tuesday (unless you feel comfortable about a Friday or Monday deployment given the long weekend for US people?)

Change #1182668 abandoned by Esanders:

[VisualEditor/VisualEditor@master] Switch to using mw.util rather than OO.ui

Reason:

See I8d2860672436cbf4e1d245e45062161babbe887a

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

Change #1182667 abandoned by Esanders:

[mediawiki/extensions/VisualEditor@master] Drop oojs-ui from page load

Reason:

See I8d2860672436cbf4e1d245e45062161babbe887a

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

Change #1183154 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@wmf/1.45.0-wmf.16] Restore ext.visualEditor.track module

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

Mentioned in SAL (#wikimedia-operations) [2025-09-02T20:45:39Z] <kemayo@deploy1003> Started scap sync-world: Backport for [[gerrit:1183154|Restore ext.visualEditor.track module (T403127)]]

Mentioned in SAL (#wikimedia-operations) [2025-09-02T20:51:31Z] <kemayo@deploy1003> jdlrobson, kemayo: Backport for [[gerrit:1183154|Restore ext.visualEditor.track module (T403127)]] synced to the testservers (see https://wikitech.wikimedia.org/wiki/Mwdebug). Changes can now be verified there.

Mentioned in SAL (#wikimedia-operations) [2025-09-02T20:57:59Z] <kemayo@deploy1003> Finished scap sync-world: Backport for [[gerrit:1183154|Restore ext.visualEditor.track module (T403127)]] (duration: 12m 20s)

Presumably this is no longer UBN, and just awaiting confirmation? Can it be downgraded so it doesn't show up in the UBN dashboard?

Test wiki on Patch demo by ESanders (WMF) using patch(es) linked to this task was deleted:

https://ed7a613ead.catalyst.wmcloud.org/w/

Jdlrobson-WMF lowered the priority of this task from Unbreak Now! to High.Sep 5 2025, 4:17 PM

Hope I'm not overstepping here @ppelberg by changing priority.

Screenshot 2025-09-05 at 9.17.07 AM.png (540×1 px, 80 KB)

I'm still seeing similar blocking issues, but I think that relates to a Wiki loves monument banner that is now loading.

Hope I'm not overstepping here @ppelberg by changing priority.

Screenshot 2025-09-05 at 9.17.07 AM.png (540×1 px, 80 KB)

I'm still seeing similar blocking issues, but I think that relates to a Wiki loves monument banner that is now loading.

Eek! No, not at all. Thank you for consciously taking action, @Jdlrobson and thank you, @Jdforrester-WMF for noticing!

ppelberg claimed this task.
ppelberg added a project: Skipped QA.

Screenshot 2025-09-05 at 9.17.07 AM.png (540×1 px, 80 KB)

I'm still seeing similar blocking issues, but I think that relates to a Wiki loves monument banner that is now loading.

Per above, Editing sees this issue as Resolved.