Special:Upload fails on ":w:" as destination filename
Open, Needs TriagePublic


Steps to reproduce:

Actual result:

  • The spinner does not stop.
  • In the JavaScript console the error TypeError: result.query.pages is undefined occurs.

The API request https://www.mediawiki.org/w/api.php?action=query&format=json&formatversion=2&titles=W%3A&prop=imageinfo&iiprop=uploadwarning returns

  "batchcomplete": true,
  "query": {
    "normalized": [
        "fromencoded": false,
        "from": "W:",
        "to": "w:"
    "interwiki": [
        "title": "w:",
        "iw": "w"

The expected key query.pages is missing in the response.

Fomafix created this task.Jan 29 2018, 4:52 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJan 29 2018, 4:52 PM
Anomie moved this task from Unsorted to Blocked on the MediaWiki-API board.Jan 30 2018, 2:14 PM
Anomie added a subscriber: Anomie.

You didn't specify any local titles, only an interwiki title. The API returned it as such.

The query key being absent when no local titles are supplied is longstanding API behavior, and is already filed as T33901: API: action=query with empty title set should still respond with "query" element. See that task for further discussion.