Bump redis from 5.0.2 to 8.1.0 in /backend #1163
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Claude Code | |
| on: | |
| issue_comment: | |
| types: [created] | |
| pull_request_review_comment: | |
| types: [created] | |
| issues: | |
| types: [opened, assigned] | |
| pull_request_review: | |
| types: [submitted] | |
| pull_request: | |
| types: [review_requested] | |
| jobs: | |
| claude: | |
| if: | | |
| contains(fromJSON('["marcoacierno","estyxx"]'), github.actor) && | |
| ( | |
| (github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) || | |
| (github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) || | |
| (github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) || | |
| (github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude'))) || | |
| (github.event_name == 'pull_request' && github.event.action == 'review_requested') | |
| ) | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 120 | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| issues: write | |
| id-token: write | |
| actions: read | |
| services: | |
| postgres: | |
| image: postgres:14.5 | |
| env: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: postgres | |
| ports: | |
| - 5432:5432 | |
| # needed because the postgres container does not provide a healthcheck | |
| options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
| redis: | |
| image: redis:7.2.3 | |
| ports: | |
| - 6379:6379 | |
| options: --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5 | |
| # Exported into every shell Claude spawns, so `uv run pytest` works with no setup. | |
| env: | |
| DATABASE_URL: postgresql://postgres:postgres@localhost:5432/postgres | |
| CACHE_URL: redis://localhost:6379/0 | |
| CELERY_BROKER_URL: redis://localhost:6379/1 | |
| CELERY_RESULT_BACKEND: redis://localhost:6379/2 | |
| MEDIA_FILES_STORAGE_BACKEND: django.core.files.storage.FileSystemStorage | |
| STRIPE_SECRET_API_KEY: fake-key | |
| STRIPE_SUBSCRIPTION_PRICE_ID: "" | |
| STRIPE_WEBHOOK_SIGNATURE_SECRET: "" | |
| # Needed by `pnpm codegen`, which `pnpm build` runs first. Generated | |
| # GraphQL types are gitignored, so a frontend typecheck needs it. | |
| API_URL_SERVER: https://admin.pycon.it | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 1 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.13.5" | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b | |
| id: setup-uv | |
| with: | |
| version: "0.12.5" | |
| enable-cache: true | |
| - name: Install python dependencies | |
| working-directory: backend | |
| run: uv sync | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@v6 | |
| with: | |
| version: 9 | |
| run_install: false | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: "23.9.0" | |
| cache: "pnpm" | |
| cache-dependency-path: "frontend/pnpm-lock.yaml" | |
| - name: Install frontend dependencies | |
| working-directory: frontend | |
| run: pnpm install | |
| - name: Run Claude | |
| uses: anthropics/claude-code-action@v1 | |
| with: | |
| claude_code_oauth_token: ${{ secrets.CLAUDE_OAUTH_TOKEN }} | |
| assignee_trigger: "pythonitaliabot2" | |
| claude_args: | | |
| --model claude-opus-5 | |
| --effort xhigh | |
| --append-system-prompt "CI MODE. You are running in GitHub Actions against a plain checkout, not a developer laptop. Ignore the 'run everything inside docker exec pycon-backend-1' instructions in AGENTS.md: there is no Docker container here. BACKEND: dependencies are already installed via 'uv sync' in ./backend, and Postgres and Redis are running with DATABASE_URL and CELERY_* already exported. Verify with: cd backend && uv run pytest <paths> -x -q (add '-n auto' for the full suite), uv run mypy ., uv tool run ruff@0.12.5 check, uv tool run ruff@0.12.5 format --check. Always prefix Python tooling with 'uv run' or 'uv tool run' - bare python, pytest, mypy and ruff are not on PATH and are not permitted. FRONTEND: node 23.9.0 and pnpm 9 are installed and 'pnpm install' has already run in ./frontend. Generated GraphQL types are gitignored, so run 'pnpm codegen' before anything that typechecks (API_URL_SERVER is already exported); 'pnpm build' runs codegen itself. Lint from ./frontend with 'npx @biomejs/biome check .'. There is no 'pnpm test' script - AGENTS.md is wrong about that, do not try it. Run the checks covering your change before you report back, and quote the real output." | |
| --allowedTools "Edit,Write,Bash(cd:*),Bash(git:*),Bash(uv:*),Bash(pip:*),Bash(pnpm:*),Bash(node:*),Bash(npx:*),Bash(gh pr view:*),Bash(gh pr diff:*),Bash(gh pr list:*),Bash(gh pr comment:*),Bash(gh issue view:*),Bash(gh issue list:*),Bash(gh search:*)" | |
| # The action only logs the init and result JSON; the transcript with the | |
| # actual error lives here. Without this, failures are undiagnosable. | |
| - name: Upload Claude execution log | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: claude-execution-output | |
| path: ${{ runner.temp }}/claude-execution-output.json | |
| if-no-files-found: warn |