Last modified: 2014-10-28 23:28:35 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 T73135, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 71135 - Strange `{_: "..."}` in artist/credit
Strange `{_: "..."}` in artist/credit
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
CommonsMetadata (Other open bugs)
unspecified
All All
: Unprioritized normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on: 72652
Blocks: 66564
  Show dependency treegraph
 
Reported: 2014-09-22 20:15 UTC by C. Scott Ananian
Modified: 2014-10-28 23:28 UTC (History)
4 users (show)

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


Attachments

Description C. Scott Ananian 2014-09-22 20:15:39 UTC
See:
https://en.wikipedia.org/wiki/Special:ApiSandbox#action=query&prop=imageinfo&format=json&iiprop=extmetadata&iilimit=10&titles=File%3ABlack_Hawk_Down_Super64_over_Mogadishu_coast.jpg

Several fields have `_: "<some text>"` as their value, instead of (as expected) a human-readable string.  For example:
```
"ObjectName": {
  "value": {
    "_": "Sold 12 Nws "
  },
  "source": "file-metadata",
  "hidden": ""
},
"ImageDescription": {
  "value": {
    "_": "Michael Durant's helicopter over Mogadishu. Mike Goodale rode on this one."
  },
  "source": "file-metadata"
},
"Artist": {
  "value": {
    "_": "LABCOPY"
  },
  "source": "file-metadata"
},
"Credit": {
  "value": {
    "_": "INQ LABCOPY"
  },
  "source": "file-metadata",
  "hidden": ""
},
```

This is crashing the OCG bundler, which expects the `value` property to contain a human-readable string, not a JSON object.
Comment 1 Mark Holmquist 2014-09-22 20:19:43 UTC
We're fairly sure that this is happening because the file has an EXIF author and source, but no information template.

But I can't verify that because there are basically no other files like that.
Comment 2 Tisza Gergő 2014-09-23 13:29:33 UTC
I think this happens when the EXIF data contains a child XML tag where an attribute would be expected. The _ key is a quirk of the MediaWiki API when it encounters data which cannot be trivially converted from XML to JSON (or vice versa).

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


Navigation
Links