aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMicah Lee <micah@micahflee.com>2023-09-04 20:16:44 -0700
committerMicah Lee <micah@micahflee.com>2023-09-04 20:16:44 -0700
commitfcd1ddc28abe6249b43483649316caf4d61c94a0 (patch)
tree5d55f3827bda4089d9d90381a4295675e9a2ea22
parent127397d0d994178c65f0e6fe7f0ab8468bef7b85 (diff)
downloadonionshare-fcd1ddc28abe6249b43483649316caf4d61c94a0.tar.gz
onionshare-fcd1ddc28abe6249b43483649316caf4d61c94a0.zip
Make check-weblate.py less brittle
-rw-r--r--RELEASE.md6
-rwxr-xr-xdocs/check-weblate.py3
2 files changed, 7 insertions, 2 deletions
diff --git a/RELEASE.md b/RELEASE.md
index 82038797..edd1e51e 100644
--- a/RELEASE.md
+++ b/RELEASE.md
@@ -55,7 +55,11 @@ Update the versions of `meek`, `obfs4proxy`, and `snowflake` in the `desktop/scr
### Finalize localization
-- [ ] Merge all the translations from weblate
+- [ ] Merge all the translations from weblate:
+ ```
+ git remote add weblate https://hosted.weblate.org/projects/onionshare/translations/
+ git pull weblate main
+ ```
- [ ] In `docs` run `poetry run ./check-weblate.py [API_KEY]` to see which translations are >90% in the app and docs
- [ ] Edit `cli/onionshare_cli/settings.py`, make sure `self.available_locales` lists only locales that are >90% translated
- [ ] From the `desktop` folder in the virtual env, run `./scripts/countries-update-list.py` to make sure the localized country list for censorship circumvention is available in all available languages
diff --git a/docs/check-weblate.py b/docs/check-weblate.py
index 135c4b44..3eb1c052 100755
--- a/docs/check-weblate.py
+++ b/docs/check-weblate.py
@@ -50,7 +50,8 @@ async def app_percent_output(percent_min, percent_max=101):
out = []
for lang_code in languages:
if (
- app_translations[lang_code] >= percent_min
+ lang_code in app_translations
+ and app_translations[lang_code] >= percent_min
and app_translations[lang_code] < percent_max
):
out.append(