From 378ff2105debecdcb88ea8b1a21e579737c89d07 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Wed, 2 Dec 2026 07:30:00 -0800 Subject: [PATCH] ci: wait for the filemeta table before the versioning suite Co-Authored-By: Claude Opus 5.5 --- .github/workflows/postgres-flat-tests.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/postgres-flat-tests.yml b/.github/workflows/postgres-flat-tests.yml index 9b28d68eae..632e4768ba 100644 --- a/.github/workflows/postgres-flat-tests.yml +++ b/.github/workflows/postgres-flat-tests.yml @@ -121,9 +121,12 @@ jobs: weed/weed -config_dir="$RUNNER_TEMP/config" mini -ip=127.0.0.1 -ip.bind=127.0.0.1 \ -dir="$RUNNER_TEMP/data" -s3.config="$GITHUB_WORKSPACE/docker/compose/s3.json" \ -webdav=false -admin.ui=false > "$RUNNER_TEMP/weed.log" 2>&1 & - for i in $(seq 90); do curl -s -o /dev/null http://127.0.0.1:8333 && break; sleep 1; done - curl -s -o /dev/null http://127.0.0.1:8333 || { cat "$RUNNER_TEMP/weed.log"; exit 1; } - test "$(docker exec ${{ job.services.postgres.id }} psql -U postgres -Atc "SELECT count(*) FROM information_schema.columns WHERE table_name = 'filemeta' AND column_name = 'path'")" = 1 + ready() { + curl -s -o /dev/null http://127.0.0.1:8333 && + test "$(docker exec ${{ job.services.postgres.id }} psql -U postgres -Atc "SELECT count(*) FROM information_schema.columns WHERE table_name = 'filemeta' AND column_name = 'path'")" = 1 + } + for i in $(seq 90); do ready && break; sleep 1; done + ready || { cat "$RUNNER_TEMP/weed.log"; exit 1; } - name: Run the S3 versioning suite env: