Lucas_Werkmeister_WMDE added a comment.

  Using `CONN_TRX_AUTOCOMMIT` for the conflict lookup has an unexpected side 
effect, though. I just got this error message from the API:
  
  counterexample
    The link <a rel="nofollow" class="external text" 
href="http://localhost/wiki1/index.php/True_duplicate";>wiki1:True duplicate</a> 
is already used by Item <a 
href="/wiki1/index.php?title=Item:Q2546&action=edit&redlink=1" class="new" 
title="Item:Q2546 (page does not exist)">Q2546</a>. You may remove it from <a 
href="/wiki1/index.php?title=Item:Q2546&action=edit&redlink=1" class="new" 
title="Item:Q2546 (page does not exist)">Q2546</a> if it does not belong there 
or merge the Items if they are about the exact same topic.
  
  The conflict lookup correctly detected the conflict with Q2546, but the rest 
of MediaWiki was working in a transaction that started before that item had 
been committed, so it thought the item doesn’t exist and the link became a 
redlink. I don’t think there’s anything we can do about this – the message is 
rendered wikitext, the link is a wikilink, we can’t just replace a call to 
`LinkRenderer::makeLink()` with `makeKnownLink()` and call it a day.
  
  On the other hand, I’m pretty sure this error was already possible (albeit 
unlikely) before: if request A deletes an item, commits, request B starts with 
an attempt to create another item with the same sitelink, and request A’s 
secondary data updates only run afterwards (deleting the item’s sitelinks from 
the database), then request B will still detect a conflict, but will already 
see that item as deleted, so it should render a redlink as well.

TASK DETAIL
  https://phabricator.wikimedia.org/T291377

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: Aklapper, hoo, Lea_Lacroix_WMDE, Mohammed_Sadat_WMDE, Lydia_Pintscher, 
Addshore, Lucas_Werkmeister_WMDE, Suran38, Biggs657, Invadibot, Lalamarie69, 
maantietaja, Juan90264, Alter-paule, Beast1978, Un1tY, Akuckartz, Hook696, 
Iflorez, Kent7301, alaa_wmde, joker88john, CucyNoiD, Nandana, Gaboe420, 
lucamauri, Giuliamocci, Cpaulf30, Lahi, Gq86, Af420, Bsandipan, 
GoranSMilovanovic, QZanden, LawExplorer, Lewizho99, Maathavan, _jensen, 
rosalieper, Scott_WUaS, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to