Skip to content

ci: record the evidence archive, delivery and cadence decision #2951

Closed

Description

@schlessera

Part of #2948 (task 2).

Context

The maintainer ruled on #2948 on 2026-10-25: the durable archive is an append-only data ref with monthly compact files, leakage-screened and updated with exact --force-with-lease like refs/heads/brain-integration-reservation (bun scripts/integrate.ts, docs/decisions/ci-utility.md:1350-1359); reports are delivered as comments on one pinned tracking issue; a weekly report always posts and a daily digest posts only when something changed; runner-slot wait is a first-class metric (#2939). The epic's constraints require each new workflow write permission to be recorded in a decision before code.

Maintainer decision — 2026-11-08

The maintainer settled the remaining archive choices:

  1. Data ref: refs/heads/brain-ci-metrics.
  2. Monthly file layout: one UTC calendar-month partition, YYYY-MM/<record-kind>.json.
  3. Schema evolution: each record kind carries an integer version; readers refuse unknown versions. Schema changes append a new version without rewriting archived records. ci: inventory every integration metric with its source, schema and status #2950 assigns the numeric versions per kind.
  4. Red-main daily trigger: any newly observed red-main incident qualifies for the next daily digest, including a brief incident. There is no minimum-duration threshold. Re-observing the same unchanged incident must not repeatedly qualify it as new. Weekly reports always post; gate changes and collection gaps independently trigger daily delivery.

This resolves the choices in the readiness review and supersedes the earlier threshold deferral. The existing #2948 archive/delivery/cadence, permission and retention decisions remain binding. No archive ref, workflow or scheduled delivery is created by recording this ruling.

Scope

Add a decision record, docs/decisions/ci-evidence.md (with an index entry in docs/decisions/README.md), that records the #2948 ruling and this issue's 2026-11-08 selections, fixes the data ref, monthly layout and schema-version rule, the leakage screen, the retention split (artifacts 90 days, data ref permanent), the delivery and cadence rules (including the newly-observed-incident trigger consumed by #2956), and the exact job-scoped permissions: contents: write only for the job that writes the data ref, issues: write only for the job that posts reports. Reference it from docs/process/ci-timings.md.

Out of scope

  • Any workflow or script change.

Acceptance criteria

  • The record cites Epic: CI and integration evidence is collected, archived beyond GitHub retention and reported automatically #2948 and its 2026-10-25 decision comment, plus this issue's dated maintainer ruling, and states every element above.
  • It fixes refs/heads/brain-ci-metrics, UTC YYYY-MM/<record-kind>.json, per-kind integer versions assigned by ci: inventory every integration metric with its source, schema and status #2950, unknown-version refusal and immutable prior records.
  • It defines the next-daily-digest trigger as any newly observed red-main incident, with no minimum duration and no repeat delivery merely for observing the same unchanged incident. Weekly-always, gate-change and collection-gap delivery remain as ruled.
  • It documents artifacts retained for 90 days, the permanent measurement data ref, leakage screening, exact force-with-lease updates, and job-scoped contents: write / issues: write without granting those permissions to other jobs.
  • It states that the archive is measurement only and never an input to proof, selection or merging.
  • tests/decision-citations.test.ts passes with any code citations it adds.

Verification

bun run test tests/decision-citations.test.ts; bun run lint.

Contract impact

None.
2026-11-04 triage: folded the later unresolved choices into the body. Classified the documentation-only deliverable as type: docs; preserved the existing milestone and decision prerequisite. Code-citation drift is a release experiment check; the checker’s own unit tests remain applicable.

2026-11-08 decision reconciliation: folded all four maintainer choices into the current brief and acceptance criteria. No other needs: prerequisite remains; the documentation task is agent-ready. Preserve its existing 0.45.0 release commitment and its dependants' actual implementation prerequisites.

