Last modified: 2014-10-15 20:42:22 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T73914, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 71914 - Terms table not updated when deleting properties (deleted properties can still be found by label with wbsearchentities)
Terms table not updated when deleting properties (deleted properties can stil...
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
WikidataRepo (Other open bugs)
unspecified
All All
: High normal (vote)
: ---
Assigned To: Wikidata bugs
u=dev c=backend p=0
:
: 71784 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-10-10 13:48 UTC by tobias.gritschacher
Modified: 2014-10-15 20:42 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description tobias.gritschacher 2014-10-10 13:48:39 UTC
Just discovered this weird issue:
if you search for the label of a deleted property, it is still found.
I've deleted the property with the label "AuWKYzfw", see http://wikidata.beta.wmflabs.org/w/index.php?title=Property:P2345&action=edit&redlink=1

But it can still be found by doing:
http://wikidata.beta.wmflabs.org/w/api.php?action=wbsearchentities&format=json&search=AuWKYzfw&language=en&type=property&limit=10

This also means it can still be selected when adding statements as the property suggester uses wbsearchentities.
Comment 1 tobias.gritschacher 2014-10-10 13:56:07 UTC
This does not apply to items:
http://wikidata.beta.wmflabs.org/w/api.php?action=wbsearchentities&format=json&search=kuzTrkkK&language=en&type=item&limit=10

Above query does not give you any search results which is correct because the item was deleted.
Comment 2 tobias.gritschacher 2014-10-10 14:30:38 UTC
You also cannot create a new property with the same label the deleted one had. Special:NewProperty also gives you a strange error message in case you try:

Property P2345 already has label "AuWKYzfw" associated with language code en.
Property P2345 already has label "ZTMfXXavmfzRtmdtGGAH" associated with language code en.

So P2345 has two labels for language en associated? The second one should be the description.
Comment 3 tobias.gritschacher 2014-10-10 14:36:52 UTC
(In reply to tobias.gritschacher from comment #2)
> You also cannot create a new property with the same label the deleted one
> had. Special:NewProperty also gives you a strange error message in case you
> try:
> 
> Property P2345 already has label "AuWKYzfw" associated with language code en.
> Property P2345 already has label "ZTMfXXavmfzRtmdtGGAH" associated with
> language code en.
> 
> So P2345 has two labels for language en associated? The second one should be
> the description.

This seems unrelated, created another bug for it: https://bugzilla.wikimedia.org/show_bug.cgi?id=71915
Comment 4 tobias.gritschacher 2014-10-10 14:38:07 UTC
(In reply to tobias.gritschacher from comment #0)
> Just discovered this weird issue:
> if you search for the label of a deleted property, it is still found.
> I've deleted the property with the label "AuWKYzfw", see
> http://wikidata.beta.wmflabs.org/w/index.php?title=Property:
> P2345&action=edit&redlink=1
> 
> But it can still be found by doing:
> http://wikidata.beta.wmflabs.org/w/api.
> php?action=wbsearchentities&format=json&search=AuWKYzfw&language=en&type=prop
> erty&limit=10
> 
> This also means it can still be selected when adding statements as the
> property suggester uses wbsearchentities.

The possible cause of the issue is outlined here:
https://bugzilla.wikimedia.org/show_bug.cgi?id=71784
>>It seems like entries in the terms table are not removed when deleting entities. On test.wikidata.org, I created a property called "role" and then deleted it. However, "role" is still shown as a siggestion in the entity selector, and i cannot create a new property with the label "role".<<
Comment 5 tobias.gritschacher 2014-10-10 14:38:43 UTC
*** Bug 71784 has been marked as a duplicate of this bug. ***
Comment 6 Gerrit Notification Bot 2014-10-13 15:26:15 UTC
Change 166425 had a related patch set uploaded by Daniel Kinzler:
Fix entity deletion updates for properties.

https://gerrit.wikimedia.org/r/166425
Comment 7 Gerrit Notification Bot 2014-10-13 16:57:46 UTC
Change 166425 merged by jenkins-bot:
Fix entity deletion updates for properties.

https://gerrit.wikimedia.org/r/166425
Comment 8 Marius Hoch 2014-10-13 17:53:49 UTC
Patch merged... not sure how to deal with the old data still in the table? Worth cleaning that up per hand?
Comment 9 Daniel Kinzler 2014-10-13 20:28:18 UTC
Would be good to delete the orphan entries, yes.
Note that similar orphans are probably present in the entity_per_page table.
Comment 10 Marius Hoch 2014-10-15 20:42:22 UTC
I've no manually purged both the orphan entity per page and the orphan terms table entries. Would be nice to have a maintenance script for that (but not really worth the work atm).

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links