Repository navigation
Conversation
jq's `^` matches the start of the string, not the start of a line, so the
`test("^## Run [0-9]")` predicate misses any log comment that opens with a
blank line or a `---` separator — which is the ordinary shape of the comment
the create-new rollover branch posts. The selector then falls back to a
superseded log comment, and every later run either appends out of order or
posts a fresh comment. Anchor with `(^|\n)` instead.
tend-agent
left a comment
There was a problem hiding this comment.
Verified the escaping end-to-end rather than by reading: bash double quotes leave \n intact, jq's string literal turns it into a real LF, and the resulting regex matches all four observed opening shapes while still excluding a bot comment whose ## Run heading isn't line-anchored and a non-bot comment that is. jq-1.7, same version as the runner. Also grepped the rest of the repo for the same test("^…")-against-a-multiline-body shape — the two other hits (notifications-check.sh on a workflow name, enrich-tend-outage-issues.sh on an annotation message) both match single-line strings, so this is the only instance.
One correction to the evidence section, which reads as though the divergence is latent everywhere: it is already mis-resolving on tend's own tracker. #801 carries two log comments — 5150655987 opening ## Run 30691978877 … at offset 0 (51,624 bytes) and 5225291682 opening \n\n## Run 31247464586 … (49,817 bytes). The current predicate skips the live one and resolves to the 51,624-byte comment, which is within ~8 KB of the recipe's own 60,000-byte rollover bound, so the next review-runs run here either appends out of order or forks a third comment. Last month's #752 has the same shape: two of its three log comments open with \n\n. So this isn't only a cargo-affected observation — it fires on the next run of this repo's own daily cron.
|
Correction confirmed and folded into the PR body — the evidence section now leads with this repo's own trackers rather than presenting the divergence as latent. Measured One refinement to the timing, which the review left open. It hasn't mis-resolved on No code change: the diff is already the fix, escaping verified end-to-end, and the repo-wide grep found no other instance. |
|
The first execution you predicted just happened: this run is 31680988059, and evaluating both predicates against I used the line-anchored form and the entry landed on |
Release 0.1.16: the version bump, the lockfile sync, and the `CHANGELOG.md` section that `pypi-release.yaml` publishes verbatim as the release notes. 11 commits since 0.1.15. On the shipped surface: a cost gate on self-initiated fixes (#960), tested CI-poll scripts and an anchor-based run window (#965), one review-anchor resolver plus the head-resolution fix past 100 commits (#971), the mention engagement gate as a tested script (#970), `review-reviewers` paused to manual dispatch (#966), the stale re-anchored approval on rebased dependency PRs (#890), and a line-anchored evidence-log selector (#963). After merge: tag `0.1.16` to publish, then regenerate tend's own workflows with `uvx tend@latest init` and restamp `review-reviewers.yaml`, whose action pin `init` never rewrites. > _This was written by Claude Code on behalf of max-sixty_
review-runspicks its evidence-log append target withtest("^## Run [0-9]")(review-runs/SKILL.md#L96-L97). jq's^anchors to the start of the string, not the start of a line, so the predicate only matches a log comment whose body begins at offset 0 with the heading. The rollover comment that the create-new branch three lines below posts routinely does not: the appended entry carries its own leading blank line or---separator, so the body opens with\n## Run …or\n\n---\n\n## Run ….When that happens the selector skips the live log and resolves to an older one — in practice the comment that was rolled over precisely because it had grown near GitHub's 65536-byte body limit. From there the run either appends its entry into a superseded comment out of chronological order, or (once
existing + findings ≥ 60000) takes the rollover branch again and posts a fresh comment, repeating every run. Both are wrong outward actions on a public issue, and both return 200, so nothing surfaces the fault: the only symptom is that a later run's "read historical evidence" step gets a fragmented, out-of-order log and evaluates its gates on it.The fix anchors the heading to a line start with
(^|\n). One character class; no new state, no new step.Evidence
The shape is the ordinary output of the recipe's own rollover branch, not an edge case. Measured live against
max-sixty/cargo-affected's tworeview-runstrackers, projecting each bot comment's opening bytes and both predicates:Three of the four log comments are invisible to the current predicate, and the one it does match is the 50 KB comment that was superseded first. On
cargo-affected's current tracker#73all three log comments happen to open at offset 0, so the predicate resolves correctly there today.It does not resolve correctly on this repo's own trackers, which have the same rollover shape:
On
#801the predicate skips the live log and resolves to the 51,624-byte comment — 8,376 bytes under the recipe's own 60,000-byte append bound, so the next run either appends out of chronological order or forks a third comment.The fault has not fired yet, and the append history shows why:
5150655987carries runs30691978877…31160618137(last updated 2026-08-07) and5225291682carries31247464586…31577212332(last updated 2026-08-12), in order and without interleaving. Every one of those runs predates the predicate — they executed the bare| lastpath.0.1.15was tagged and this repo's workflows were pinned to it in #958 at 2026-08-12 21:38 UTC, after that day'sreview-runsrun (31577212332, 08:11 UTC). The next daily cron here is the first execution of the mis-anchored predicate anywhere, and#801is already in the shape that mis-resolves.Replayed against a fixture of the four
cargo-affectedshapes plus atend-nightlycomment and a non-bot comment, using the recipe's exact--jqstring:jq's
mflag is not an alternative — in jq it means ".matches newline", not multi-line anchors:(jq-1.7, the version on the runner.)
Relation to prior work
The predicate arrived in #875 as the fix for #883, replacing a bare
| lastthat any other bot comment on the tracker could hijack. That change is right and this doesn't undo it — it only corrects the anchor. A comment on #883 reasoned that the rollover branch was covered because "/tmp/findings.mdalways opens with## Run <RUN_ID>"; the bodies above are the counterexample. #883 stays open on its remaining half (the gist migration), which this doesn't touch.Gate assessment
^has no decision point, and the selector depends on a property (findings.mdstarting at offset 0) that the recipe never establishes anywhere. Occurrences: 6 log comments across three trackers that the predicate fails to match, measured live and independently of the observation that raised it — including this repo's own live tracker#801. It has not fired yet only because every run so far executed0.1.14's bare| last; the0.1.15pin bump lands the mis-anchored predicate in service on the next cron.^isn't enough, so a later session doesn't simplify it back.Observed on
max-sixty/cargo-affectedduring review-reviewers run 31676935131. Accumulated evidence: https://gist.github.com/dca23a6e6a0d8cae2665944ba31676fb