Lucas_Werkmeister_WMDE added a comment.

I’m not sure how this would look – non-static serialize and static deserialize methods on Context and its subclasses? Or should it be a separate kind of ContextSerialization service? I think my colleagues know more about this than me, there’s a lot of serialization going on in Wikibase ;)

Separate ContextSerializer and ContextDeserializer is probably the way to go, in analogy to some other (de)serializers we already have in WBQC and also in Wikibase.

Different question: a Context currently holds an EntityDocument, which many checkers also assume is a StatementListProvider. Obviously, we don’t want to serialize the full entity… what do we do? Return some fake EntityDocument that only holds the ID and nothing else, and document that deserialized contexts cannot be used to actually check the constraint? Or return some kind of EntityDocument that lazily loads the real underlying object (using an underlying EntityLookup)? Or restructure Context into a more convenient form?


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

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

To: Lucas_Werkmeister_WMDE
Cc: Aklapper, Lucas_Werkmeister_WMDE, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Agabi10, abian, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to