Lucas_Werkmeister_WMDE added a comment.

I forgot one thing… CheckResult also has getters for the snak type and data value, which are used in the special page. We definitely don’t want to add the data value to the cache, but I’m not sure how we can keep the special page functionality in that case…

I’m still not sure how to solve this… we have all the information, in theory, since the special page doesn’t use the cache, so the only time when we’re interested in the snak type and data value, we also have access to them. But the question is how to reconcile that inside the CheckResult class.

For now, since the CheckResult constructor accepts both Context and ContextCursor, we could extract the snak type and data value into separate fields, and populate them in the constructor only if the constructor argument was a full Context. That’s not very nice, but it works.

In the long term, perhaps we should split up these “full check results” and “deserialized check results” into two classes…


TASK DETAIL
https://phabricator.wikimedia.org/T185712

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: gerritbot, Ladsgroup, Aklapper, Lucas_Werkmeister_WMDE, Giuliamocci, Adrian1985, Cpaulf30, Lahi, Gq86, Baloch007, Darkminds3113, Lordiis, GoranSMilovanovic, Adik2382, Th3d3v1ls, Ramalepe, Liugev6, QZanden, LawExplorer, Lewizho99, Maathavan, Agabi10, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to