DAlangi_WMF added a comment.
In T350806#9412606 <https://phabricator.wikimedia.org/T350806#9412606>, @Krinkle wrote: > @DAlangi_WMF The problematic hook that initiated this task (via the parent task) is `onPageContentLanguage()` which is called by Title->getPageViewLanguage(), but not directly. The hook call resides in `ContentHandler::getPageViewLanguage() -> ContentHandler->getPageViewLanguage()`. > > The reason Wikibase is out of scope, is that it implements a custom method called `getPageViewLanguage` in a subclass of ContentHandler, and shares no code with the base class in core. After we deprecate and remove this, the Wikibase continues to work on its own. > > CommonsMetadata, however, does call into the affected core code. It makes the same kind of mistake as the other extensions we patched in this task, namely it deals with a ParserOutput, but instead of asking the ParserOutput object what the language of the HTML is, it tries to "guess" by invoking global state of `ContentHandler::getPageViewLanguage`. Ack! I'll review and test the patch you made. Thanks for clarifying. 🙏🏽 TASK DETAIL https://phabricator.wikimedia.org/T350806 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: DAlangi_WMF Cc: xSavitar, Tgr, WMDE-leszek, Michael, matmarex, Aklapper, Krinkle, Danny_Benjafield_WMDE, Isabelladantes1983, Themindcoder, Mohamed-Awnallah, Adamm71, Jersione, Hellket777, mrephabricator, LennardHofmann, LisafBia6531, Astuthiodit_1, 786, lbowmaker, BTullis, Biggs657, karapayneWMDE, toberto, Invadibot, Ywats0ns, caldera, maantietaja, Juan90264, Alter-paule, NavinRizwi, Beast1978, CBogen, ItamarWMDE, Un1tY, Akuckartz, Hook696, Kent7301, joker88john, 94rain, CucyNoiD, Nandana, Gaboe420, lucamauri, Patriccck, Giuliamocci, Cpaulf30, Lahi, Gq86, Af420, Ramsey-WMF, Bsandipan, GoranSMilovanovic, TJH2018, Nattes, QZanden, EnricoCNC, LawExplorer, Lewizho99, Maathavan, SundanceRaphael, _jensen, rosalieper, Taiwania_Justo, Neuronton, Scott_WUaS, Izno, alex-mashin, Wikidata-bugs, aude, geraki, Dinoguy1000, Gryllida, jeblad, jayvdb, MrStradivarius, Tacsipacsi, Catrope, Jackmcbarn, Mbch331
_______________________________________________ Wikidata-bugs mailing list -- [email protected] To unsubscribe send an email to [email protected]
