Page MenuHomePhabricator

Wikisource projects use different namespaces for page, so max width applying where it shouldn't
Closed, ResolvedPublic

Description

In English Wikisource the page namespace is 104.
In Italian Wikisource it is 108
It varies in other namespaces too.

TODO

Context: https://www.mediawiki.org/wiki/Talk:Reading/Web/Desktop_Improvements/Archive4#Not_at_all_suitable_for_Wikisource_users

Event Timeline

@Ankry said he would share the list with us, optionally along with the script that pulls this data out.

As it turns out, originally, the Page namespace was paired with the lowest not used number which was different on each wiki. Only a few years ago, it was standardized for new Wikisource wikis.

  1. It was already suggested in T74525 to harmonize Page/Index namespace numbes across Wikisources
  2. The current number used can be retrieved from configuration using the wgProofreadPageNamespaceIds parameter
  3. The current list follows. It was extracted from the result of the script https://github.com/phil-el/phetools/blob/master/utils/gen_namespace.py

Please, remember that sourceswiki is also Wikisource (as "old" in the list below).

namespaces["wikisource"]["es"] = {
    "Page" : 102,
}
namespaces["wikisource"]["it"] = {
    "Page" : 108,
}
namespaces["wikisource"]["ban"] = {
    "Page" : 250,
}
namespaces["wikisource"]["be"] = {
    "Page" : 104,
}
namespaces["wikisource"]["gl"] = {
    "Page" : 250,
}
namespaces["wikisource"]["ko"] = {
    "Page" : 250,
}
namespaces["wikisource"]["la"] = {
    "Page" : 104,
}
namespaces["wikisource"]["nl"] = {
    "Page" : 104,
}
namespaces["wikisource"]["pa"] = {
    "Page" : 250,
}
namespaces["wikisource"]["mr"] = {
    "Page" : 104,
}
namespaces["wikisource"]["jv"] = {
    "Page" : 250,
}
namespaces["wikisource"]["fi"] = {
    "Page" : 250,
}
namespaces["wikisource"]["is"] = {
    "Page" : 250,
}
namespaces["wikisource"]["ru"] = {
    "Page" : 104,
}
namespaces["wikisource"]["he"] = {
    "Page" : 104,
}
namespaces["wikisource"]["wa"] = {
    "Page" : 250,
}
namespaces["wikisource"]["hr"] = {
    "Page" : 102,
}
namespaces["wikisource"]["lt"] = {
    "Page" : 250,
}
namespaces["wikisource"]["or"] = {
    "Page" : 250,
}
namespaces["wikisource"]["sk"] = {
    "Page" : 250,
}
namespaces["wikisource"]["ja"] = {
    "Page" : 250,
}
namespaces["wikisource"]["cs"] = {
    "Page" : 250,
}
namespaces["wikisource"]["de"] = {
    "Page" : 102,
}
namespaces["wikisource"]["pms"] = {
    "Page" : 102,
}
namespaces["wikisource"]["fo"] = {
    "Page" : 250,
}
namespaces["wikisource"]["th"] = {
    "Page" : 250,
}
namespaces["wikisource"]["ca"] = {
    "Page" : 102,
}
namespaces["wikisource"]["hy"] = {
    "Page" : 104,
}
namespaces["wikisource"]["et"] = {
    "Page" : 102,
}
namespaces["wikisource"]["pl"] = {
    "Page" : 100,
}
namespaces["wikisource"]["cy"] = {
    "Page" : 104,
}
namespaces["wikisource"]["en"] = {
    "Page" : 104,
}
namespaces["wikisource"]["id"] = {
    "Page" : 104,
}
namespaces["wikisource"]["el"] = {
    "Page" : 100,
}
namespaces["wikisource"]["hu"] = {
    "Page" : 104,
}
namespaces["wikisource"]["ml"] = {
    "Page" : 106,
}
namespaces["wikisource"]["fr"] = {
    "Page" : 104,
}
namespaces["wikisource"]["ar"] = {
    "Page" : 104,
}
namespaces["wikisource"]["eu"] = {
    "Page" : 250,
}
namespaces["wikisource"]["br"] = {
    "Page" : 102,
}
namespaces["wikisource"]["kn"] = {
    "Page" : 104,
}
namespaces["wikisource"]["lij"] = {
    "Page" : 250,
}
namespaces["wikisource"]["az"] = {
    "Page" : 250,
}
namespaces["wikisource"]["nap"] = {
    "Page" : 250,
}
namespaces["wikisource"]["ta"] = {
    "Page" : 250,
}
namespaces["wikisource"]["te"] = {
    "Page" : 104,
}
namespaces["wikisource"]["vec"] = {
    "Page" : 102,
}
namespaces["wikisource"]["mk"] = {
    "Page" : 250,
}
namespaces["wikisource"]["pt"] = {
    "Page" : 106,
}
namespaces["wikisource"]["yi"] = {
    "Page" : 250,
}
namespaces["wikisource"]["fa"] = {
    "Page" : 104,
}
namespaces["wikisource"]["bs"] = {
    "Page" : 250,
}
namespaces["wikisource"]["sa"] = {
    "Page" : 104,
}
namespaces["wikisource"]["uk"] = {
    "Page" : 250,
}
namespaces["wikisource"]["sl"] = {
    "Page" : 100,
}
namespaces["wikisource"]["zh"] = {
    "Page" : 104,
}
namespaces["wikisource"]["hi"] = {
    "Page" : 250,
}
namespaces["wikisource"]["sah"] = {
    "Page" : 250,
}
namespaces["wikisource"]["bg"] = {
    "Page" : 250,
}
namespaces["wikisource"]["no"] = {
    "Page" : 104,
}
namespaces["wikisource"]["bn"] = {
    "Page" : 104,
}
namespaces["wikisource"]["vi"] = {
    "Page" : 104,
}
namespaces["wikisource"]["zh-min-nan"] = {
    "Page" : 250,
}
namespaces["wikisource"]["eo"] = {
    "Page" : 104,
}
namespaces["wikisource"]["sv"] = {
    "Page" : 104,
}
namespaces["wikisource"]["ro"] = {
    "Page" : 104,
}
namespaces["wikisource"]["tr"] = {
    "Page" : 250,
}
namespaces["wikisource"]["li"] = {
    "Page" : 250,
}
namespaces["wikisource"]["gu"] = {
    "Page" : 104,
}
namespaces["wikisource"]["sr"] = {
    "Page" : 250,
}
namespaces["wikisource"]["as"] = {
    "Page" : 104,
}
namespaces["wikisource"]["da"] = {
    "Page" : 104,
}
namespaces["wikisource"]["old"] = {
    "Page" : 104,
}

