Page MenuHomePhabricator

Link() and Site.sametitle fail when namespace case is different from site case
Closed, ResolvedPublic

Description

As can be seen at the following, the 'site' has a case in the general chunk, and each namespace can have another case. e.g. User & MediaWiki & Special are not case-sensitive, whereas the other namespaces are.

https://en.wiktionary.org/w/api.php?action=query&meta=siteinfo&siprop=general|namespaces

pywikibot (core and compat) only fetch and use the case rule from the general site data, not for each namespace.


Version: core-(2.0)
Severity: normal

Details

Reference
bz69118

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:35 AM
bzimport set Reference to bz69118.
bzimport added a subscriber: Unknown Object (????).

Also all use of nocapitalize is probably problematic.

Change 151809 had a related patch set uploaded by XZise:
Site.sametitle recognizes namespace capitalisation

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

Change 161676 had a related patch set uploaded by XZise:
[FIX] Only apply uppercase to Link title if namespace dictates so

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

Change 161676 merged by jenkins-bot:
[FIX] Only apply uppercase to Link title if namespace dictates so

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

Change 151809 merged by jenkins-bot:
[FEAT] Improved Site.sametitle

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

jayvdb claimed this task.

Patches merged.