Keys added to src/resources/language/_language.yml are not propagated to the per-language translation files, and nothing in the test suite or CI catches it. Auditing the 30 base language files against _language.yml at b69ed2dde16d1b502dcdddace4eebae5038550e3:
tools-share and tools-download are missing from 25 of the 30. They were added in January 2024 for the book tools menu, so all those languages have been showing English "Download" and "Share" there since.
ko is also missing title-block-modified, added September 2022.
sr-Latn is also missing code-links-title, launch-binder-title, launch-dev-container-title, listing-page-field-wordcount and listing-page-words, all added in 2023.
lt still carries search, which was renamed to search-label in May 2023. The Lithuanian search label falls back to English.
sv still carries callout-danger-title, which was renamed to callout-caution-title in February 2023. The Swedish caution callout title falls back to English.
Only bg, es, eu, is and sl are complete.
The region variants de-CH, fr-CA, pt-BR and zh-TW are not affected. They are read as overlays on top of their base language, so being partial is the point:
|
if (lang) { |
|
// enumerate variations dictated by this lang |
|
const subtags = lang.split("-"); |
|
for (let i = 0; i < subtags.length; i++) { |
|
variations.push(subtags.slice(0, i + 1).join("-")); |
|
} |
A check would stop this recurring
We could add a test that reads _language.yml and every _language-*.yml and fails when a base language file misses a key, or when any file carries a key that no longer exists in _language.yml. The region variants would be exempt from the missing-key half but not from the unknown-key half, which is what would have caught lt and sv.
Without something like that the drift restarts the next time a key is added. This is separate from #14772, which is about custom keys supplied by users.
Worth saying that a check only surfaces the gaps. Filling them is translation work for people who speak the language, not something to bulk fill with machine output.
Keys added to
src/resources/language/_language.ymlare not propagated to the per-language translation files, and nothing in the test suite or CI catches it. Auditing the 30 base language files against_language.ymlatb69ed2dde16d1b502dcdddace4eebae5038550e3:tools-shareandtools-downloadare missing from 25 of the 30. They were added in January 2024 for the book tools menu, so all those languages have been showing English "Download" and "Share" there since.kois also missingtitle-block-modified, added September 2022.sr-Latnis also missingcode-links-title,launch-binder-title,launch-dev-container-title,listing-page-field-wordcountandlisting-page-words, all added in 2023.ltstill carriessearch, which was renamed tosearch-labelin May 2023. The Lithuanian search label falls back to English.svstill carriescallout-danger-title, which was renamed tocallout-caution-titlein February 2023. The Swedish caution callout title falls back to English.Only
bg,es,eu,isandslare complete.The region variants
de-CH,fr-CA,pt-BRandzh-TWare not affected. They are read as overlays on top of their base language, so being partial is the point:quarto-cli/src/core/language.ts
Lines 77 to 82 in b69ed2d
A check would stop this recurring
We could add a test that reads
_language.ymland every_language-*.ymland fails when a base language file misses a key, or when any file carries a key that no longer exists in_language.yml. The region variants would be exempt from the missing-key half but not from the unknown-key half, which is what would have caughtltandsv.Without something like that the drift restarts the next time a key is added. This is separate from #14772, which is about custom keys supplied by users.
Worth saying that a check only surfaces the gaps. Filling them is translation work for people who speak the language, not something to bulk fill with machine output.