Page MenuHomePhabricator

When a message requires modules load the modules on parse
Open, NormalPublic

Description

The module mediawiki.toc gets not loaded when __TOC__ is only in a message.

Steps to reproduce:

  • Create [[MediaWiki:Editnotice-0]] with the content
__TOC__
== H2 ==
  • Save the page
    • the module mediawiki.toc get loaded and the toc is hideable.
  • Edit a page in namespace 0
    • The content of MediaWiki:Editnotice-0 is shown before the edit box.
    • The toc is not hideable because the module mediawiki.toc is not loaded.

You only see the missing module mediawiki.toc when it is not loaded by the dependency to mediawiki.util. This dependency gets removed in https://gerrit.wikimedia.org/r/131260


Version: 1.24rc
Severity: minor
See Also:
T41049: SyntaxHighlight-Geshi CSS not included in special pages ([[Special:Cite]], [[Special:ExpandTemplates]])

Details

Reference
bz64969

Event Timeline

bzimport raised the priority of this task from to Normal.
bzimport set Reference to bz64969.
bzimport added a subscriber: Unknown Object (MLST).
Fomafix created this task.May 6 2014, 7:22 PM

Change 131766 had a related patch set uploaded by Gerrit Patch Uploader:
Load required modules from messages in parseText()

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

Change 196626 had a related patch set uploaded (by Umherirrender):
Add metadata from ParserOutput on message parse to OutputPage

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

He7d3r updated the task description. (Show Details)Mar 14 2015, 11:52 PM
He7d3r set Security to None.

Change 196626 abandoned by Umherirrender:
Add metadata from ParserOutput on message parse to OutputPage

Reason:
May have to many side effects or break changes

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

I liked https://gerrit.wikimedia.org/r/196626, can we revive it? We could try limiting this feature to a few message which run into this problem often ('edittools' in particular), if we're concerned about too many random things breaking. (cc @Umherirrender)

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 30 2015, 12:18 AM
XXN added a subscriber: XXN.Oct 30 2015, 12:25 AM

T113340 is also a request for automatic loading modules. Maybe this can combined or build on each other.

He7d3r added a subscriber: He7d3r.Oct 30 2015, 12:14 PM

I liked https://gerrit.wikimedia.org/r/196626, can we revive it? We could try limiting this feature to a few message which run into this problem often ('edittools' in particular), if we're concerned about too many random things breaking. (cc @Umherirrender)

Feel free to upload under your own name, if you have a concept in your head. There is no need for attribution to my user name.

Whitelisting messages by adding another call avoids b/c problems, but maybe makes things not easier.

Elitre added a subscriber: Elitre.Aug 29 2017, 10:40 AM