Page MenuHomePhabricator

🐙 Add the field to DataTypeDefinitions
Closed, ResolvedPublic

Description

  • Ponder the name a bit. Parser vs deserializer…

Event Timeline

If I'm not mistaken there is already a field in DataTypeDefinitions for exactly this purpose called parser-factory-callback. From the docs: "ValueParser for this data type" which is what we want. Looking through the code, this field so far was effectively only used for *value* type definitions. A few extensions do use it (codesearch) for data type definitions, but most (all of the ones active on wikidata) only copied the default code for the corresponding value type, which doesn't have any effect.

I believe this means that there is no code to be written for this task. For T360605 we just need to elaborate on the consequences of using it and change the docs entry from "repo only" to "client and repo".