Repository navigation
fix(i18n): disable Crowdin content segmentation on the README - #804
Conversation
Crowdin defaults content_segmentation to 1. On a Markdown file that splits the source into sentence-level segments and, per their own docs, routes the translation upload through "experimental machine learning technology". On README.md that reassembled the <details>/<summary> release-history blocks out of order, emitted broken HTML (stray </summary>, orphaned </em>), and spliced English source text into the German and zh-CN output while keeping mismatched links. What identified it: the UI locale JSON came through the same sync clean (+256 lines, zero deletions, all 16 files valid), while the six READMEs churned +169/-159. Segmentation does not apply to JSON, so the split ran exactly along the boundary the setting predicts. The release-history blocks were reordered rather than renumbered -- rc.13/rc.12/rc.11 in the source came back rc.12/rc.11/rc.13 -- which is reassembly, not translation memory. Also turned off in the Crowdin UI (file 39; 446 sentence segments -> 382 block ones, revision 6 -> 7) along with enabling Exclude code blocks, which had been sending fenced code out for translation. This config entry is the guard so a project re-create or a fresh upload cannot silently restore the default. Refs: #801
|
Deployment failed for project drydock-website with the following error: |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review. 📝 WalkthroughWalkthroughThe Crowdin README configuration now sets Possibly related PRs
Merge Risk: ⚪ Minimal · up to This localized configuration and test update is merge-ready after normal checks; no actionable merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
…ey gaps (#920) * fix(i18n): stop Crowdin reverting the translated READMEs, close the key gaps Two failures with the same root: the sync was trusted to fill in what the repo had not translated, and what it actually fills in is verbatim English. README.md was registered as a Crowdin source, so every sync round-tripped the six hand-translated READMEs through the project. Turning off content segmentation in #804 to fix an earlier corruption renumbered every segment, which orphaned the stored translations from the strings they belonged to, and Crowdin exports source text for anything it cannot match. The next sync opened as PR #919 deleting 1392 lines of translated README across all six files, caught only because readme-translations.test.ts failed 30 assertions. Crowdin no longer maps README.md: those files are hand-authored in-repo and asserted phrase by phrase at every cut, nobody translates them in Crowdin, and the mapping only ever produced a PR that undid the work. The workflow's push trigger drops README.md for the same reason, and the assertion in crowdin-workflow.test.ts is inverted so re-adding the mapping fails CI. The eleven action-policy keys are the other half. The Auto/Manual/Blocked badge and its three state tooltips, on both the update-status panel and the per-trigger rows, were added to the English catalog only in #761, so they rendered in English for every non-English user from that release on. Now translated in all 16 locales, matching each file's existing terminology rather than a general rule, with the dd.action.* label names left literal. key-parity.spec.ts used to tolerate a key present in en and absent from a locale, on the documented grounds that "Crowdin fills after push". It does not, and a gap filled with English is worse than an open one because it reads as a finished translation to every later check. That direction now fails, with the offending locale/namespace/key listed. The cost is that a PR adding a UI string has to translate it in the same change, which is the intended trade. * fix(i18n): use the consonant-form Korean particle after Drydock Korean picks a particle by whether the preceding syllable ends in a consonant or a vowel. Drydock reads 드라이독, which ends in ㄱ, so it takes 이/은/을/과/으로 and never 가/는/를/와/로. CodeRabbit caught `Drydock가` in the actionPolicyTooltip string added by the previous commit; two more were already in the catalog beside it, in updateStatus.summary.notify and in configView, both from Crowdin. Every other Drydock in ko already used the consonant forms, so these three were the outliers. Nothing flagged them, which is the same shape as the gap this branch is about: key-parity compares structure, placeholder-parity compares braces, and no-raw-text only looks for English leaking into templates. The new korean-particles gate reads every ko namespace and fails on a vowel-form particle attached to a name whose Korean reading ends in a consonant, with the offending line and the correction. It is deliberately keyed on a short list rather than applied to every proper noun, because Docker reads 도커 and is vowel-final, so `Docker가` is correct and a blanket rule would flag it. The two Crowdin-stored strings may come back on a sync: re-uploading a corrected translation adds a candidate alongside the stored one instead of replacing it, the same behaviour that produced #919 on the READMEs. The gate is what makes that loud instead of silent.
Fixes the corruption that makes #801 unmergeable.
Root cause
Crowdin defaults
content_segmentationto1. On a Markdown file that splits the source into sentence-level segments and, per Crowdin's own docs, routes the translation upload through "experimental machine learning technology". Nobody enabled it — it was the default, applied to a README dense with inline HTML.On
README.mdthat produced:<details>/<summary>release-history blocks reassembled out of order — sourcerc.13, rc.12, rc.11came backrc.12, rc.11, rc.13</summary>, orphaned</em>) in zh-CNHow it was identified
The UI locale JSON came through the same sync clean — +256 lines, zero deletions, all 16 files valid JSON — while the six READMEs churned +169/−159. Segmentation doesn't apply to JSON, so the damage split exactly along the boundary the setting predicts.
That also ruled out the translation-memory hypothesis the corruption first suggested: the release blocks were reordered, not renumbered. The full set
{rc.11, rc.12, rc.13}was present and correctly spelled in both source and output, just in a different order. Stale TM produces wrong values; this produced right values in the wrong places, which is reassembly.What changed
crowdin.yml:content_segmentation: 0on the README entry..github/tests/crowdin-workflow.test.ts: the existing shape guard updated to pin the new key, with the reasoning inline so deleting it isn't a silent regression. That guard is why this PR needed a second push — it caught the config change immediately.The config entry is the guard, not the fix: it stops a project re-create or fresh upload from silently restoring the default.
Not done yet
l10n_crowdinstill holds the corrupt output. Next is re-uploading the known-good translations fromdev/v1.7against the new segmentation, re-running the sync, and confirming.github/tests/readme-translations.test.tsgoes 12 failed → 0. #801 must not merge as-is.Refs: #801
Changelog
crowdin.ymlto setcontent_segmentation: 0forREADME.md.content_segmentation: 0.Concerns
l10n_crowdin.