GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||
GeezerVison is showing phabricator.wikimedia.org — T302158 Language conversion fixes in extensions using LanguageConverter are leaking conversion rules outside extension tags
Assigned To None Authored By
Project Tags Referenced Files None
Description List of steps to reproduce (step by step, including full links if applicable):
What happens?: What should have happened instead?: Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc.: Links:
Details Related Changes in Gerrit:
Related Objects Search...
Event TimelineComment Actions Difference between pre, inputbox, templatedata and syntaxhighlight with similar code <pre>: <inputbox>: <templatedata>: <syntaxhighlight>: Comment Actions Note that conversion after extension tag (only) is matching the normal behavior, but it's impossible to achieve. Comment Actions It currently act like this: 1. outer text (unexpected: got converted caused by 4., should not be converted) 2. tag inner text without conversion enabled (expected) 3. outer text (unexpected: got converted caused by 4., should not be converted) 4. tag inner text with tag-wide conversion rules added and conversion enabled (expected) 5. outer text (unexpected: got converted caused by 4., should not be converted) 6. conversion rules removed page-wide 7. outer text (not converted caused by 4. added + 6. removed conversion rules) 8. tag inner text without conversion enabled (expected) 9. outer text (not converted caused by 4. added + 6. removed conversion rules) 10. tag inner text with tag-wide conversion rules added and conversion enabled (expected) 11. outer text (not converted caused by 4. added + 6. removed conversion rules but didn't affected by 10.) Comment Actions Change 763939 had a related patch set uploaded (by Func; author: Func): [mediawiki/core@master] LanguageConverter: Make reloadTables() method public for purging out manual conversion rules Comment Actions The behavior of TemplateData is fine, and PortableInfobox doesn't have a project tag, right? Comment Actions PortableInfobox is an extension made by Fandom with ported versions, so it's outside the scope of Wikimedia Phabricator. Comment Actions Change 763943 had a related patch set uploaded (by Func; author: Func): [mediawiki/extensions/InputBox@master] Purge out manual conversion rules Shizhao moved this task from Backlog to Extensions/Skins on the Chinese-Sites board.Feb 21 2022, 3:27 AM2022-02-21 03:27:24 (UTC+0) Comment Actions See T484: RFC: Scoped language converter as well, and https://wikimedia.slack.com/archives/C024Z8K9CAU/p1660748317850709 for those with access to WMF slack. tl;dr the fundamental issue here is that LanguageConverter for a given language is a global singleton with persistent state. I don't think just making reloadTables public is a good fix, because it doesn't solve the root cause: now all the rules will be wiped after the extension content is processed, which isn't any better than adding rules after the extension content is processed. (T263082 is mentioned here, but it probably has the same issue with language converter rules "leaking" out, although that might be a Feature rather than a Bug in that case.) Restricted Application added a subscriber: Ericliu1912. · View Herald TranscriptAug 17 2022, 6:36 PM2022-08-17 18:36:11 (UTC+0) Winston_Sung moved this task from Extensions/Skins to MediaWiki core on the Chinese-Sites board.Mar 10 2023, 8:43 AM2023-03-10 08:43:15 (UTC+0) Shizhao moved this task from MediaWiki core to Extensions/Skins on the Chinese-Sites board.Mar 13 2023, 2:12 AM2023-03-13 02:12:14 (UTC+0) Winston_Sung moved this task from Backlog to Extensions/Skins on the MediaWiki-Language-converter board.Mar 18 2023, 3:48 AM2023-03-18 03:48:52 (UTC+0) Winston_Sung moved this task from Untriaged to Script & term conversion on the I18n board.Aug 9 2023, 3:14 PM2023-08-09 15:14:18 (UTC+0) Pppery edited projects, added: Patch-Needs-Improvement; removed: Patch-For-Review.Dec 22 2024, 5:23 PM2024-12-22 17:23:00 (UTC+0) Comment Actions Change #763939 abandoned by Hashar: [mediawiki/core@master] LanguageConverter: Make reloadTables() method public for purging out manual conversion rules Comment Actions Change #763939 restored by Thcipriani: [mediawiki/core@master] LanguageConverter: Make reloadTables() method public for purging out manual conversion rules Restricted Application removed a project: Patch-Needs-Improvement. · View Herald TranscriptMar 30 2026, 11:17 PM2026-03-30 23:17:37 (UTC+0) Pppery edited projects, added: Patch-Needs-Improvement; removed: Patch-For-Review.Mar 31 2026, 1:56 AM2026-03-31 01:56:55 (UTC+0) Content licensed under Creative Commons Attribution-ShareAlike (CC BY-SA) 4.0 unless otherwise noted; code licensed under GNU General Public License (GPL) 2.0 or later and other open source licenses. By using this site, you agree to the Terms of Use, Privacy Policy, and Code of Conduct. · Wikimedia Foundation · Privacy Policy · Code of Conduct · Terms of Use · Disclaimer · CC-BY-SA · GPL · Credits | |||||||||||||||||||||||||||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |