Skip to content

Estate CI repair: the six diseases (lock edges, standards pins, canon pins, UUIDv8, archetype bugs, actions policy), the proven protocol, and the measured who-still-has-what #319

Open

Description

@hyperpolymath

Estate CI repair: the six diseases, the proven protocol, and who still has them

Context

Three repos have now been fully repaired with the protocol below, each verified green locally with the estate's own gates and then green in CI:

This issue is the follow-up for the rest of the estate. Read the three PRs first; this issue adds only what they do not show.

The six diseases (in dependency order)

1. actions.lock dangling edges → startup_failure, jobs=0

Symptom: workflows die as completed/startup_failure with zero jobs, no logs, no check runs posted. The PR/commit UI shows checks as "expected" forever. Diagnose by the run list: gh run list -R <repo> --json conclusion | grep startup_failure.

Cause: .github/workflows/actions.lock lists a workflow's refs under workflows: but has no matching top-level dependencies: record. Per scripts/check-lock-sync.sh's header (cicd-squabbler, 2026-09-22): a ref present in the lock but unresolvable is FATAL at startup; a ref absent from the lock is harmless. This is why the two locked julia workflows died while 34 unlisted ones ran.

Fix: regenerate the lock transitively closed. gh actions-lock (v0.2.0) writes schema v0.0.3, but it is BLIND to job-level reusable-workflow uses: — it empties their workflows: entries. The repo's own check-lock-sync.sh (clause 1) REQUIRES them locked in subpath-stripped form (e.g. hyperpolymath/standards@<sha>, not .../workflows/x.yml@<sha>). The extension's stale finding on those entries is a known false positive that standards' CURRENT update-actions-lock.sh accepts (verify_lock_coverage); older helper pins do not. So: run the tool, then re-add the stripped entries, then verify with BOTH gates (see Verification below).

Time-saver: the three repaired repos' locks share the same scaffold refs. Reuse their dependencies: records verbatim (they were resolved and verified 2026-10-15); only repo-specific refs need fresh API resolution. Floating @main refs should be resolved fresh.

2. Standards caller pins older than the v0.2.0-aware helpers

Symptom: governance / Actions lockfile verify fails with stale findings even when disease 1 is fixed.
Fix: bump every uses: hyperpolymath/standards/...@da2c748aad55c1a1dcba00b60fe4a35017bc6540 to the current standards main (94572e612a7bf11f8e6343d19adadf17ef2a3de3 as of 2026-10-15; re-check before applying), then update the lock entries for the new pin. Input signatures are backward compatible.

3. Missing [canon] block → Canon lockstep / Dogfood Gate red

