Page MenuHomePhabricator

Autosuggest-Gadget disconnects other entries
Closed, ResolvedPublicBUG REPORT

Description

Hello,

with article

https://de.wikipedia.org/wiki/Moritz_Hartlieb_von_Wallthor

the AutoSuggest-Gadget suggested only a single object

https://www.wikidata.org/w/index.php?title=Q23542343&action=history

which has already been connected to article

https://de.wikipedia.org/wiki/Wladimir_von_Hartlieb

Should AutoSuggest-Gadget exclude objects, which are already connected to other articles in the same language?

Or at least give a warning, that the connection has been changed and the other article has been disconnected?

Details

TitleReferenceAuthorSource BranchDest Branch
Autosuggestsitelink.js: Check if wikidata item already has other sitelinksrepos/commtech/autosuggest-sitelink!35s-mukutiT329968main
Customize query in GitLab

Event Timeline

Restricted Application added a subscriber: Aklapper. ยท View Herald TranscriptFeb 17 2023, 5:58 PM

s-mukuti opened https://gitlab.wikimedia.org/repos/commtech/autosuggest-sitelink/-/merge_requests/35

Autosuggestsitelink.js: Check if wikidata item already has other sitelinks

samtar merged https://gitlab.wikimedia.org/repos/commtech/autosuggest-sitelink/-/merge_requests/35

Autosuggestsitelink.js: Check if wikidata item already has other sitelinks

Is this ready for QA? Also let me know if when a good time is to update the gadget. I see as of the time of writing, meta:MediaWiki:Gadget-AutosuggestSitelink.js is ~81 days out of date. I assume we'll want QA to look at this before we deploy our next "stable" version.

Is this ready for QA? Also let me know if when a good time is to update the gadget. I see as of the time of writing, meta:MediaWiki:Gadget-AutosuggestSitelink.js is ~81 days out of date. I assume we'll want QA to look at this before we deploy our next "stable" version.

Yup, according to @S_Mukuti this is ready for QA :) โ€” I assume QA will use the version at https://gitlab.wikimedia.org/repos/commtech/autosuggest-sitelink and once confirmed we can update the gadget?

@S_Mukuti I just wanted to validate a couple of things with you if this is the results you wanted and I also came up with a side issue as seen below. Please let me know if you want me to create separate tasks for any or just however you want me to proceed, thanks!

Test links:
https://test.wikipedia.org/wiki/Cheesesteak
https://test.wikipedia.org/wiki/Philly_taco
https://test.wikidata.org/wiki/Q231553

I created a test wikidata and a test site called "Cheesesteak". I linked the article "Cheesesteak" with the Wikidata item. Is this what you want with the "Site link created", which I thought was fine but it followed with a "This article is already linked to an item". Shouldn't the 2nd part be removed since you are linking it for the first time and should only appear when you click Autosuggest again on that article?

T329968_Autosuggest_Linking_Wikidata.png (1ร—2 px, 349 KB)

Once "Cheesesteak" was linked, I create another article called "Philly taco" and tried to link it with the "cheesesteak" wikidata. Is that the warning you wanted? Also shouldn't the warning appear after the wikidata description besides in the middle of the wikidata item since it looks like it's part of the wikidata item? Also to distinguish it better, should we have the letters bold or anything to make it stick out more? Once you select the item and Submit, I was able to link it to "Philly taco" which now "Cheesesteak" is now unlinked to the wikidata.

T329968_Autosuggest_Linking_WikidataWarning.png (1ร—2 px, 286 KB)

Side error that I came across. When I was creating a new article of "Philly taco" which the "cheeseteak" wikidata did not have an alias of "Philly taco" yet. The Autosuggest link popped up as designed but if I do an edit since you can't close the popup unless you refresh the screen, each edit creates a new Autosuggest popup which doesn't go away so you end up with multiples on the side.

T329968_Autosuggest_Linking_MultiplePopups.png (1ร—2 px, 336 KB)

@S_Mukuti I just wanted to validate a couple of things with you if this is the results you wanted and I also came up with a side issue as seen below. Please let me know if you want me to create separate tasks for any or just however you want me to proceed, thanks!
Test links:
https://test.wikipedia.org/wiki/Cheesesteak
https://test.wikipedia.org/wiki/Philly_taco
https://test.wikidata.org/wiki/Q231553
I created a test wikidata and a test site called "Cheesesteak". I linked the article "Cheesesteak" with the Wikidata item. Is this what you want with the "Site link created", which I thought was fine but it followed with a "This article is already linked to an item". Shouldn't the 2nd part be removed since you are linking it for the first time and should only appear when you click Autosuggest again on that article?

T329968_Autosuggest_Linking_Wikidata.png (1ร—2 px, 349 KB)

Once "Cheesesteak" was linked, I create another article called "Philly taco" and tried to link it with the "cheesesteak" wikidata. Is that the warning you wanted? Also shouldn't the warning appear after the wikidata description besides in the middle of the wikidata item since it looks like it's part of the wikidata item? Also to distinguish it better, should we have the letters bold or anything to make it stick out more? Once you select the item and Submit, I was able to link it to "Philly taco" which now "Cheesesteak" is now unlinked to the wikidata.

T329968_Autosuggest_Linking_WikidataWarning.png (1ร—2 px, 286 KB)

Side error that I came across. When I was creating a new article of "Philly taco" which the "cheesesteak" wikidata did not have an alias of "Philly taco" yet. The Autosuggest link popped up as designed but if I do an edit since you can't close the popup unless you refresh the screen, each edit creates a new Autosuggest popup which doesn't go away so you end up with multiples on the side.

I could not replicate this from my end, it seems to work as expected and has only one popup at a time. When I do an. edit the popup disappears. Perhaps the best solution is to ensure that the popup can be closed as suggested on https://phabricator.wikimedia.org/T329335

T329968_Autosuggest_Linking_MultiplePopups.png (1ร—2 px, 336 KB)

@GMikesell-WMF For the first one the notice "This article is already linked to an item" should only appear when an article is already linked to a Wikidata item" but not when it is linked for the first time.
For the second scenario, perhaps it is a good idea to consider changing the position of the warning to be after the description of the Wikidata item.
The issue of multiple pop-ups seemed to have been resolved in a previous patch but I will have a look to see why it is still appearing in this case. I don't think it requires a separate task.

@S_Mukuti

@GMikesell-WMF For the first one the notice "This article is already linked to an item" should only appear when an article is already linked to a Wikidata item" but not when it is linked for the first time.

Yeah, it's weird this is coming off a new article that I created and linking it for the first time but still getting "This article is already linked to an item" pop up with it. Did you want me to create a task or you will fix it off of this same task?

For the second scenario, perhaps it is a good idea to consider changing the position of the warning to be after the description of the Wikidata item.

Did you want me to create a separate task or will you fix it off this task regarding positioning it after the description? Also, what do you think of making it bold, different color, or *<text>* for "Proceeding with this action will unlink item from another article" so the user can make sure they don't miss it when there are multiple wikidata items? It could be a design question but up to you.

The issue of multiple pop-ups seemed to have been resolved in a previous patch but I will have a look to see why it is still appearing in this case. I don't think it requires a separate task.

Ok keep me posted on this and let me know if you can resolve it or if it's more than that and I should create a new task. Thanks!

Created a followup task for the popup bug. T340547, Moving this task to done.