Ladsgroup added a comment.
In T205045#5382778 <https://phabricator.wikimedia.org/T205045#5382778>, @hoo wrote: > Yeah, this is on purpose⦠this is rather complex (unfortunately). The thing is that we make sure that usage are "correct" by: Immediately purging no-longer accurate usages on page touches/ re-parses on edit (it might be that we also add new usages here, but that's not technically needed), then we later on add all usage to the table that come up when parsing the page in different ways (different language, mostly, maybe exclusively). Thanks for explaining, Since it's intentional, I don't replace the thing but I have struggle understanding what is the usecase. Can you give me an example of a case that the hook fails to add the new usages but the job can do? > Possible improvements: > Either (I prefer this): > > - Only remove usages outdated usages in `UsageUpdater` (synchronous), don't add any new ones > - Only `INSERT` actually new usages in `AddUsagesForPageJob` > > Or: > > - Update usages in `UsageUpdater` (synchronous, on page update), like it is done now > - Only inject `AddUsagesForPageJob` if that hasn't happened > - Only `INSERT` actually new usages in `AddUsagesForPageJob` The latter is sorta already implemented. The second bullet point is already live. TASK DETAIL https://phabricator.wikimedia.org/T205045 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Ladsgroup Cc: alaa_wmde, Lucas_Werkmeister_WMDE, Joe, mobrovac, Pchelolo, Michael, Lydia_Pintscher, jcrespo, Ladsgroup, hoo, Addshore, Marostegui, Aklapper, Krinkle, Hook696, Daryl-TTMG, RomaAmorRoma, 0010318400, E.S.A-Sheild, darthmon_wmde, joker88john, DannyS712, CucyNoiD, Nandana, NebulousIris, Gaboe420, Versusxo, Majesticalreaper22, Giuliamocci, Adrian1985, Cpaulf30, Lahi, Gq86, Af420, Darkminds3113, Bsandipan, Lordiis, GoranSMilovanovic, Adik2382, Th3d3v1ls, Ramalepe, Liugev6, QZanden, LawExplorer, WSH1906, Lewizho99, Maathavan, _jensen, rosalieper, Jonas, Wikidata-bugs, aude, Jdforrester-WMF, Mbch331, Jay8g, Krenair
_______________________________________________ Wikidata-bugs mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs
