|Resolved||None||T246124 [EPIC ] Use Wikidata properties to manually add statements about local items|
|Resolved||None||T248838 Select a federated property to make a statement|
|Resolved||Jakob_WMDE||T248852 Avoid calling wbgetentities to get a property's data type|
It looks like we can avoid the extra wbgetentities call in most cases. As far as I can see there are three different cases, only two of which are interesting for us in the federated properties context.
- When using the property search field and adding a new statement for a property for which there is no existing statement on the entity we're editing. In this case we can take the data type from the wbsearchentities response.
- When adding a new value for an existing statement group on the entity. In this case no wbsearchentities request happens, but we can take the data type from the entity data available on the page.
- When using the property suggester (no searching) and adding a new statement for a property for which there is no existing statement on the entity we're editing. In that case no wbsearchentities happens either, but we can just keep making the wbgetentities call in that case. Federated properties is not meant to work with PropertySuggester for now and it will work once we get to wbgetentities.
Proof of concept patch: https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikibase/+/584922