Symptom: could not read got_crit — refusing to compare an empty value.
Fix: add to .machine_readable/rsr-profile.a2ml (the file the job reads TODAY; it is legacy .a2ml awaiting kyX's .deed conversion — rulings D313/D320 say do NOT hand-convert; the pin rides the conversion):

[canon]
version = "2.1.2"
criteria_sha256 = "6a5aa8857bd0d0d58ef48827938ca17c251b6b854dacf59d306388d61694d82a"
gates_sha256 = "e70efd2f53c9445e30da4baf770366f04a4a84ffd844a01426e587e565b53e6a"

Read the current values from https://raw.githubusercontent.com/hyperpolymath/standards/main/canon.lock — do not trust this issue's copy if time has passed; a canon release changes them (spine-adopts-then-canon-releases ordering applies to the SPINE, not to catching repos up).

4. UUIDv8 strict migration (ADR-008 amendment D320)

Symptom: governance / UUID v7 conformance and UUID v8 conformance fail with non-v8 UUID literal (...).
Scanner facts: it reads EVERY hyphenated [0-9a-f]{8}-... literal in every non-.a2ml file, COMMENTS INCLUDED. Project.toml [deps]/[weakdeps]/[extras] tables are exempt (external registry ids); Manifests are exempt.
Fix per literal kind:

  • Package identity uuid (Project.toml top-level): re-mint as v8 profile T with the estate generator (bun scripts/uuid-v8.js t from standards, or gh equivalent), note the superseded v5 by pointing at git history WITHOUT spelling the literal (the scanner reads comments).
  • CLAUDE.md identity uuid: same re-mint.
  • EXTERNAL ids (e.g. Arena.ai thread ids in docs/recovered/): DO NOT convert — converting falsifies the record. Write them with underscores (01a0a9f1_d658_...) with a one-line note; that breaks the scanner regex while leaving the fact unchanged.
    Verify with check-uuid-v8.sh --strict . from standards.
    Post-mint: any code referencing the old package uuid keeps working (packages are loaded by name), but re-run the package's tests.

5. The julia-library archetype's own broken gate snippets

In .github/workflows/julia-ci.yml (shipped by rsr-template-repo):

  • fmt job: filter(isfile, Iterators.flatten(...)) is a MethodError (filter over an iterator) — must be collect(Iterators.flatten(...)).
  • fmt job: JuliaFormatter.format_string does not exist in 2.x — must be format_text.
  • jet job: JET.test_package(path=".", julia_version="1") is a MethodError in JET 0.12 — report_package takes the package MODULE. Must be using <Package>; JET.test_package(<Package>).
  • Both julia workflows lack the SPDX header and top-level permissions: that the governance linter requires.
  • julia-docs.yml guards a docs-site capability most minimized profiles do not declare; its own gate prescribes removal. Removing it also retires the julia-actions/julia-docdeploy allowlist gap.
    The archetype itself (rsr-template-repo archetypes/julia-library/) still ships all of these bugs — fixing it there is the real cure; without it every future mint arrives broken.

6. Empty "Allow select actions" policy → EVERY workflow startup_failure

Symptom: identical to disease 1 but the repo's Actions policy is allowed_actions: "selected" with an EMPTY patterns list — no action is permitted, so every run of every workflow dies at startup, including on main.
Affected (measured 2026-10-15): occupancy-types, resource-algebra, absolute-zero.
Fix needs an owner decision (see the linked question below) because it is a security-posture change: either set allowed_actions: all (+ optionally sha_pinning_required: true, the ZeroProb.jl model, which requires SHA-pinned workflow files), or populate the selected-actions patterns (actions/*, github/*, hyperpolymath/*, julia-actions/*, ...). API: PUT /repos/{owner}/{repo}/actions/permissions. Note occupancy-types and resource-algebra and absolute-zero ALSO have diseases 1-4, so fix the policy first, then run the protocol.

JET findings you will meet once the gates actually run (diseases fixed)

The JET gate has never analyzed anything on any julia-library repo (the path= call was a MethodError). Expect real findings; the recurring species and their fixes:

  • Captured-and-reassigned locals in open(...) do closures → Core.Box → Any: restructure to a plain loop with try/finally.
  • Structs with Vector fields: the default convert()-ing constructor explores Vector{X}(B::BitVector) and range dead ends under abstract interpretation. Fix: explicit TYPED inner constructors (new() stores without convert). @kwdef's generated constructor has the same artifact — write the kw constructor explicitly.
  • "x" * replace(s, ...) * "x" three-arg * with an AbstractString middle widens into Base Regex-concat dead ends: build with an IOBuffer loop.
  • Required regex captures: guard with a _required_capture helper that fails loud on the impossible Nothing branch.
  • Untyped function parameters where the body dispatches (!claim): type them (claim::Function).
    Each fix is verified by re-running JET.test_package(<Module>) to zero findings plus the package's test suite.

Verification (all local, no CI needed)

  1. bash scripts/check-lock-sync.sh .github/workflows → "in sync and transitively closed"
  2. bash <standards>/scripts/update-actions-lock.sh --verify-local .github/workflows → exit 0 (accepts the reusable false positives)
  3. bash <standards>/scripts/check-uuid-v8.sh --strict . → clean
  4. bash <standards>/scripts/check-allowed-actions.sh <allowlist.json> .github/workflows → 0 gaps
  5. JuliaFormatter 2.14: 0 unformatted; Pkg.test() green; JET.test_package(<Module>) clean (temp env; JET 0.12.3, Julia 1.13)

Measured state (2026-10-15, from local clones; re-verify before acting)

Repo lock uuid v8 notes
Protoctist.jl GREEN clean healed (#8 merged)
ResidualEvidenceTypes.jl RED on main 2 literals #5 open, heals
EpistemicTypes.jl RED on main 4 literals #7 open, heals
occupancy-types RED 2 literals ALSO policy-blocked (disease 6)
resource-algebra GREEN clean policy-blocked (disease 6) only
absolute-zero RED 1 literal ALSO policy-blocked (disease 6)
choreographic-types RED clean lock disease only
ZeroProb.jl / CompositionalDA.jl / CompositionalCounts.jl ABSENT DA/Counts: 1 literal each unlocked (ledger-excused); UUID literals become live when the strict gate reaches them
odraz (metadatastician) GREEN 1 literal UUID literal only

Also observed: EpistemicTypes.jl main has GitHub Pages and OSSF Scorecard failures not yet diagnosed (investigate after its #7 merges); zero repos' docs-deploy paths were audited beyond Protoctist/RET/EpistemicTypes.

Operational notes for whoever runs this

Owner decisions linked here (do not act without them)

  1. Actions-allowlist posture for occupancy-types / resource-algebra / absolute-zero (disease 6): all+SHA-pinning (ZeroProb model) vs all plain (majority model) vs populated allowlist.
  2. Whether to fix the julia-library archetype in rsr-template-repo (disease 5's real cure) — recommended, affects every future mint.

Activity

  1. hyperpolymath commented on Oct 15, 2026

    @hyperpolymath
    OwnerAuthor

    Addendum (2026-10-15, post-sweep): the "checks hanging forever" mechanism + two new edges

    The hang mechanism (why you force-merge through CodeQL etc.): a workflow that dies as startup_failure creates the run but posts no check run. The PR UI then shows the check as expected/pending forever — nothing failed, nothing will ever arrive. Two estate diseases produce exactly this, both measured today:

    1. Dangling lock edges — the workflow is locked but unresolvable → startup failure → its check never posts (measured: Protoctist, RET, EpistemicTypes, occupancy-types, absolute-zero, choreographic-types).
    2. Empty selected actions allowlist — every workflow including CodeQL dies at startup, so CodeQL's check hangs on every PR (measured: occupancy-types, resource-algebra, absolute-zero before today's policy fix).

    So "CodeQL hangs on hundreds of repos" is this same disease family, not a CodeQL problem. Fixing the sweep = fixing the hang. Post-policy-fix, the CodeQL checks on the three policy-blocked repos should start arriving on their next PRs. The reposystem#319 protocol covers the rest.

    Codeac is different: it's a third-party SaaS app posting its own checks (it posted fine on today's repaired PRs, e.g. Protoctist #7). Its hangs are app-side (its analysis queue per repo) — check the Codeac dashboard for repos with stuck analyses; it is NOT affected by the actions policy and won't be fixed by the sweep.

    New edge for whoever executes the sweep — the rust-ci Detect job: standards' rust-ci-reusable.yml (current main) has a Detect Cargo.toml job that checks out ${{ github.ref }} explicitly. On a pull_request event in a called workflow that is refs/pull/N/merge — fine while open, but on a merged PR's last run the ref no longer exists and the job fails (couldn't find remote ref). Harmless today (non-required), but if any repo makes it a required check, merges will wedge after the fact. Recommend: gate the detect job's checkout on non-merged refs, or use github.sha.

    Progress so far (2026-10-15): Protoctist #8 merged (healed); repair PRs open on ResidualEvidenceTypes #5, EpistemicTypes #7, occupancy-types #13, absolute-zero #190, choreographic-types #33; UUIDv8 mints: odraz #19, CompositionalDA #11, CompositionalCounts #11; archetype root fixes: rsr-template-repo #240 + standards #1268 (the registered julia-package-identity domain). Actions policy set to all + SHA-pinning on the three blocked repos (owner ruling). Remaining rows: resource-algebra (policy fixed; lock was green — should be alive on next push, verify), plus the unaudited remainder of the estate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions