Skip to content

feat(bin): add rework signals section to Wake daily records - #53

Merged
clarsen merged 5 commits into
mainfrom
fm/wake-story3-rework
Nov 22, 2026
Merged

clarsen merged 5 commits into
mainfrom
fm/wake-story3-rework

Conversation

@clarsen

@clarsen clarsen commented Nov 22, 2026 •

Copy link
Copy Markdown
Owner

Intent

I approve the wake question.

Story 3, Rework signals from the forge and project clones: The record's rework section lists reverts in project clones and, for each of the fleet's task PRs/MRs, closed-unmerged state and failed pipelines, each with its time, read-only. These are the three rework signals the captain marked useful (13, 14, 15). Stories 15 and 16 reuse its forge reads.
Verify: For 2026-11-19 the record lists the lblnet_hostupdate revert a83fbcb64; for a day with a known task MR closed unmerged and a known red task-MR pipeline, it lists both with their URLs; the section has no relaunch field; a forge that cannot be reached is named in coverage, not counted as zero.

Context: the captain approved Wake on 2026-11-21 ("I approve the wake question"), a firstmate throughput retrospective built as a deterministic daily collector plus a thin /wake judgment skill. The collector's first slice is merged (#50, bin/fm-wake-daily.py writing data/wake/daily/.json with one section per signal). The captain kept 7 signals: 2, 3, 5, 6, 13, 14, 15. Product-owner tickets: ~/src/therealfirstmate/data/wake-value-model-revise/tickets (value-model.md, initiative-wake.md, epic-wake-daily-record/tickets/tickets.toml). Changes land only in the fork github.com/clarsen/firstmate.

