chore(ci): Read clickhouse image from versions json for CI - #70905
Conversation
The turbo-tests hardcoded the ClickHouse server image, so it drifted from the version local dev and hobby run whenever docker-compose was bumped. Read it from clickhouse-versions.json's `local` key via a new get_clickhouse_versions output, making the JSON the single source of truth for the product-test image. Mirrored into the depot shadow to keep the drift check green. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The version in the docker-compose file should match this version at all times, in the unlikely event the fallback happens it should still be a valid test scenario. |
Problem
The
turbo-testsproduct suite inci-backend.ymlhardcoded its ClickHouse server image (clickhouse/clickhouse-server:26.6.1.1193). Everywhere else in backend CI already derives the image from.github/clickhouse-versions.json, but these two pins were hand-maintained copies. Whenever local dev and hobby were bumped to a new ClickHouse version, the product tests kept running the old image until someone remembered to edit both the canonical workflow and its depot shadow. That is the silent drift the versions file exists to prevent.Changes
Claude made these changes at my direction.
turbo-testsnow reads the image from the versions file instead of a literal:local_imageoutput to theget_clickhouse_versionsjob, read from the JSON'slocalkey with the same null guard the existingoldest_supportedread uses.turbo-testsimage references at${{ needs.get_clickhouse_versions.outputs.local_image }}and addedget_clickhouse_versionsto that job'sneeds..depot/workflows/ci-backend.yml) so the shadow-drift check stays green.Note
localin the versions file is the 3-part tagclickhouse/clickhouse-server:26.6.1, not the 4-part26.6.1.1193. That is a real rolling tag pointing at the same build today, and the compat matrix already pulls it, so there is no functional change now. From here on the product tests track whatever the versions file says.How did you test this code?
No new automated tests, since this is CI config. I (Claude) could not run the actual
turbo-testsjob or a full CI run locally. What I did run:bin/hogli lint:workflows(after syncing the flox venv): 6/6 checks pass across 100 workflows.jq -r '.local' .github/clickhouse-versions.jsonreturnsclickhouse/clickhouse-server:26.6.1, and I confirmed that tag is real and pullable on Docker Hub.get_clickhouse_versionsis skipped, the output is empty anddocker-compose.dev.yml(whichextendsbase) falls back to base's${CLICKHOUSE_SERVER_IMAGE:-...}default.turbo-testsruns withalways(), so the newneedsedge cannot cause it to skip. This matches how the existingoldest_supported_imageconsumers already behave.actionlint is not installed locally, so CI owns that check. I verified the
needsreference and the output declaration by hand.Automatic notifications
Docs update
No user-facing docs affected.
🤖 Agent context
Autonomy: Human-driven by @tpgilmore (agent-assisted)
Tool: Claude Code (Claude Opus 4.8). I followed the repo's
authoring-ci-workflowsskill (read itsSKILL.md, per the CLAUDE.md requirement for any.github/workflowsedit). No other skills applied.Decisions:
localkey rather than adding a new 4-part key. The versions file is already the source of truth and the plan was to move these pins onto its 3-part identifiers, so reusinglocalkeeps one lever instead of two.get_clickhouse_versionsoutput rather than an inlinejqinturbo-tests, to match howoldest_supported_imageis already consumed and keep the JSON read in one place.This closes a lag where the product-test image had to be updated by hand after each ClickHouse bump. The versions file is populated by the existing infra sync, so pulling from it removes the manual step.