> Can you quantify lots?

At least 5 templates (including the one discussed in this thread), approx 160 transclusions on yue.wp, mostly in article space. That means 0.25% of all articles.

According to the discussion, zh.wp is affected by this bug too: at least 7 templates, according to my insource search.

en.wp has at least 45 pages with this problem, including 9 templates. [[en:Template:Merge to]] alone has 3000+ transclusions.

Since this change affected [[en:Template:Merge to]] which is a trunk project copied by many other wikis, I expect a very large - probably in the tens of thousands - total number of broken pages.

My insource search string:
insource:/"[[:{{NAMESPACE}}:"/

Deryck



On 5 Sep 2017 22:54, "Arlo Breault" <abreault@wikimedia.org> wrote:
> A recent change to MediaWiki software seems to have broken templates everywhere. The syntax
>
> [[:{{NAMESPACE}}:{{{1}}}|{{{1}}}]]
>
> used to work on a template to generate a link to a page in the same namespace, typically used on templates related to move (rename) discussions.

The change is in, https://gerrit.wikimedia.org/r/#/c/361597/

The commit message there asserts that there were only a handful
of pages this was seen to affect in [[mw:Parsoid/Round-trip_testing]].

Nevertheless, I should have communicated it more widely, since that
isn't necessarily representative of your wiki.


> However this has stopped working as of last month, causing lots of [[::ABC|ABC]] to be displayed in plain-text everywhere when this syntax is used in the main namespace.

Can you quantify "lots"?

https://zh-yue.wikipedia.org/w/index.php?title=Special:%E9%82%8A%E5%BA%A6%E9%8F%88%E5%8E%BB%E5%91%A2%E7%89%88/Template:Mergeto&limit=100

shows less than a hundred main namespace pages.


The justification for the change is that the first colon has meaning,
it escapes the link, giving it the default namespace, but the second
colon is part of the title.

https://en.wikipedia.org/wiki/:Link

vs

https://en.wikipedia.org/wiki/::Link


> We figured for now at yue.wp that
> [[{{NAMESPACE}}:{{{1}}}|{{{1}}}]]
> (notice the deletion of the colon at the beginning) works and would like to know if this is the recommended solution. This doesn't seem to have been picked up by Linter.

That isn't exactly the same thing.

For some namespaces (File, Category, etc.) the colon
escape renders that syntax as a link rather than
construct itself (file, or whathaveyou).

Using that template on pages in those namespaces
will have different results.


The pseudocode you want is more like,

if (namespace) { ":" + namespace }


> Related discussion on yue.wp:
> https://zh-yue.wikipedia.org/w/index.php?title=Wikipedia%3A%E5%9F%8E%E5%B8%82%E8%AB%96%E5%A3%87_%28%E6%8A%80%E8%A1%93%29&type=revision&diff=1120463&oldid=1118769
>
> Deryck [[User:Deryck Chan]]
> Sysop & ambassador, yue.wp

Sorry for the inconvenience.  If the above workaround
is unacceptable, let me know, and we'll reassess.

Arlo