As I wrote in T300182#7658336, I don’t understand why this exception is defined as a burnt-in variable in LocalSettings.php (InitialiseSettings.php on Wikimedia) in the first place. If the ProofreadPage extension provides an edit form that’s hard to use with limited width, then let the ProofreadPage extension communicate this to Vector. It would not only make third-party wikis’ lives easier, but also would avoid the issue with the different namespace numbers.

It would be lovely if all these pages could be migrated to a standard set of (reserved) NS numbers for ProofreadPage and have a redirect from the old to the new so that they old will continue to work while all tools are updated and issues resolved.

Yes, switching all Wikisources to use the same namespace ID would be nice; however, even if they all use the same ID, I still think that hardcoding a namespace ID in the Wikimedia configuration is not the appropriate solution for this problem, especially as this doesn’t help third-party wikis. (Also, I don’t know if redirecting from the old namespace ID to the new one is feasible—there’s precedent for redirecting namespace names, but I don’t think there’s a precedent for redirecting namespace numbers. It may be possible to keep the old numbers for reads by creating a bunch of views—although it could result in breaking constraints and/or informal expectations about uniqueness of the data—, but I can’t imagine how it would work for writes.)

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

[operations/mediawiki-config@master] Apply max width setting to all Wikisource page namespaces

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

Change 762928 merged by jenkins-bot:

[operations/mediawiki-config@master] Apply max width setting to all Wikisource page namespaces

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

Mentioned in SAL (#wikimedia-operations) [2022-02-15T21:36:03Z] <urbanecm@deploy1002> Synchronized wmf-config/InitialiseSettings.php: b3e8161445d4f778cab8cbabe709f9583ac62df2: Apply max width setting to all Wikisource page namespaces (T300563; 1/2) (duration: 00m 50s)

Mentioned in SAL (#wikimedia-operations) [2022-02-15T21:36:52Z] <urbanecm@deploy1002> Synchronized wmf-config/CommonSettings.php: b3e8161445d4f778cab8cbabe709f9583ac62df2: Apply max width setting to all Wikisource page namespaces (T300563; 2/2) (duration: 00m 49s)