Last modified: 2008-10-28 15:42:08 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T18158, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 16158 - generator=links barfs if a link is registered in negative namespaces
generator=links barfs if a link is registered in negative namespaces
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
API (Other open bugs)
1.14.x
All All
: Normal major (vote)
: ---
Assigned To: Roan Kattouw
http://de.wikipedia.org/w/api.php?act...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-10-28 10:24 UTC by Splarka
Modified: 2008-10-28 15:42 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Splarka 2008-10-28 10:24:07 UTC
It is currently possible to register links to negative namespaces. 

A link to a non-existing Special: page like [[Special:Foobarbaz]] will show <pl ns="-1" title="Special:Foobarbaz" />, and an image link= like [[Image:Foo|link=Special:UserLogin]] to either an existing or non-existing Special page will show <pl ns="-1" title="Special:UserLogin" />. This last one is rather more buggy than the other. This can also be done with Media: (-2) namespace links in image link=.

These are perhaps not ideal situations, but as there are multiple methods of accidentally doing it, perhaps the API should do a sanity check and ignore -1 namespaces for generator?

See also:
http://test.wikipedia.org/w/api.php?action=query&prop=links&titles=Flibble
http://test.wikipedia.org/w/api.php?action=query&generator=links&titles=Flibble

(test cases are fragile, subject to later repair)
Comment 1 Roan Kattouw 2008-10-28 15:42:08 UTC
Bug as filed fixed in r42732. The 'unsupportednamespace' error has become a warning so at least it's not broken any more. This is a temporary solution until we figure out what to do with negative namespace titles; see also bug 16162.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links