What Changed

  • bin/fm-wake-daily.py adds a rework section to the daily record, with three lists:
    • reverts: commits whose subject starts with Revert in local projects/ clone history (read with git log --all), with the commit time and a commit URL built from the clone's origin.
    • closed_unmerged: fleet task PRs/MRs that were closed without a merge on that Pacific day.
    • failed_pipelines: failed GitLab MR pipelines and failed GitHub pull request workflow runs, each with its own URL and the task PR/MR URL.
  • The collector finds task PR/MR URLs in ship rows, fleet ledger events and state/*.meta files, and reduces each to its canonical URL. It reads only tasks that were in flight that day. A done task with no recorded start is assumed to have started 14 days before its done day, and coverage.forge_candidates reports how many tasks used that assumption. Forge reads are read-only glab api / gh api calls. If a clone or forge can't be read, or a response hits a page limit, that signal is marked not_measurable in coverage.signals, and the clone or forge URL that failed is named in coverage.inputs, so it never shows up as a measured zero.
  • Adds tests/fm-wake-daily-rework.test.sh and gives it a duration hint in bin/fm-test-run.sh. Updates docs/wake-daily.md to describe the new section, its inputs and the coverage behaviour.

Risk Assessment

✅ Low: The rework collector only reads data and adds a section. The fixes from earlier rounds are in the current code: canonical PR/MR URL keys, the no-origin fallback, a per-day candidate window with a 14-day assumed start, skipping already-merged PRs for closed_unmerged, and unreadable PRs named in coverage only on their candidate days. Tracing the fixture days (2026-11-19, 11-18, 11-17, 10-20) gave the expected candidates, events, and coverage, and nothing else turned up as a wrong result that intended usage would reach.

Testing

I drove the real collector CLI against a disposable home in /tmp, using a real lblnet_hostupdate clone and the live lsg-git GitLab and GitHub APIs with the machine's existing logins. Read-only checks only: no forge or clone state was changed. The real revert a83fbcb64, the closed-unmerged MR 3977 and MR 3968's failed pipelines all appeared on 2026-11-19 with their URLs, and an independent glab query returned the same pipelines. The failed run on GitHub PR #53 appeared on 2026-11-21. There is no relaunch field. The unreachable forge was named in coverage, and both forge signals were marked not_measurable rather than zero. The focused rework test also passed. I removed the disposable home afterward, and the worktree is clean. This is a CLI that writes JSON records, so there is no UI to screenshot; the evidence is the JSON records it wrote.

  • Live validation: ✅ go - 6 of 6 scenarios driven live against the product
Scenario Result Live Evidence
Collect 2026-11-19 with a real lblnet_hostupdate clone: rework.reverts lists a83fbcb64 with its time and lsg-git commit URL ✅ pass live live-2026-11-19-measured.json: reverts[0].commit=a83fbcb6410e…, at 2026-11-19T20:12:44Z, evidence https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb64…; reverts measured, count 1
Real task MR closed unmerged on 2026-11-19 (lsg-git MR 3977) is listed with its URL and close time ✅ pass live live-2026-11-19-measured-summary.txt: closed_unmerged=[MR 3977], at 2026-11-20T00:49:51Z (16:49 Pacific on the 19th); measured, count 1
Real red task-MR pipelines on 2026-11-19 (MR 3968) are listed with pipeline URL, MR URL and time ✅ pass live live-2026-11-19-rework.txt: six failed pipelines (866383 … 866484), matching an independent glab query for failed pipelines on refs/merge-requests/3968 that day
Real failed GitHub pull_request run on PR #53 appears on its Pacific day 2026-11-21 ✅ pass live live-2026-11-21-github-summary.txt: actions/runs/44991191376 listed; forge input readable; failed_pipelines measured, count 1
The rework section has no relaunch field ✅ pass live live-2026-11-19-measured-summary.txt: rework_keys = [closed_unmerged, failed_pipelines, reverts]
Adversarial: a task MR on an unreachable forge (gitlab.invalid) is named in coverage and not counted as zero ✅ pass live live-2026-11-19-rework.txt: forge:https://gitlab.invalid/... has status not_measurable; closed_unmerged and failed_pipelines both not_measurable with count null and partial observed counts of 1 and 6;…
Evidence: Live 2026-11-19 record (real clone and forge, plus unreachable forge)
{
  "contributions": {
    "projects": []
  },
  "coverage": {
    "forge_candidates": {
      "assumed_start": 3,
      "assumed_start_rule": "done day minus 14 days when no start is recorded",
      "count": 3
    },
    "inputs": {
      "/tmp/wake-live.PfPbhy/data/backlog.md": {
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/data/captain-questions.json": {
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/data/done-archive.md": {
        "reason": "absent",
        "status": "not_measurable"
      },
      "/tmp/wake-live.PfPbhy/projects": {
        "clones": 1,
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/projects/lblnet_hostupdate": {
        "status": "readable"
      },
      "forge:https://gitlab.invalid/team/proj/-/merge_requests/1": {
        "reason": "forge unreachable or invalid response",
        "status": "not_measurable"
      },
      "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968": {
        "status": "readable"
      },
      "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977": {
        "status": "readable"
      }
    },
    "ledger_duplicates_dropped": 0,
    "limits": [
      "Sessions outside firstmate are invisible.",
      "Backlog-only dates are day-level; backlog decisions are dated by their task's close date.",
      "A merge is a contribution, not proof of production value."
    ],
    "merge_time_source": "done-archive",
    "signals": {
      "closed_unmerged": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md",
          "forge:https://gitlab.invalid/team/proj/-/merge_requests/1"
        ],
        "observed": 1,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      },
      "decisions": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md"
        ],
        "observed": 0,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      },
      "failed_pipelines": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md",
          "forge:https://gitlab.invalid/team/proj/-/merge_requests/1"
        ],
        "observed": 6,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      },
      "links": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md"
        ],
        "observed": 6,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      },
      "reverts": {
        "count": 1,
        "status": "measured"
      },
      "scouts": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md"
        ],
        "observed": 0,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      },
      "ships": {
        "count": null,
        "inputs": [
          "/tmp/wake-live.PfPbhy/data/done-archive.md"
        ],
        "observed": 0,
        "reason": "missing or unreadable input",
        "status": "not_measurable"
      }
    },
    "uncounted_decisions": {
      "count": 0,
      "reason": "answer time unknown (task still open)"
    }
  },
  "day": "2026-11-19",
  "links": {
    "items": [
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "https://gitlab.invalid/team/proj/-/merge_requests/1",
        "id_family": null,
        "kind": "mr",
        "origin_tasks": [],
        "project": "proj",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": [],
        "task": "live-unreachable"
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "id_family": null,
        "kind": "mr",
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": [],
        "task": "live-red"
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977",
        "id_family": null,
        "kind": "mr",
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": [],
        "task": "live-closed"
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "live-closed",
        "id_family": null,
        "kind": "task",
        "mrs": [
          "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"
        ],
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": []
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "live-red",
        "id_family": null,
        "kind": "task",
        "mrs": [
          "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968"
        ],
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": []
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "live-unreachable",
        "id_family": null,
        "kind": "task",
        "mrs": [
          "https://gitlab.invalid/team/proj/-/merge_requests/1"
        ],
        "origin_tasks": [],
        "project": "proj",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": []
      }
    ]
  },
  "rework": {
    "closed_unmerged": [
      {
        "at": "2026-11-20T00:49:51.669000Z",
        "task": "live-closed",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"
      }
    ],
    "failed_pipelines": [
      {
        "at": "2026-11-19T22:40:11.237000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866383"
      },
      {
        "at": "2026-11-19T22:44:06.852000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866399"
      },
      {
        "at": "2026-11-19T22:58:37.155000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866417"
      },
      {
        "at": "2026-11-19T23:18:19.593000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866428"
      },
      {
        "at": "2026-11-19T23:33:23.899000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866481"
      },
      {
        "at": "2026-11-19T23:35:56.970000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866484"
      }
    ],
    "reverts": [
      {
        "at": "2026-11-19T20:12:44Z",
        "commit": "a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "evidence": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "project": "lblnet_hostupdate",
        "subject": "Revert \"CI generated outputs\""
      }
    ]
  },
  "schema": "fm-wake-daily.v1",
  "timezone": "America/Los_Angeles"
}
Evidence: Live 2026-11-19 rework and coverage excerpt
{
  "rework": {
    "closed_unmerged": [
      {
        "at": "2026-11-20T00:49:51.669000Z",
        "task": "live-closed",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"
      }
    ],
    "failed_pipelines": [
      {
        "at": "2026-11-19T22:40:11.237000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866383"
      },
      {
        "at": "2026-11-19T22:44:06.852000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866399"
      },
      {
        "at": "2026-11-19T22:58:37.155000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866417"
      },
      {
        "at": "2026-11-19T23:18:19.593000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866428"
      },
      {
        "at": "2026-11-19T23:33:23.899000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866481"
      },
      {
        "at": "2026-11-19T23:35:56.970000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866484"
      }
    ],
    "reverts": [
      {
        "at": "2026-11-19T20:12:44Z",
        "commit": "a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "evidence": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "project": "lblnet_hostupdate",
        "subject": "Revert \"CI generated outputs\""
      }
    ]
  },
  "cov_signals": {
    "reverts": {
      "count": 1,
      "status": "measured"
    },
    "closed_unmerged": {
      "count": null,
      "inputs": [
        "/tmp/wake-live.PfPbhy/data/done-archive.md",
        "forge:https://gitlab.invalid/team/proj/-/merge_requests/1"
      ],
      "observed": 1,
      "reason": "missing or unreadable input",
      "status": "not_measurable"
    },
    "failed_pipelines": {
      "count": null,
      "inputs": [
        "/tmp/wake-live.PfPbhy/data/done-archive.md",
        "forge:https://gitlab.invalid/team/proj/-/merge_requests/1"
      ],
      "observed": 6,
      "reason": "missing or unreadable input",
      "status": "not_measurable"
    }
  },
  "forge_inputs": {
    "/tmp/wake-live.PfPbhy/projects": {
      "clones": 1,
      "status": "readable"
    },
    "/tmp/wake-live.PfPbhy/projects/lblnet_hostupdate": {
      "status": "readable"
    },
    "forge:https://gitlab.invalid/team/proj/-/merge_requests/1": {
      "reason": "forge unreachable or invalid response",
      "status": "not_measurable"
    },
    "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968": {
      "status": "readable"
    },
    "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977": {
      "status": "readable"
    }
  },
  "forge_candidates": {
    "assumed_start": 3,
    "assumed_start_rule": "done day minus 14 days when no start is recorded",
    "count": 3
  }
}
Evidence: Live 2026-11-19 measured record
{
  "contributions": {
    "projects": []
  },
  "coverage": {
    "forge_candidates": {
      "assumed_start": 2,
      "assumed_start_rule": "done day minus 14 days when no start is recorded",
      "count": 2
    },
    "inputs": {
      "/tmp/wake-live.PfPbhy/data/backlog.md": {
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/data/captain-questions.json": {
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/data/done-archive.md": {
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/projects": {
        "clones": 1,
        "status": "readable"
      },
      "/tmp/wake-live.PfPbhy/projects/lblnet_hostupdate": {
        "status": "readable"
      },
      "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968": {
        "status": "readable"
      },
      "forge:https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977": {
        "status": "readable"
      }
    },
    "ledger_duplicates_dropped": 0,
    "limits": [
      "Sessions outside firstmate are invisible.",
      "Backlog-only dates are day-level; backlog decisions are dated by their task's close date.",
      "A merge is a contribution, not proof of production value."
    ],
    "merge_time_source": "done-archive",
    "signals": {
      "closed_unmerged": {
        "count": 1,
        "status": "measured"
      },
      "decisions": {
        "count": 0,
        "status": "measured"
      },
      "failed_pipelines": {
        "count": 6,
        "status": "measured"
      },
      "links": {
        "count": 4,
        "status": "measured"
      },
      "reverts": {
        "count": 1,
        "status": "measured"
      },
      "scouts": {
        "count": 0,
        "status": "measured"
      },
      "ships": {
        "count": 0,
        "status": "measured"
      }
    },
    "uncounted_decisions": {
      "count": 0,
      "reason": "answer time unknown (task still open)"
    }
  },
  "day": "2026-11-19",
  "links": {
    "items": [
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "id_family": null,
        "kind": "mr",
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": [],
        "task": "live-red"
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977",
        "id_family": null,
        "kind": "mr",
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": [],
        "task": "live-closed"
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "live-closed",
        "id_family": null,
        "kind": "task",
        "mrs": [
          "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"
        ],
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": []
      },
      {
        "blocked_by": [],
        "epic_refs": [],
        "family_tasks": [],
        "id": "live-red",
        "id_family": null,
        "kind": "task",
        "mrs": [
          "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968"
        ],
        "origin_tasks": [],
        "project": "lblnet_hostupdate",
        "recorded_on": "2026-11-19",
        "scout_reports": [],
        "scout_tasks": [],
        "story_refs": []
      }
    ]
  },
  "rework": {
    "closed_unmerged": [
      {
        "at": "2026-11-20T00:49:51.669000Z",
        "task": "live-closed",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"
      }
    ],
    "failed_pipelines": [
      {
        "at": "2026-11-19T22:40:11.237000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866383"
      },
      {
        "at": "2026-11-19T22:44:06.852000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866399"
      },
      {
        "at": "2026-11-19T22:58:37.155000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866417"
      },
      {
        "at": "2026-11-19T23:18:19.593000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866428"
      },
      {
        "at": "2026-11-19T23:33:23.899000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866481"
      },
      {
        "at": "2026-11-19T23:35:56.970000Z",
        "pr_url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3968",
        "task": "live-red",
        "time_source": "updated_at",
        "url": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/pipelines/866484"
      }
    ],
    "reverts": [
      {
        "at": "2026-11-19T20:12:44Z",
        "commit": "a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "evidence": "https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb6410e1857fc9dd49e91509f09f1bda445",
        "project": "lblnet_hostupdate",
        "subject": "Revert \"CI generated outputs\""
      }
    ]
  },
  "schema": "fm-wake-daily.v1",
  "timezone": "America/Los_Angeles"
}
Evidence: Live 2026-11-19 measured summary

{"rework_keys":["closed_unmerged","failed_pipelines","reverts"],"reverts":["a83fbcb6410e1857fc9dd49e91509f09f1bda445"],"closed":["https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"],"failed_n":6,"sig":{"reverts":{"count":1,"status":"measured"},"closed_unmerged":{"count":1,"status":"measured"},"failed_pipelines":{"count":6,"status":"measured"}}}

{"rework_keys":["closed_unmerged","failed_pipelines","reverts"],"reverts":["a83fbcb6410e1857fc9dd49e91509f09f1bda445"],"closed":["https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/merge_requests/3977"],"failed_n":6,"sig":{"reverts":{"count":1,"status":"measured"},"closed_unmerged":{"count":1,"status":"measured"},"failed_pipelines":{"count":6,"status":"measured"}}}
Evidence: Live 2026-11-21 GitHub failed run

{"failed":[{"url":"https://github.com/clarsen/firstmate/actions/runs/44991191376","at":"2026-11-22T06:13:52Z"}],"gh_input":{"status":"readable"},"sig":{"count":1,"status":"measured"}}

{"failed":[{"url":"https://github.com/clarsen/firstmate/actions/runs/44991191376","at":"2026-11-22T06:13:52Z"}],"gh_input":{"status":"readable"},"sig":{"count":1,"status":"measured"}}

Pipeline

Updates from git push no-mistakes

✅ **Intent** - passed

✅ No issues found.

✅ **Rebase** - passed

✅ No issues found.

🔧 **Review** - 4 issues found → auto-fixed (2) ✅
  • ⚠️ bin/fm-wake-daily.py:212 - task_prs keys forge reads by the loose PR_URL match (http allowed, plus any trailing [^\s)<>]*), but forge_rework only accepts the strict https GITLAB_MR/GITHUB_PR fullmatch. Any other form is marked 'unsupported forge URL' (line 341), and that makes closed_unmerged and failed_pipelines not_measurable for every day. Example: a Done row in done-archive.md that says ... https://github.com/clarsen/firstmate/pull/7, follow-up or .../pull/7/files or .../merge_requests/42#note_1. PR_URL captures pull/7,, pull/7/files or the #note fragment, GITHUB_PR/GITLAB_MR fail to match, and from then on both forge rework signals are permanently not_measurable even though the PR is readable. A row that has both .../pull/7 and .../pull/7/ already dedups, but these variants don't. Fix: in task_prs, normalize each candidate to the canonical PR/MR URL by searching with GITHUB_PR/GITLAB_MR prefixes (no anchors, stop at the number) before inserting. Other sites with the same rule: line 215 (ledger pr) and line 231 (meta pr=/anchor_pr=/member.*.pr=).
  • ⚠️ bin/fm-wake-daily.py:285 - Every run re-reads the forge for every ship PR ever recorded in backlog.md and done-archive.md, plus ledger and meta PRs. That is 2 glab calls per MR, and 2+N gh calls per GitHub PR (one actions/runs call per commit), each with a 30s timeout, whatever the requested day. As the archive grows to hundreds of PRs, one run makes hundreds to thousands of API calls and can hit the gh rate limit. Also, any one historical PR that can no longer be read (repo deleted or renamed, old forge, lost token scope, rate limit) marks closed_unmerged and failed_pipelines not_measurable for every day from then on, including days unrelated to that PR. The remedy is a product decision: which PRs count as candidates for a given day (for example only tasks open or done within a window around the day, or skipping merged PRs for closed_unmerged). That scope choice is what needs authorization, not the defect itself.
  • ⚠️ bin/fm-wake-daily.py:258 - clone_reverts treats a failed git remote get-url origin as a failed history read. As a result, one local-only clone under projects/ with no origin remote makes the reverts signal not_measurable for every day. The code already has a fallback for this case (evidence: projects/<name>@<sha> when base is None). Fix: only gate coverage on the log read's returncode, and when the remote lookup fails, use base=None.
  • ℹ️ tests/fm-wake-daily-rework.test.sh:34 - The glab and gh stubs return small handwritten JSON (for example MR detail with only state/closed_at/merged_at, and pipelines with only id/status/updated_at/web_url). The user's CLAUDE.md says mock data MUST be based on actual API calls and stored centrally with documentation. Replace these with trimmed real GitLab MR/pipelines and GitHub pulls/commits/actions-runs responses kept in a documented fixture location. That way field-name drift (for example finished_at vs updated_at, conclusion vs status) would be caught.

🔧 Fix applied.
5 issues (1 error, 3 warnings, 1 info) still open:

  • ⚠️ bin/fm-wake-daily.py:212 - task_prs keys forge reads by the loose PR_URL match (http allowed, plus any trailing [^\s)<>]*), but forge_rework only accepts the strict https GITLAB_MR/GITHUB_PR fullmatch. Any other form is marked 'unsupported forge URL' (line 341), and that makes closed_unmerged and failed_pipelines not_measurable for every day. Example: a Done row in done-archive.md that says ... https://github.com/clarsen/firstmate/pull/7, follow-up or .../pull/7/files or .../merge_requests/42#note_1. PR_URL captures pull/7,, pull/7/files or the #note fragment, GITHUB_PR/GITLAB_MR fail to match, and from then on both forge rework signals are permanently not_measurable even though the PR is readable. A row that has both .../pull/7 and .../pull/7/ already dedups, but these variants don't. Fix: in task_prs, normalize each candidate to the canonical PR/MR URL by searching with GITHUB_PR/GITLAB_MR prefixes (no anchors, stop at the number) before inserting. Other sites with the same rule: line 215 (ledger pr) and line 231 (meta pr=/anchor_pr=/member.*.pr=).
  • ⚠️ bin/fm-wake-daily.py:285 - Every run re-reads the forge for every ship PR ever recorded in backlog.md and done-archive.md, plus ledger and meta PRs. That is 2 glab calls per MR, and 2+N gh calls per GitHub PR (one actions/runs call per commit), each with a 30s timeout, whatever the requested day. As the archive grows to hundreds of PRs, one run makes hundreds to thousands of API calls and can hit the gh rate limit. Also, any one historical PR that can no longer be read (repo deleted or renamed, old forge, lost token scope, rate limit) marks closed_unmerged and failed_pipelines not_measurable for every day from then on, including days unrelated to that PR. The remedy is a product decision: which PRs count as candidates for a given day (for example only tasks open or done within a window around the day, or skipping merged PRs for closed_unmerged). That scope choice is what needs authorization, not the defect itself.
  • ⚠️ bin/fm-wake-daily.py:258 - clone_reverts treats a failed git remote get-url origin as a failed history read. As a result, one local-only clone under projects/ with no origin remote makes the reverts signal not_measurable for every day. The code already has a fallback for this case (evidence: projects/<name>@<sha> when base is None). Fix: only gate coverage on the log read's returncode, and when the remote lookup fails, use base=None.
  • ℹ️ tests/fm-wake-daily-rework.test.sh:34 - The glab and gh stubs return small handwritten JSON (for example MR detail with only state/closed_at/merged_at, and pipelines with only id/status/updated_at/web_url). The user's CLAUDE.md says mock data MUST be based on actual API calls and stored centrally with documentation. Replace these with trimmed real GitLab MR/pipelines and GitHub pulls/commits/actions-runs responses kept in a documented fixture location. That way field-name drift (for example finished_at vs updated_at, conclusion vs status) would be caught.
  • 🚨 bin/fm-wake-daily.py:247 - Introduced by the round-1 fix for unbounded-forge-scan. When task_spans has no start for a task, it uses the done day as the start: spans[task] = (starts.get(task) or end, end) (docs/wake-daily.md:33 says 'A done task with no recorded start is read only on its done day'). On historical days that fallback is almost always what runs, because start days come from only two places. (1) A row's (since D) tag: Done/archive rows carry (merged D)/(done D), and no Done fixture in the repo keeps a since tag. (2) Ledger task.dispatched events: build() loads the ledger only when day &gt;= LEDGER_CUTOFF (2026-11-21), so before that date the ledger list is always empty. Concrete case: a task MR has a failed pipeline on 2026-11-18, the worker fixes it, and the row reads (merged 2026-11-19). Collecting 2026-11-18 skips the MR at line 342 because day < start == 2026-11-19. Nothing is read and no coverage input is recorded, so failed_pipelines reports measured with the red pipeline left out. Red pipelines normally happen before the merge or done day, so historical failed_pipelines counts are undercounted with no visible failure. That conflicts with the intent's check that 'for a day with a known red task-MR pipeline, it lists [it] with [its] URL'. An MR closed unmerged on a day other than its row's done day (for example archived later) is dropped the same way. The test only covers rows whose events fall on their done day, plus an open task with a since tag, so it cannot catch this. Possible remedies: treat an unknown start as unbounded (start=None), use a fixed lookback before the done day, or read the ledger's dispatch events for span purposes regardless of the cutoff. Choosing among them changes the candidate scope the user decided on, so the remedy, not the defect, needs authorization.

🔧 Fix applied.
1 info still open:

  • ℹ️ tests/fm-wake-daily-rework.test.sh:34 - The glab and gh stubs return small handwritten JSON (for example MR detail with only state/closed_at/merged_at, and pipelines with only id/status/updated_at/web_url). The user's CLAUDE.md says mock data MUST be based on actual API calls and stored centrally with documentation. Replace these with trimmed real GitLab MR/pipelines and GitHub pulls/commits/actions-runs responses kept in a documented fixture location. That way field-name drift (for example finished_at vs updated_at, conclusion vs status) would be caught.

✅ No issues found.

✅ **Test** - passed

✅ No issues found.

  • Live validation: ✅ go - 5 of 5 scenarios driven live against the product
Scenario Result Live Evidence
Collect 2026-11-19 from a fresh clone of lblnet_hostupdate; the record lists revert a83fbcb64 with its time and commit URL ✅ pass live record-2026-11-19.json: rework.reverts[0].commit=a83fbcb6410e…, at 2026-11-19T20:12:44Z, evidence https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb64…; signals.reverts measured count 1
Collect a day that has a real closed-unmerged task MR and a real red task-MR pipeline; the record lists both with URLs and times ✅ pass live record-2026-11-19.json: closed_unmerged = MR !3979 at 2026-11-20T00:57:42Z (16:57 PT on 11-19); failed_pipelines = pipelines 866903 and 866905 on MR !3989, which merged on 11-20, with its pr_url; both…
The rework section has no relaunch field ✅ pass live no-relaunch-check.txt: rework keys are exactly closed_unmerged, failed_pipelines, reverts, and no key containing 'relaunch' appears anywhere in the record
Adversarial check: a task MR on an unreachable forge is named in coverage instead of being counted as zero ✅ pass live record-2026-11-19-unreachable-forge.json: coverage.inputs['forge:https://gitlab.fm-lab.invalid/grp/proj/-/merge_requests/7'] is not_measurable; closed_unmerged and failed_pipelines are not_measurable…
The run is read-only and idempotent: the clone and source files are unchanged, and a repeat run leaves the record bytes unchanged ✅ pass live readonly-check.txt; cmp after the repeat run reported the record byte-identical
  • git clone --filter=blob:none --no-checkout https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate.git $LAB/projects/lblnet_hostupdate (disposable lab home)
  • python3 bin/fm-wake-daily.py 2026-11-19 --home $LAB with backlog ship rows for real MRs !3979 (closed unmerged), !3989 (red pipelines, merged 2026-11-20) and GitHub PR clarsen/firstmate#50
  • jq check that the rework section has only reverts/closed_unmerged/failed_pipelines and no relaunch key anywhere in the record
  • Repeat run with the same inputs; cmp showed the record file is byte-identical
  • python3 bin/fm-wake-daily.py 2026-11-19 --home $LAB-unreach with an extra MR row on unresolvable host gitlab.fm-lab.invalid (real glab call fails)
  • Read-only check: the clone's refs and config and the source data hashes are unchanged after a run
  • bash tests/fm-wake-daily-rework.test.sh

✅ No issues found.

  • Live validation: ✅ go - 6 of 6 scenarios driven live against the product
Scenario Result Live Evidence
Collect 2026-11-19 with a real lblnet_hostupdate clone: rework.reverts lists a83fbcb64 with its time and lsg-git commit URL ✅ pass live live-2026-11-19-measured.json: reverts[0].commit=a83fbcb6410e…, at 2026-11-19T20:12:44Z, evidence https://lsg-git.lbl.gov/lblnet/lblnet_hostupdate/-/commit/a83fbcb64…; reverts measured, count 1
Real task MR closed unmerged on 2026-11-19 (lsg-git MR 3977) is listed with its URL and close time ✅ pass live live-2026-11-19-measured-summary.txt: closed_unmerged=[MR 3977], at 2026-11-20T00:49:51Z (16:49 Pacific on the 19th); measured, count 1
Real red task-MR pipelines on 2026-11-19 (MR 3968) are listed with pipeline URL, MR URL and time ✅ pass live live-2026-11-19-rework.txt: six failed pipelines (866383 … 866484), matching an independent glab query for failed pipelines on refs/merge-requests/3968 that day
Real failed GitHub pull_request run on PR #53 appears on its Pacific day 2026-11-21 ✅ pass live live-2026-11-21-github-summary.txt: actions/runs/44991191376 listed; forge input readable; failed_pipelines measured, count 1
The rework section has no relaunch field ✅ pass live live-2026-11-19-measured-summary.txt: rework_keys = [closed_unmerged, failed_pipelines, reverts]
Adversarial: a task MR on an unreachable forge (gitlab.invalid) is named in coverage and not counted as zero ✅ pass live live-2026-11-19-rework.txt: forge:https://gitlab.invalid/... has status not_measurable; closed_unmerged and failed_pipelines both not_measurable with count null and partial observed counts of 1 and 6;…
  • python3 bin/fm-wake-daily.py 2026-11-19 --home &lt;disposable home&gt; with a real lblnet_hostupdate clone, real MRs 3977 and 3968, and a gitlab.invalid MR row
  • python3 bin/fm-wake-daily.py 2026-11-19 --home &lt;disposable home&gt; rerun with the unreachable row removed and an empty done-archive.md, to show all three signals measured
  • python3 bin/fm-wake-daily.py 2026-11-21 --home &lt;disposable home&gt; with real GitHub PR clarsen/firstmate#53 and an empty fleet ledger
  • Cross-checked against independent read-only glab api and gh api queries for closed MRs and failed pipelines and runs
  • bash tests/fm-wake-daily-rework.test.sh (prints ok: Wake daily rework collector)
✅ **Document** - passed

✅ No issues found.

✅ No issues found.

✅ **Lint** - passed

✅ No issues found.

✅ No issues found.

✅ **Push** - passed

✅ No issues found.

✅ No issues found.

…test.sh but gives it no duration hint in bin/fm-test-run.sh. That leaves 44 of 292 portable serial scripts without a hint (15.07%), over the coverage guard's 15% cap. Rule that broke: no more than 15% of portable serial scripts may lack a duration hint. The rule is checked in one place, the hint table in bin/fm-test-run.sh, so that is the one place to fix. Fix: I added `tests/fm-wake-daily-rework.test.sh 1600` to the hint table, just before `tests/fm-wake-daily.test.sh 1600`. The table's comment allows a new test to use a local sample until CI has measured it, and PR #50 added the sibling test's hint the same way. The new test took about 1.6s locally. Verified: - `bin/fm-test-run.sh --check-coverage` passes (`FM_TEST_COVERAGE ok`, serial_unhinted=43). - tests/fm-wake-daily-rework.test.sh and tests/fm-wake-daily.test.sh pass. - tests/fm-test-run.test.sh, the shard 2 test that runs the real coverage check, now passes every coverage subtest. That includes "portable shard union, disjointness, and coverage guard hold" and "coverage guard bounds the unmeasured share and serial packing within twenty minutes", so the shard 2 failure was almost certainly this missing hint. - **Test coverage guard:** fixed directly by this change. - **Full suite:** a summary check that fails when any lane fails, so it should clear once the other two pass. - **Behavior portable parallel 2:** its coverage subtests pass locally, but tests/fm-test-run.test.sh still exits 1 here. Its "--jobs on a proven family" subtest runs tests/fm-session-lock-ancestry.test.sh, which fails with "not ok - the fixture hook never finished". That script also fails when run on its own on this host. This PR does not change it or the session-lock code (its diff against base is empty), so I treat it as a local host problem and made no change for it. I could not finish a full local run of the portable-parallel-2 lane: it was stopped at the 10-minute background limit, and that run had also started before the fix
@clarsen
clarsen force-pushed the fm/wake-story3-rework branch from 6e66945 to ba80bcf Compare November 22, 2026 18:00
@clarsen clarsen changed the title feat(bin): add rework signals to Wake daily record feat(bin): add rework signals section to Wake daily records Nov 22, 2026
…l 1". It failed because of today's date, not because of the PR's code. "Full suite" only fails when another lane fails, so it should clear once serial 1 passes. **What failed:** `tests/fm-wake-daily.test.sh` reported `not ok - incomplete day wrote a record`. This test came from the base branch and the PR doesn't change it. **Why:** the test collects records for a fixed day, `POST=2026-11-22`, and writes `data/wake/daily/2026-11-22.json`. At the end it runs the collector for today's date, which it expects to be rejected as not yet complete, and then asserts that no file exists for today. CI ran on 2026-11-22, so today was the same day as `POST`. The collector correctly rejected the run, but the file written earlier by the same test was already there, so the assertion failed. The test would fail on any day that matches one of its fixed fixture days. **Rule broken:** the "incomplete day wrote no record" check must only see what the incomplete-day run itself writes. That check, on that one path, is the only place that depends on it. **Fix:** in `tests/fm-wake-daily.test.sh`, one `rm -f "$CASE_HOME/data/wake/daily/$TODAY.json"` line (plus a comment) right before the incomplete-day call. The check still fails if the collector ever writes a record for an incomplete day. `tests/fm-wake-daily-rework.test.sh` doesn't use the current date, so nothing else needed the same change. No product code changed. **Verified on 2026-11-22, the date that broke CI:** - `tests/fm-wake-daily.test.sh` failed before the change with the same message as CI, and now passes (`ok: Wake daily collector`). - `tests/fm-wake-daily-rework.test.sh` still passes. - shellcheck reports only an info-level SC1091 note about sourcing `tests/lib.sh`, which was already there. I did not run the full serial 1 lane locally
@clarsen
clarsen merged commit 10ba33f into main Nov 22, 2026
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant