In T207479 some traces were identified showing exceptions.
During the task breakdown we decided the ticket probably needed a different fix than just catching the exceptions.
SPIKE 4 hours
There are various combinations that need to be checked
- datavalue type, no datatype
- matching types
- mismatching types
Conclusions
For values that look like entityids the datavalue type should be wikibase-entityid
- Everything works to plan when the value is an entityid and matching datatype is supplied
- For mismatched types:
- If the datatype is unknown returns unknown datatype
- If the datatype is one of monolingualtext quantity string time external-id wikibase-item wikibase-property and id is item or property return nice human link to entity
- If the datatype is one of monolingualtext quantity string time external-id wikibase-item wikibase-property and id is lexeme (sub) id return link only to lexeme entity and no human readable string
- If the datatype is one of url commonsMedia geo-shape tabular-data returns internal_api_error_InvalidArgumentException
- If the datatype is wikibase-lexeme but id is not lexeme id returns internal_api_error_InvalidArgumentException
- If the datatype is wikibase-form but existent lexeme or sense id provided causes fatal error
- If the datatype is wikibase-form and non-existent sense id provided return link to deleted sense
- If the datatype is wikibase-form and non-existent lexeme id provided returns internal_api_error_InvalidArgumentException
- If the datatype is wikibase-sense and a non-sense id is provided causes fatal error