Activity

  1. added
    type: chore
    area: ci
    area: docs
    priority: p1
    agent-ready
    on Oct 25, 2026
  2. added this to the 0.45.0 milestone on Oct 25, 2026
  3. added
    needs: decision
    and removed
    agent-ready
    on Nov 3, 2026
  4. schlessera commented on Nov 3, 2026

    @schlessera
    OwnerAuthor

    2026-11-03 readiness review at main d142e997b. The #2948 ruling (2026-10-25) settles the archive form, the retention split, the job-scoped permissions, delivery to one pinned issue, the cadence rules and the runner-slot metric. The scope also asks this record to fix three things that ruling does not settle:

    1. The data ref's name. The ruling only gives refs/heads/brain-ci-metrics as an example, and ci: archive CI evidence beyond GitHub retention and backfill the current artifacts #2955 writes to "the data ref named in the ci: record the evidence archive, delivery and cadence decision #2951 decision". Recommendation: refs/heads/brain-ci-metrics.
    2. The monthly file layout. Recommendation: one partition per UTC calendar month, YYYY-MM/<record-kind>.json. The alternative is to state only the monthly partitioning and leave the paths to ci: archive CI evidence beyond GitHub retention and backfill the current artifacts #2955.
    3. The schema-version rule. Recommendation, following the existing collector behaviour in scripts/ci-timings.ts:

    The red-main incident "threshold" for the daily digest also has no value in the ruling. Unless a value is ruled, the record will quote it unchanged and state that no value is set.

    Also corrected the body's stale citation: the reservation-ref passage is now at docs/decisions/ci-utility.md:1302-1312.

    To resume: a maintainer ruling on points 1–3, then remove needs: decision and restore agent-ready.

  5. added
    type: docs
    and removed
    type: chore
    on Nov 4, 2026
  6. schlessera commented on Nov 8, 2026

    @schlessera
    OwnerAuthor

    Decision (maintainer, 2026-11-08):

    • Ref: refs/heads/brain-ci-metrics.
    • Layout: UTC YYYY-MM/<record-kind>.json.
    • Versions: per-kind integers; refuse unknown versions; append new versions without rewriting old records. ci: inventory every integration metric with its source, schema and status #2950 assigns the numeric versions.
    • Daily red-main trigger: any newly observed red-main incident, with no minimum duration. Re-observing the same unchanged incident is not a new trigger. Weekly reports always post; gate changes and collection gaps remain independent daily triggers.

    The body and documentation acceptance criteria now contain these choices, alongside #2948's existing append-only archive, retention, leakage-screening, exact force-with-lease, pinned-issue delivery and job-scoped permission rules. The previous threshold deferral is superseded. The archive remains measurement only, never proof/selection/merge input.

    Remove needs: decision and add agent-ready; no other needs: label remains. This readies the decision-record task, preserves its existing 0.45.0 milestone, and does not create an archive ref or enable a workflow. #2955 still waits for the actual record; #2956 must consume the selected daily trigger.

  7. added
    agent-ready
    and removed
    needs: decision
    on Nov 8, 2026
  8. self-assigned this
    on Nov 15, 2026
  9. schlessera commented on Nov 15, 2026

    @schlessera
    OwnerAuthor

    Claimed for implementation. Claim token: claim-8352958f. Branch: docs/2951-ci-evidence.

    No path or closure collisions; no active implementation PR.

  10. schlessera commented on Nov 15, 2026

    @schlessera
    OwnerAuthor

    Delivered in PR #4004, squash b22ca4b on main. Citation checker: 42 passed. Local check:pr passed all selected checks after frozen-lockfile dependency installation. Candidate CI run 43718084613 passed; the squash parent and tree exactly match its verified checkout. PR and issue milestones read back as 0.45.0 after closure. No follow-up issues filed. Automatic main CI run 43718464606 is still in progress; its selected jobs must be inspected before claiming post-merge proof complete.

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

Metadata

Metadata

Assignees

Labels

agent-readyarea: ciarea: docspriority: p1type: docs

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions