Last modified: 2014-07-16 09:02:49 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 T68791, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 66791 - Do not omit empty fields from JSON
Do not omit empty fields from JSON
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
WikidataRepo (Other open bugs)
unspecified
All All
: Highest blocker (vote)
: ---
Assigned To: Wikidata bugs
u=dev c=backend p=3 s=2014-07-15
:
Depends on: 66839
Blocks:
  Show dependency treegraph
 
Reported: 2014-06-18 16:03 UTC by Daniel Kinzler
Modified: 2014-07-16 09:02 UTC (History)
5 users (show)

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


Attachments

Description Daniel Kinzler 2014-06-18 16:03:52 UTC
The new serialization code, Serializers\EntitySerializer, omits empty fields from the data structure. E.g. if there are no descriptions set, addDescriptionsToSerialization() will do nothing instead of adding $serialization['descriptions'] = array();

This is a breaking change versus the old serialization code, compare getSerialized() in Wikibase\Lib\Serializers\EntitySerializer.

This leads to some parts of the JSON representation being optional, which forces consumers to always check for preses. This is likely to break existing consumers (bots, gadgets, etc).
Comment 2 Lydia Pintscher 2014-07-01 12:20:27 UTC
Current status: Seems to only still need to be done for claims.
Comment 4 tobias.gritschacher 2014-07-15 12:16:45 UTC
claims are missing.

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


Navigation
Links