From e9b2d548da7ea513c2be2c22db46577aab8f9d36 Mon Sep 17 00:00:00 2001 From: Sam Mason de Caires Date: Mon, 10 Aug 2026 15:16:03 +0100 Subject: [PATCH] chore: remove crowdin i18n integration MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Crowdin sync has been broken since May 2025 — the scheduled download workflow has failed on every run since (git auth failure, exit 128), so no translations have flowed in for ~14 months. Remove the integration and keep the catalogs in-repo: - delete crowdin.yml and the download/upload workflows - document the Lingui-only flow in CONTRIBUTING.md - strip stale X-Crowdin-* headers from the non-English catalogs No runtime change: translations still ship from the committed .po files. i18n-check.yml was already Crowdin-independent and is now the sole i18n CI guard. Co-Authored-By: Claude Opus 5 (1M context) --- .github/workflows/crowdin-download.yml | 63 ------------- .github/workflows/crowdin-upload.yml | 37 -------- CONTRIBUTING.md | 12 +-- crowdin.yml | 125 ------------------------- src/locales/de/messages.po | 5 - src/locales/el/messages.po | 5 - src/locales/es/messages.po | 5 - src/locales/fr/messages.po | 5 - src/locales/ru/messages.po | 5 - src/locales/zh/messages.po | 5 - 10 files changed, 5 insertions(+), 262 deletions(-) delete mode 100644 .github/workflows/crowdin-download.yml delete mode 100644 .github/workflows/crowdin-upload.yml delete mode 100644 crowdin.yml diff --git a/.github/workflows/crowdin-download.yml b/.github/workflows/crowdin-download.yml deleted file mode 100644 index 1db31e6e48..0000000000 --- a/.github/workflows/crowdin-download.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: Download crowdin files - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} - cancel-in-progress: true - -on: - schedule: - - cron: '0 */6 * * *' - workflow_dispatch: - -# Checkout + git push both authenticate with BOT_TOKEN, so GITHUB_TOKEN only needs read. -permissions: - contents: read - -jobs: - download-from-crowdin: - name: Download sources from Crowdin - runs-on: ubuntu-latest - if: github.repository == 'aave/interface' - - steps: - - name: Checkout - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - with: - token: ${{ secrets.BOT_TOKEN }} - - - uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 - - - uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0 - with: - node-version-file: '.nvmrc' - cache: 'pnpm' - - - name: crowdin action - uses: crowdin/github-action@60debf382ee245b21794321190ad0501db89d8c1 # v2.13.0 - with: - project_id: 502668 - token: ${{ secrets.CROWDIN_TOKEN }} - upload_translations: false - download_translations: true - create_pull_request: false - push_translations: false - config: 'crowdin.yml' - env: - GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} - CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }} - - - name: check diff - run: | - if [[ -z $(git status -s) ]] - then - echo "tree is clean" - else - pnpm install --frozen-lockfile - pnpm i18n:compile - git add . - git config --global user.name 'Crowdin bot' - git config --global user.email 'crowdin-bot@aave.com' - git commit -am "chore(i18n): synchronize translations from crowdin [skip cypress]" - git push - exit - fi diff --git a/.github/workflows/crowdin-upload.yml b/.github/workflows/crowdin-upload.yml deleted file mode 100644 index 1ef313817f..0000000000 --- a/.github/workflows/crowdin-upload.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: Upload Crowdin files - -# on any push to main, we upload the translations to be translated -on: - push: - branches: - - main - -# Crowdin sync authenticates with BOT_TOKEN, so GITHUB_TOKEN only needs read. -permissions: - contents: read - -jobs: - upload-to-crowdin: - name: Upload sources to Crowdin - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - - - uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 - - - uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0 - with: - node-version-file: '.nvmrc' - cache: 'pnpm' - - - name: Synchronize - uses: crowdin/github-action@60debf382ee245b21794321190ad0501db89d8c1 # v2.13.0 - with: - upload_sources: true - download_translations: false - config: 'crowdin.yml' - env: - GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} - CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f22babc1b8..7ae9e34340 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -188,19 +188,17 @@ To add a new token to the app, the process is pretty simple. All you’ll need t ## Translations -Aave uses [Crowdin](https://crowdin.com/) for translation management and internationalization. We only update strings within the app. Everything else is downloaded from Crowdin. For more information, such as installing their CLI tool, read their [documentation](https://developer.crowdin.com/api/v2/). +Aave uses [Lingui](https://lingui.dev/) for internationalization. Translation catalogs live in `src/locales//messages.po` and are maintained directly in this repository — `src/locales/en/messages.po` is the source catalog, generated from the `Trans` macros and `t` calls in the code. -To upload strings: +After adding or changing strings in the app, regenerate the catalogs: ```bash -crowdin upload sources +pnpm i18n ``` -To download strings: +This runs `i18n:extract` (updates `messages.po` for every configured locale with the strings found in the source) followed by `i18n:compile` (builds the `messages.js` files the app loads at runtime). Commit the resulting `.po` changes along with your code. -```bash -crowdin download -``` +Translations for non-English locales are filled in by hand in the corresponding `messages.po` file. Any string left with an empty `msgstr` falls back to English. If you would like to add support for a new language across the app, please [open up an issue](https://github.com/aave/interface/issues/new/choose) and add the `i18n` label to it. This helps us categorize, and it will also help to gauge public interest for the new language. If the community decides to go forward with your preferred language, you may open up a pull request. Please follow the template of [this PR](https://github.com/aave/interface/pull/447#issue-1165545965). diff --git a/crowdin.yml b/crowdin.yml deleted file mode 100644 index 9eb6597256..0000000000 --- a/crowdin.yml +++ /dev/null @@ -1,125 +0,0 @@ -# -# Your Crowdin credentials -# -'project_id': '502668' -'api_token_env': 'CROWDIN_PERSONAL_TOKEN' -'base_path': '.' -'base_url': 'https://api.crowdin.com' -'export_languages': ['en', 'es', 'fr', 'el'] -# -# Choose file structure in Crowdin -# e.g. true or false -# -'preserve_hierarchy': true - -# -# Files configuration -# -files: [ - { - # - # Source files filter - # e.g. "/resources/en/*.json" - # - 'source': 'src/locales/en/messages.po', - - # - # Where translations will be placed - # e.g. "/resources/%two_letters_code%/%original_file_name%" - # - 'translation': 'src/locales/%two_letters_code%/%original_file_name%', - # - # Files or directories for ignore - # e.g. ["/**/?.txt", "/**/[0-9].txt", "/**/*\?*.txt"] - # - #"ignore" : [], - - # - # The dest allows you to specify a file name in Crowdin - # e.g. "/messages.json" - # - # 'dest': 'en.po', - # - # File type - # e.g. "json" - # - #"type" : "", - - # - # The parameter "update_option" is optional. If it is not set, after the files update the translations for changed strings will be removed. Use to fix typos and for minor changes in the source strings - # e.g. "update_as_unapproved" or "update_without_changes" - # - #"update_option" : "", - - # - # Start block (for XML only) - # - - # - # Defines whether to translate tags attributes. - # e.g. 0 or 1 (Default is 1) - # - # "translate_attributes" : 1, - - # - # Defines whether to translate texts placed inside the tags. - # e.g. 0 or 1 (Default is 1) - # - # "translate_content" : 1, - - # - # This is an array of strings, where each item is the XPaths to DOM element that should be imported - # e.g. ["/content/text", "/content/text[@value]"] - # - # "translatable_elements" : [], - - # - # Defines whether to split long texts into smaller text segments - # e.g. 0 or 1 (Default is 1) - # - # "content_segmentation" : 1, - - # - # End block (for XML only) - # - - # - # Start .properties block - # - - # - # Defines whether single quote should be escaped by another single quote or backslash in exported translations - # e.g. 0 or 1 or 2 or 3 (Default is 3) - # 0 - do not escape single quote; - # 1 - escape single quote by another single quote; - # 2 - escape single quote by backslash; - # 3 - escape single quote by another single quote only in strings containing variables ( {0} ). - # - # "escape_quotes" : 3, - - # - # Defines whether any special characters (=, :, ! and #) should be escaped by backslash in exported translations. - # e.g. 0 or 1 (Default is 0) - # 0 - do not escape special characters - # 1 - escape special characters by a backslash - # - # "escape_special_characters": 0 - # - - # - # End .properties block - # - - # - # Does the first line contain header? - # e.g. true or false - # - #"first_line_contains_header" : true, - - # - # for spreadsheets - # e.g. "identifier,source_phrase,context,uk,ru,fr" - # - # "scheme" : "", - }, - ] diff --git a/src/locales/de/messages.po b/src/locales/de/messages.po index 06c8e518cf..4be46dbc6f 100644 --- a/src/locales/de/messages.po +++ b/src/locales/de/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: German\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: de\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx msgid "If you DO NOT unstake within {0} of unstake window, you will need to activate cooldown process again." diff --git a/src/locales/el/messages.po b/src/locales/el/messages.po index e7c619cf09..6d067e6913 100644 --- a/src/locales/el/messages.po +++ b/src/locales/el/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: Greek\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: el\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx #: src/modules/umbrella/StakeCooldownModalContent.tsx diff --git a/src/locales/es/messages.po b/src/locales/es/messages.po index d2c9e813e3..97aae21b51 100644 --- a/src/locales/es/messages.po +++ b/src/locales/es/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: Spanish\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: es-ES\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx #: src/modules/umbrella/StakeCooldownModalContent.tsx diff --git a/src/locales/fr/messages.po b/src/locales/fr/messages.po index d7b7278c40..c13a87419f 100644 --- a/src/locales/fr/messages.po +++ b/src/locales/fr/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: French\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: fr\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx #: src/modules/umbrella/StakeCooldownModalContent.tsx diff --git a/src/locales/ru/messages.po b/src/locales/ru/messages.po index 3bb6ff30ee..d55bf7ccc8 100644 --- a/src/locales/ru/messages.po +++ b/src/locales/ru/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: Russian\n" "Plural-Forms: nplurals=4; plural=((n%10==1 && n%100!=11) ? 0 : ((n%10 >= 2 && n%10 <=4 && (n%100 < 12 || n%100 > 14)) ? 1 : ((n%10 == 0 || (n%10 >= 5 && n%10 <=9)) || (n%100 >= 11 && n%100 <= 14)) ? 2 : 3));\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: ru\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx msgid "If you DO NOT unstake within {0} of unstake window, you will need to activate cooldown process again." diff --git a/src/locales/zh/messages.po b/src/locales/zh/messages.po index a740261ac2..a237ec8104 100644 --- a/src/locales/zh/messages.po +++ b/src/locales/zh/messages.po @@ -12,11 +12,6 @@ msgstr "" "Last-Translator: \n" "Language-Team: Chinese Simplified\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Crowdin-Project: aave-interface\n" -"X-Crowdin-Project-ID: 502668\n" -"X-Crowdin-Language: zh-CN\n" -"X-Crowdin-File: /src/locales/en/messages.po\n" -"X-Crowdin-File-ID: 46\n" #: src/components/transactions/StakeCooldown/StakeCooldownModalContent.tsx msgid "If you DO NOT unstake within {0} of unstake window, you will need to activate cooldown process again."