Skip to content

fix(coord): coord.sh done works when no comment links a PR - #119

Merged
xcjs merged 1 commit into
mainfrom
fix/coord-done-without-pr
Oct 4, 2026
Merged

xcjs merged 1 commit into
mainfrom
fix/coord-done-without-pr

Conversation

@m-vawter

@m-vawter m-vawter commented Oct 3, 2026

Copy link
Copy Markdown
Collaborator

coord.sh done N without --pr looks for a pr: …/pull/N comment on the issue. When there isn't one, as with a settings-only or decision issue, last is null, and capture() on a null body is a jq error:

jq: error: null (null) cannot be matched, as it is not a string

So done exited before posting DONE. This guards with select(. != null). coord.ps1 already checks for a match first. The merged-PR check is unchanged when a PR URL is found.

Verification

  • With this branch, coord.sh done 104 (the e2e gate, a settings-only issue) posted DONE and closed 0.1 e2e gate: require the CI checks on main #104. On main, the same call fails with the error above.
  • The jq filter on four inputs: no PR comment → empty; no comments → empty; one pr: comment → its URL; two → the last one.
  • bash -n is clean.

🤖 Generated with Claude Code

Without --pr, done looks for a "pr: .../pull/N" comment. When none exists
(a settings-only or decision issue), `last` is null, and capture() on a
null body is a jq error, so done exited before posting DONE. Guard with
select(. != null). coord.ps1 already checks for a match first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@m-vawter m-vawter mentioned this pull request Oct 3, 2026

@xcjs xcjs left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Verified: guard matches coord.ps1's match-first pattern; author live-tested done 104 on this branch. Safe one-liner. Approved.

@xcjs
xcjs merged commit 21f7860 into main Oct 4, 2026
4 checks passed
@xcjs
xcjs deleted the fix/coord-done-without-pr branch October 4, 2026 00:37
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.

0.1 e2e gate: require the CI checks on main

2 participants