Skip to content

fix(pr-pipeline): write blocked-by edges for blockers the issue body names - #10183

Merged
kyle-sexton merged 6 commits into
mainfrom
fix/admission-text-blockers-native-edges
Oct 26, 2026
Merged

kyle-sexton merged 6 commits into
mainfrom
fix/admission-text-blockers-native-edges

Conversation

@kyle-sexton

Copy link
Copy Markdown
Member

No related issue: owner rule 2026-10-26 (human only for intent, design or HIGH/CRITICAL security); admission bounced issues whose blockers were named only in text
Refs: #8994
Refs: #8989

Summary

Admission reads blockers only from native blocked-by edges. Intake's apply-verdict wrote edges only for the triage model's Blocked by: line, so an issue whose body named its blocker in text (Blocked by: #8753) had no edge. It was admitted, and the issue lane handed it back to a person. Examples: #8994 (open blocker #8753, run 40233438204) and #8989 (open blocker #7613, run 40232047026).

Fix

  • edges.mjs gets textBlockers(body, repository). Candidates come from lines that start with Blocked by or Depends on (an optional list marker or bold is allowed), and from list items under a Blocked by or Depends on heading. Each such line can name #<n> and this repository's issue URLs. The parser ignores fenced and inline code, HTML comments, > quotes, owner/repo#<n>, other repositories' URLs, pull request URLs, none, and mentions in ordinary prose. It returns at most 10 distinct numbers per issue.
  • apply-verdict.mjs merges these candidates with the verdict's own list and passes them to the existing writeEdges. That function already checks that each number is an open issue in this repository and not a pull request, skips edges that already exist, and on a 403, 429 or 5xx records a miss, deletes the edges the run wrote, holds back status: ready, and emits an annotation. Edges are written on escalated verdicts too, so a person who later adds agent-ready by hand still finds them. An untrusted-provenance verdict or label writes none. GETs keep createGitHub's bounded retry. No POST retry was added: a 5xx POST that GitHub did apply would come back 422 on a retry and fall out of the rollback list. The hourly triage sweep retries the run instead.
  • Every triage re-reads the body, so a blocker edge a person deletes comes back while the body still names that open issue. To drop a text blocker, edit the body.
  • The native edge stays the only source admission reads. No workflow, token or permission changes: apply-verdict already writes edges with the lanes App token's issues: write grant (docs/conventions/pr-pipeline.yaml, apply-verdict declares "writes blocked-by edges").

Verification

Related

  • Not covered: an agent-ready label added by hand to an issue that intake never triaged after this change. The issue lane's admit job reads with a GITHUB_TOKEN that has only issues: read, so it cannot write edges without a permission change.
  • Not covered: issues already sitting in admission-deferred from before this change. work-unblock re-admits them on native edges alone, and its declared scope does not include edge writes. Re-triage (the hourly sweep, or a release) writes their edges.

🤖 Generated with Claude Code

…names

Admission reads only native blocked-by edges, and intake's apply-verdict
wrote edges only for the triage model's `Blocked by:` line. An issue whose
body named its blocker in text ("Blocked by: #8753") got no edge, was
admitted, and the issue lane handed it back to a person.

apply-verdict now also parses the body (edges.mjs textBlockers): a line
starting with Blocked by or Depends on, and list items under such a
heading, with #<n> and this repository's issue URLs; code, HTML comments,
quotes, cross-repository references and pull request URLs name nothing.
At most 10 candidates per issue go to the existing writeEdges, which
checks each is an open issue here, skips edges already there, and misses
and rolls back on 403, 429 or 5xx. Escalated verdicts write them too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 26, 2026 05:15
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-26T05:17:10.549271Z eddbf68 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed fb2af10eb13f810dcde6a018b2e0ff281479caa8: 0 finding(s), 0 as inline comments.

No security issues found in the incremental change (6313818..fb2af10).

The change only affects the text of one ::warning annotation in missedAnnotation (.github/scripts/intake-triage/apply-verdict.mjs). It moves the edges computation above the !ready branch. A not-ready verdict now keeps the partial-set clause when an edge was written and its rollback failed. The test file adds a matching assertion.

  • The interpolated values are issue numbers and HTTP statuses that missedEdges and undeletedEdges format. Neither the body text nor any other attacker-controlled string reaches the annotation line, so it opens no workflow-command injection path.
  • Control flow is unchanged. fail is still false on the not-ready path and the 403 handling below it is untouched. Neither file is on the trusted-path list, and neither is a trust control.
  • No manifest, workflow, token-scope, or permission changes are in this increment.

critical-findings: 0

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

claude-review: 1 inline finding(s) on eddbf687c45c43ac1d3ea6761fe374e5726eadd6; the summary is in this lane's pull request comment.

claude-lane: claude-review

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed fb2af10eb13f810dcde6a018b2e0ff281479caa8: 0 finding(s), 0 as inline comments.

Incremental review of apply-verdict.mjs and apply-verdict.test.mjs since 6313818: no findings. I read the code and the diff only. I did not run the tests.

  • Change: in missedAnnotation, the edges string is now built before the !ready branch, so the not-ready warning keeps the "written and not deleted … so work-unblock can admit the issue" clause for edges that stayed written. The closing sentence reads "does not see the blockers not written" when undeleted is non-empty and "does not see these blockers" otherwise.
  • Why it's correct: a not-ready verdict with a rolled-back edge that failed to delete leaves a partial set of native edges. The old text told the reader work-unblock saw none of them, which was wrong in that case.
  • Behavior check: missed.length === 0 still returns null first, so the ternary can't produce a misleading message when nothing was missed. The ready-path branches (::error on 403, ::warning otherwise) are untouched.
  • Tests: the new test covers both wordings with exact-string assertions. The strings match what the code builds. The test covers both branches of the new ternary.

No hold applies. The change touches no trusted path, billing or security surface.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: eddbf687c4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .github/scripts/intake-triage/edges.mjs Resolved
kyle-sexton and others added 4 commits October 26, 2026 06:31
… link targets

A missed blocked-by edge on an escalated verdict no longer fails the job or
claims a held-back status: ready; missedAnnotation takes the ready state. A
Markdown link in the issue body counts as its target alone, so a #N label on
a link to another repository names no local issue.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… warning

A reference-style Markdown link counts as its definition's target, like an
inline link. The missed-edge warning says "a verdict that is not ready",
since a flagged verdict reaches that branch as well as an escalation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

claude-review: 1 inline finding(s) on 63138180b12184df78c90d8391ff890f4097383d; the summary is in this lane's pull request comment.

claude-lane: claude-review

…ning

On a verdict that is not ready, the missed-edge warning said work-unblock
"does not see these blockers" even when an edge was written and its
rollback failed, which leaves a partial set work-unblock does read. The
not-ready warning now carries the same partial-set clause as the ready
one when an edge stayed written, and says work-unblock does not see the
blockers not written.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kyle-sexton
kyle-sexton added this pull request to the merge queue Oct 26, 2026
Merged via the queue into main with commit 9973b9c Oct 26, 2026
39 checks passed
@kyle-sexton
kyle-sexton deleted the fix/admission-text-blockers-native-edges branch October 26, 2026 12:29
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