From 2984e8426a625c3bf07cc89cfccba9730c79ac17 Mon Sep 17 00:00:00 2001 From: masonxhuang Date: Tue, 9 Jun 2026 11:24:29 +0800 Subject: [PATCH 1/2] ci: fail incomplete docs translation runs --- .github/workflows/translate-all.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/translate-all.yml b/.github/workflows/translate-all.yml index 5d55a3f5b5..6f0a9225d8 100644 --- a/.github/workflows/translate-all.yml +++ b/.github/workflows/translate-all.yml @@ -328,6 +328,7 @@ jobs: if [ "${current_source_sha}" != "${SOURCE_SHA}" ]; then echo "stale=true" >> "${GITHUB_OUTPUT}" echo "changed_count=0" >> "${GITHUB_OUTPUT}" + echo "incomplete_count=0" >> "${GITHUB_OUTPUT}" { echo "### Translation finalizer skipped" echo @@ -418,6 +419,11 @@ jobs: with out.open("a", encoding="utf-8") as fh: fh.write("stale=false\n") fh.write(f"changed_count={len(status)}\n") + fh.write(f"incomplete_count={len(missing_or_failed)}\n") + + incomplete_path = Path(".openclaw-sync/i18n-incomplete-locales.txt") + incomplete_path.parent.mkdir(exist_ok=True) + incomplete_path.write_text("\n".join(missing_or_failed) + ("\n" if missing_or_failed else ""), encoding="utf-8") summary = Path(os.environ["GITHUB_STEP_SUMMARY"]) with summary.open("a", encoding="utf-8") as fh: @@ -509,3 +515,13 @@ jobs: run: | set -euo pipefail gh workflow run pages.yml --ref main + + - name: Fail incomplete translation run + if: steps.apply.outputs.stale != 'true' && steps.apply.outputs.incomplete_count != '0' + run: | + { + echo "Translation finished with missing or failed locales." + echo "Successful locale artifacts were applied before this failure when available." + cat .openclaw-sync/i18n-incomplete-locales.txt + } >&2 + exit 1 From 58577d911c882854558ecf6f45b9833d3d446c20 Mon Sep 17 00:00:00 2001 From: Vincent Koc <25068+vincentkoc@users.noreply.github.com> Date: Tue, 9 Jun 2026 13:46:29 +0900 Subject: [PATCH 2/2] ci: group translation finalizer outputs --- .github/workflows/translate-all.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/translate-all.yml b/.github/workflows/translate-all.yml index 6f0a9225d8..3b94b28e15 100644 --- a/.github/workflows/translate-all.yml +++ b/.github/workflows/translate-all.yml @@ -326,9 +326,11 @@ jobs: | node -e 'const fs = require("node:fs"); const data = JSON.parse(fs.readFileSync(0, "utf8")); process.stdout.write(data.sha || "");' )" if [ "${current_source_sha}" != "${SOURCE_SHA}" ]; then - echo "stale=true" >> "${GITHUB_OUTPUT}" - echo "changed_count=0" >> "${GITHUB_OUTPUT}" - echo "incomplete_count=0" >> "${GITHUB_OUTPUT}" + { + echo "stale=true" + echo "changed_count=0" + echo "incomplete_count=0" + } >> "${GITHUB_OUTPUT}" { echo "### Translation finalizer skipped" echo