Repository navigation
feat: accept the floating sdlc launcher in XII; constitution 1.46.0 - #157
Conversation
python-sdlc#62 converts repos to a committed bootstrap, .sdlc/bin/sdlc, run by repo: local hooks with no rev: and by the sdlc ci job. Every converted pilot (josui, mcp-nagios, syslog) failed sdlc ci on the constitution alone: check_sdlc_wiring demanded the rev-pinned hook and check_standalone_hooks the Gourmand/Gatehouse hooks. XII now prefers the floating form for every repo kind. A repo whose hooks run the launcher is judged by check_floating_wiring alone: the launcher is a committed executable file, sdlc-commit and sdlc-push are language: system with the right entry and stage, both hook types are installed, and a job named `sdlc ci` runs it. Accepting a form is not a new requirement, so it is not version-gated. The rev-pinned and standalone forms stay accepted until the wave finishes. Releases 1.46.0 (1.43.0 was already taken): refs, CHANGELOG, history row. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN
Any executable at .sdlc/bin/sdlc passed, so a repo could commit a script that exits 0 and pass its own hooks and its `sdlc ci` required check. The launcher must now hash to an entry in sdlc_bootstrap_sha256 (python-sdlc#62's bin/sdlc-bootstrap), and in the floating form the `sdlc ci` job must run that committed file, not any `sdlc` on a path. The image still floats; only the file the gate trusts is pinned. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN
|
Review (a213, Dolza 1 - Max) at 2603041. Tests pass (339). 2 blocking findings, then nits. How I tested: I converted a scratch copy of josui
BlockingB1. Nothing checks what the launcher contains, and nothing guards the file.
Fix:
B2. Nothing makes the image come from the variable. python-sdlc's
Not blocking, but worth fixing in the same pass
Question 2: does "judged by this form alone" drop a check that still matters?No. The new branch replaces only
What does move is trust. A non-Python repo used to get Gourmand and Gatehouse at commit from named images; now it gets them from whatever the launcher runs. That is why B1 matters. Nits
Release shape
|
There was a problem hiding this comment.
Gatehouse found 1 issues (1 medium)
Reviewed 1 commit since 2603041 (incremental).
5 finding(s) dropped: their evidence is not in the diff.
|
|
||
| # --pull=newer: :latest moves, and a stale local copy is how a two-week-old | ||
| # reviewer once judged trentina. Offline, podman keeps the copy it has. | ||
| if ! podman --events-backend=none run --rm --log-driver=none --network=none \ |
There was a problem hiding this comment.
MEDIUM (Test Coverage): The new bootstrap script invokes an external podman command, handles pull and empty-output failures, writes a temporary launcher, and forwards arguments and the launcher’s exit status, but no tests exercise these paths. Failures in this gate-running script could therefore go undetected.
Suggestion: Add shell-level tests using a stub podman executable to cover successful launcher retrieval and argument forwarding, command failure, empty output, and propagation of the launcher’s exit status.
Evidence:
if ! podman --events-backend=none run --rm --log-driver=none --network=none \
--cap-drop=all --security-opt=no-new-privileges --pull=newer \
-- "$image" launcher "$image" > "$dir/sdlc" || [ ! -s "$dir/sdlc" ]; then
...
fi
sh "$dir/sdlc" "$@"
There was a problem hiding this comment.
Not a bug: tests/sdlc-bootstrap is a byte-for-byte fixture of python-sdlc's bin/sdlc-bootstrap, kept here only so the validator's sha256 pin is tested against real bytes; this repo never runs it. Its behaviour (stub podman, pull failure, empty output, argv and exit status) is tested where it lives, in python-sdlc#62's tests/test_host_contract.sh and tests/contract.sh.
From #157's review (a213). The `sdlc ci` job is the required check, so anything that turns it green without judging is a hole: - the step's run must be exactly `.sdlc/bin/sdlc ci`, so `|| true`, a second line and another script are rejected - no `if:` that could be false and no `continue-on-error` on the job or the step: a skipped required check reads as passed - SDLC_IMAGE unset or exactly `${{ vars.SDLC_IMAGE }}` at workflow, job and step env (B2): a PR must not choose the image that judges it - a duplicate floating hook id is named instead of silently replacing - this repo's Protect workflows guard also rejects fork changes to .sdlc/ Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN
|
Re: review a213 (#157 (comment)) B1: Fixed in 371e59d. The launcher must hash to an entry in B2: Fixed in db3384c. In the floating form, Cases 3, 5, 6: Fixed in db3384c for the floating form. It rejects Nit, duplicate hook ids: Fixed in db3384c. A second hook with the same id is now named instead of silently replacing the first. Your six cases are now tests: 364 pass, and the three converted pilots still pass. |
There was a problem hiding this comment.
Gatehouse found no issues.
Reviewed 1 commit since 371e59d (incremental).
7 finding(s) dropped: their evidence is not in the diff.
…inal bootstrap #62's bin/sdlc-bootstrap is frozen at a483867 (sha256 6c4691c4...). The earlier hash came from an unreleased draft that no repo carries, so it is replaced rather than kept. tests/sdlc-bootstrap is the a483867 file. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN
There was a problem hiding this comment.
Gatehouse found 1 issues (1 medium)
Reviewed 1 commit since db3384c (incremental).
1 finding(s) dropped: their evidence is not in the diff.
|
|
||
| # The value, with the repository named in full or not at all. | ||
| want=${SDLC_IMAGE:-latest} | ||
| case $want in |
There was a problem hiding this comment.
MEDIUM (Test Coverage): The new image-reference allowlist has multiple parsing and rejection branches, but no tests were added or updated to cover them. Regressions could accept an unintended reference or reject a supported one without detection.
Suggestion: Add table-driven shell tests for main, latest, version refs, fully qualified refs, and valid digests, plus rejected refs and digest length/character boundary cases. Mock the pull command to verify invalid values are rejected before any image is pulled.
Evidence:
case $want in
main|latest) image=$FLEET:$want ;;
@sha256:*)
hex=${want#@sha256:}
case $hex in *[!0-9a-f]*) refuse ;; esac
[ "${#hex}" -eq 64 ] || refuse
image=$FLEET$want ;;
*[!0-9.]*|.*|*.|*..*|*.*.*.*) refuse ;;
*.*.*) image=$FLEET:$want ;;
*) refuse ;;
esac
There was a problem hiding this comment.
Not a bug: tests/sdlc-bootstrap is a byte-for-byte fixture of python-sdlc's bin/sdlc-bootstrap at a483867, kept here only so the validator's sha256 pin is tested against real bytes; this repo never runs it. The image-ref allowlist this finding asks about is table-tested at its source, python-sdlc a483867 tests/test_host_contract.sh ("the floating launcher" section). It covers main, X.Y.Z, @sha256 and fully qualified refs as accepted. It covers localhost/, other repos, 1.2, v1.2.3, 1.2.3.4, 1..3, a short or non-hex digest, main;id and --privileged as refused with exit 2 before podman runs.
The guard job now matches crunchtools/gatehouse examples/gatehouse.yml at 4ae89d0 line for line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN
There was a problem hiding this comment.
Gatehouse found no issues.
Reviewed 1 commit since ea74bee (incremental).
What
XII now prefers the floating sdlc launcher from crunchtools/python-sdlc#62 as the wiring for every repo kind. The launcher is a committed
.sdlc/bin/sdlc. Tworepo: local,language: systemhooks run it asentry: .sdlc/bin/sdlc commitandentry: .sdlc/bin/sdlc push, with norev:. Thesdlc cijob runs.sdlc/bin/sdlc ci.check_floating_wiringapplies to any repo whose hooks run the launcher, and judges it by that form alone. It requires:sdlc_bootstrap_sha256language: systemwith the right entry, with no duplicate idspre-pushdefault_install_hook_typesnames both stagessdlc cijob (check_floating_ci). This job is the required check, so nothing may turn it green without judging:runis exactly.sdlc/bin/sdlc ci, so no|| true, no second line and no other scriptif:that could be false, orcontinue-on-errorSDLC_IMAGEis unset or exactly${{ vars.SDLC_IMAGE }}at workflow, job and stepenv:, because a PR must not choose its judgesdlc_bootstrap_sha256is a list: a bootstrap change adds a hash and there is no flag day.bin/sdlc-bootstrap(87e8649a…). It will be re-seeded from the final bytes once feat: v1.26.0 agents reach a forge only through the gateway #62 merges.Protect workflowsrejects fork changes under.sdlc/as well as.github/workflows/. The fleet's copy comes fromcrunchtools/gatehouseexamples/gatehouse.yml, which needs the same change.Inherits.sdlc_launcherandsdlc_bootstrap_sha256.sdlcjoinsfloating_images.v1.46.0at the merge sha and dispatchmajor-tag.yml.Known residual, accepted
The rev-pinned and standalone forms have always been matched by text. They still accept a fake
repo: localscript,|| true,if: falseandcontinue-on-error. Left as is: both forms stop being accepted once the conversion wave finishes, and v2 drops them.Pilots
Each pilot was converted with #62's
scripts/convert_repo.py --applyat the commit #62 records.exit 0launcherTests
The full suite passes (364). The tests cover every case from the a213 review, using the real bootstrap vendored as
tests/sdlc-bootstrap.sdlc commitandsdlc pushpass locally.Not merged: ready for review.
v2/anddocs/constitution-v2(#156) are untouched.🤖 Generated with Claude Code
https://claude.ai/code/session_01R7Y1jeqWyD1kaUDpcBw3TN