From 9e608eae3337770f7860b530dce6a96a30298539 Mon Sep 17 00:00:00 2001 From: xiaoxia Date: Fri, 17 Jul 2026 08:02:58 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix(ci):=20=E4=BF=AE=E5=A4=8Dauto-merge?= =?UTF-8?q?=E7=BC=BAGITEA=5FTOKEN=20+=20tests.yml=E7=BC=BAGITHUB=5FTOKEN?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/auto-merge.yml | 4 ++++ .gitea/workflows/tests.yml | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/auto-merge.yml b/.gitea/workflows/auto-merge.yml index d4a29622a..0d2722dfc 100644 --- a/.gitea/workflows/auto-merge.yml +++ b/.gitea/workflows/auto-merge.yml @@ -13,9 +13,13 @@ jobs: uses: actions/checkout@v3 - name: Auto merge develop PRs + env: + GITEA_API_TOKEN: ${{ secrets.REVIEW_GITEA_TOKEN }} run: | bash scripts/auto_merge_prs.sh develop - name: Auto merge main PRs (release only) + env: + GITEA_API_TOKEN: ${{ secrets.REVIEW_GITEA_TOKEN }} run: | bash scripts/auto_merge_prs.sh main diff --git a/.gitea/workflows/tests.yml b/.gitea/workflows/tests.yml index f8ffeb555..773129aca 100755 --- a/.gitea/workflows/tests.yml +++ b/.gitea/workflows/tests.yml @@ -11,9 +11,11 @@ jobs: steps: - name: Checkout code shell: sh + env: + GITHUB_TOKEN: ${{ github.token }} run: | set -eu - python - <<'PY' + python3 - <<'PY' import io import os import tarfile @@ -93,9 +95,11 @@ jobs: steps: - name: Checkout code shell: sh + env: + GITHUB_TOKEN: ${{ github.token }} run: | set -eu - python - <<'PY' + python3 - <<'PY' import io import os import tarfile -- 2.54.0 From 2baf583d0d97d0c7f5fd5670d3434cfbf254a5be Mon Sep 17 00:00:00 2001 From: xiaoxia Date: Fri, 17 Jul 2026 08:54:47 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix(ci):=20=E4=B8=BA=E5=8D=95=E5=85=83?= =?UTF-8?q?=E6=B5=8B=E8=AF=95=E6=B7=BB=E5=8A=A0Redis=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=EF=BC=8C=E4=BF=AE=E5=A4=8DCelery=E7=9B=B8=E5=85=B3=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=E5=A4=B1=E8=B4=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/ci-cd.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.gitea/workflows/ci-cd.yml b/.gitea/workflows/ci-cd.yml index 90caef5ae..3bcc81d9d 100755 --- a/.gitea/workflows/ci-cd.yml +++ b/.gitea/workflows/ci-cd.yml @@ -128,6 +128,27 @@ jobs: grep -q "Running upgrade" /tmp/alembic-upgrade.sql python3 scripts/check_schema_metadata.py + - name: Start Redis for unit tests + shell: sh + run: | + set -eu + docker rm -f ci-redis-validate 2>/dev/null || true + docker run -d --name ci-redis-validate \ + -p 6379:6379 \ + --health-cmd "redis-cli ping" \ + --health-interval 2s \ + --health-timeout 2s \ + --health-retries 15 \ + redis:7-alpine + for i in $(seq 1 20); do + if docker inspect --format='{{.State.Health.Status}}' ci-redis-validate 2>/dev/null | grep -q healthy; then + echo "Redis is ready" + break + fi + echo "Waiting for Redis... ($i/20)" + sleep 1 + done + docker inspect --format='{{.State.Health.Status}}' ci-redis-validate | grep -q healthy - name: Run unit tests shell: sh env: -- 2.54.0