name: Manual Live E2E on: workflow_dispatch: inputs: run_live_suite: description: "Run backend live e2e suite" required: true default: "true" type: choice options: - "true" - "false" jobs: backend-live-e2e: if: ${{ inputs.run_live_suite == 'true' }} runs-on: ubuntu-latest timeout-minutes: 45 env: AGENT_LIVE_E2E: "1" AGENT_LIVE_INTEGRATION: "1" steps: - name: Checkout uses: actions/checkout@v4 - name: Setup Python uses: actions/setup-python@v5 with: python-version: "3.12" - name: Setup uv uses: astral-sh/setup-uv@v3 - name: Restore .env from secret shell: bash run: | if [ -z "${{ secrets.SOCIAL_APP_ENV_FILE }}" ]; then echo "Missing required secret: SOCIAL_APP_ENV_FILE" exit 1 fi printf '%s' "${{ secrets.SOCIAL_APP_ENV_FILE }}" > .env - name: Install dependencies run: uv sync - name: Start local Supabase stack run: docker compose --env-file .env -f infra/docker/docker-compose.yml up -d - name: Wait for Postgres shell: bash run: | for i in $(seq 1 30); do if nc -z 127.0.0.1 5434; then exit 0 fi sleep 2 done echo "Postgres is not ready" docker compose --env-file .env -f infra/docker/docker-compose.yml ps exit 1 - name: Apply database migrations run: uv run alembic -c backend/alembic/alembic.ini upgrade head - name: Run live E2E tests run: uv run pytest backend/tests/e2e/test_agent_live_flow.py -m live -v -rs - name: Dump container logs on failure if: failure() run: docker compose --env-file .env -f infra/docker/docker-compose.yml logs --no-color - name: Shutdown local Supabase stack if: always() run: docker compose --env-file .env -f infra/docker/docker-compose.yml down -v