Forward-port the #2052 policy-gate transport-fault fix onto dev-factory main #2053
Labels
No labels
agent-blocked
agent-working
autopilot
bug
deferred
deploy-pending
enhancement
landing-pr
model-haiku
model-opus
model-sonnet
needs-design
needs-info
needs-triage
no-triage
out-of-scope
priority
ready-for-agent
ready-for-human
ready-for-session
rehearsal-183
snapshot-pending
standing-drive
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Matou/idss#2053
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Forward-port the #2052
policy-lib.sh/preflight-lib.shfix (a dead Forgejo read in the #12 policy gate reported asinvalid-policy) from the dev-factory cheap-backport branch onto dev-factorymain.What landed where
#2052 landed the fix as the #2048 route — a dev-factory cheap-backport branch authored off the idss pin, re-vendored into idss, with the forward-port to
mainowed:backport/idss-2052@d5be6884b60fd3fe36dd0dc12f72061a073c66e8, authored off the pin7d40af3.FACTORY_REF 7d40af3 → d5be688(idssmaincommit3b30cda3).policy-lib.sh,preflight-lib.sh,tests/policy-lib-test.sh,tests/preflight-lib-test.sh(NOT dev-factory's own.sandcastle/self-vendored copies).The owed work
Cherry-pick / re-apply
d5be688's diff onto dev-factorymain(now LANDING=push since df #276, 2026-10-17 — no longer the LANDING=pr that routed sibling #2049 to a human) so a future main-HEAD adoption carries the fix instead of silently dropping it.mainis ~457 commits ahead of7d40af3; its rootpolicy-lib.sh/preflight-lib.shmay have diverged, so the forward-port may conflict — run dev-factory's owntests/policy-lib-test.sh,tests/preflight-lib-test.sh,tests/run-swarm-stages-test.shandonboarding/tests/onboard-lib-test.shafter applying (all four were green on the backport branch).FACTORY_REFto a df-main HEAD as part of this — that drags 457 commits of unrelated factory churn into idss and is out of scope. This ticket closes when the fix is on dfmain; idss adopts df-main-HEAD on its own cadence (the drift NOTE's "behind main" advisory).Proof it's the same defect class as #2049
#2049 is the still-open forward-port of the sibling #2048 forgejo-lib/heal fix. This is the policy-gate twin, a disjoint file set, so the two forward-ports do not conflict each other.
Filed as a follow-up of #2052 under ADR 0174. Advances #2052's OWED tail.
invalid-policy— the #12 policy gate's label check has a 6s retry budget, records no verdict error line, and blames a policy file that is valid (the #1359 defect in the other preflight gate) #2052Close report — forward-port landed on dev-factory
main(ADR 0174, two-way door)The #2052 policy-gate transport-fault fix is now on dev-factory
main, so a future main-HEAD adoption carries it instead of silently dropping it.What landed
cherry-pick -x d5be688onto dev-factorymain→b786895(5b614ec..b786895, pushed; LANDING=push).policy-lib.sh(+37/-8… the rc-3 TRANSPORT split),preflight-lib.sh(+32/-6,verdict_erroron every refusal +policy-tracker-unreachable),tests/policy-lib-test.sh(+30),tests/preflight-lib-test.sh(+31). 115 insertions / 15 deletions.FACTORY_REFis not bumped (out of scope — that would drag df-main churn into idss; idss adopts df-main-HEAD on its own cadence).The merge
mainwas 69 commits ahead of the pin7d40af3(the ticket's ~457 estimate was stale — immaterial).preflight-lib.shandtests/preflight-lib-test.shwere byte-unchanged from the pin (clean apply);policy-lib.sh(+111/-34) andtests/policy-lib-test.sh(+39/-2) had diverged but the 3-way auto-merge produced a coherent result — no conflicts, verified by eye and by test.Proof (dev-factory's own suites, run on the rebased tip)
tests/policy-lib-test.sh→ 74 checks passed (incl. the TRANSPORT rc-3 path: shims a 5xx on the labels GET, asserts rc 3, asserts stderr names TRANSPORT and never "not minted").tests/preflight-lib-test.sh→ 10 groups passed.tests/run-swarm-stages-test.sh→ 12 groups passed.onboarding/tests/onboard-lib-test.sh→ 274 passed, 0 failed.Honest residue (not a defect, no human door)
forgejo-lib.shis still the pre-#2048forgejo_get(single-attempt, no retry loop), so theFORGEJO_GET_RETRIES/FORGEJO_GET_BACKOFFthatpolicy_validatenow sets are harmless no-ops on main until #2049 lands the sibling forgejo-lib retry forward-port. The actual #2052 defect fix — the rc 2 (invalid-policy) vs rc 3 (TRANSPORT /policy-tracker-unreachable) distinction and the non-emptyverdict_error— is fully effective now, independent of the retry loop. When #2049 lands, the extended ride-out budget activates automatically. The two forward-ports touch disjoint files and do not conflict, as the ticket states.Landing authority: dev-factory
mainis LANDING=push per df #276 (a3c9f50, "retire the #220 interim rail: dev-factory LANDING back to push", 2026-10-17) — no human merge gate, unlike the LANDING=pr that routed sibling #2049.Ruled by agent under ADR 0174 — veto anytime. Advances #2052's OWED tail.
reset --hard origin/mainmid-run is attributed to the worker and DELETES main-owned machinery (run 57327 lost #2099) #2104