Page MenuHomePhabricator

Improve code quality in the entity usage deduplicator in Wikibase
Open, In Progress, Needs TriagePublic

Description

[Needs prioritisation] & More understanding of overall core issue.

Make the assumptions in the UsageDeduplicator code explicit, log an error if the assumption is broken, but handle gracefully (do not let it crash)

This need was brought to our attention by this production error T428620: TypeError: Wikibase UsageDeduplicator::deduplicateStatementUsages(): Argument must be of type array (Warning: Undefined array key "C") (☀️)

Todo:

  • Check what the assumptions are (e.g. there should be no CQR usage without C usage)

Event Timeline

Zaidusyy subscribed.

Hello! I'd like to work on this task. I am currently looking into the implementation and plan to submit a patch for review.

Change #1302871 had a related patch set uploaded (by Zaidusyy; author: Zaidusyy):

[mediawiki/extensions/Wikibase@master] Fix TypeError in UsageDeduplicator for missing C usage

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

Zaidusyy changed the task status from Open to In Progress.Fri, Jul 24, 10:11 PM