Skip to content

Commit a53b401

Browse files
Fetch submodule tags in release workflow test job (#75)
actions/checkout's submodule clone is shallow and doesn't carry tags. scripts/build_agents_md.py asserts the spec submodule HEAD is AT a v* tag (used by tests/test_agents_md_drift.py). ci.yml has had this step since PR #72; release.yml was missed, so the v0.9.0-rc1 tag's test job failed on the drift check. Build / publish jobs don't regenerate AGENTS.md (they package the committed file via hatchling), so the fix is only needed in the test job.
1 parent 9387092 commit a53b401

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,18 @@ jobs:
2828
# Conformance fixtures live in the openarmature-spec submodule.
2929
submodules: recursive
3030

31+
- name: Fetch submodule tags
32+
# actions/checkout's submodule clone is shallow and doesn't
33+
# carry tags. ``scripts/build_agents_md.py`` asserts the
34+
# submodule HEAD is AT a ``v*`` tag (``git tag --points-at
35+
# HEAD``; refuses to bundle draft spec text or text from
36+
# a commit between two release tags);
37+
# ``tests/test_agents_md_drift.py`` runs that assertion.
38+
# Fetch tag refs only — the HEAD commit is already present
39+
# from the submodule checkout, and we don't need history
40+
# beyond what tags point at. Mirrors the step in ``ci.yml``.
41+
run: git -C openarmature-spec fetch --tags
42+
3143
- name: Install uv
3244
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
3345
with:

0 commit comments

Comments
 (0)