Fix build_changelog: install git for towncrier staging

Towncrier calls `git add` on the updated CHANGELOG.md. Install git and
run `git init` in the Python container to satisfy this requirement.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Erich Blume 2026-02-11 16:26:48 -08:00
commit 518e2ab737

View file

@ -31,9 +31,13 @@ class BlumeopsCi:
return await (
dag.container()
.from_("python:3.12-slim")
# git is required because towncrier stages CHANGELOG.md via git add
.with_exec(["apt-get", "update", "-qq"])
.with_exec(["apt-get", "install", "-y", "-qq", "git"])
.with_exec(["pip", "install", "towncrier"])
.with_directory("/workspace", src)
.with_workdir("/workspace")
.with_exec(["git", "init"])
.with_exec(["towncrier", "build", "--version", version, "--yes"])
.directory("/workspace")
)