chrismdp / issue-to-pull-request

An issue becomes a pull request

Public ·
Version 23 of 23
  1. #23 · chrismdp · · 0.8ShowingLatest
  2. #22 · chrismdp · · 0.6
  3. #21 · chrismdp · · 0.6
  4. #20 · chrismdp · · 0.6
  5. #19 · chrismdp · · 0.6
  6. #18 · chrismdp · · 0.6
  7. #17 · chrismdp · · 0.6
  8. #16 · chrismdp · · 0.4
  9. #15 · chrismdp · · 0.4
  10. #14 · chrismdp · · 0.4
  11. #13 · chrismdp · · 0.4
  12. #12 · chrismdp · · 0.4
  13. #11 · chrismdp · · 0.4
  14. #10 · chrismdp · · 0.4
  15. #9 · chrismdp · · 0.4
  16. #8 · chrismdp · · 0.3
  17. #7 · chrismdp · · 0.3
  18. #6 · chrismdp · · 0.3
  19. #5 · chrismdp · · 0.3
  20. #4 · chrismdp · · 0.3
  21. #3 · chrismdp · · 0.3
  22. #2 · chrismdp · · 0.3
  23. #1 · chrismdp · · 0.3
Fork
publicanyone who reads the repositorythe label[build]the issue[yes]the issue's numberthe issue's labels and last edit[labelled, unedited since][added without write access]the issue's text and commentsthe approved text and itspeople's commentsCI's latest pull_request run onthe branchwhy the last try failedthe change[touches .github/ or Claude'sfiles][touches neither][within limits]each push, as made[pushed]the description[within limits]each pull request, as opened[the draft failed][the push or the pull requestfailed]TriggerThe build label is added to anissueA stranger's comment starts nothing: the build label counts only when GitHub's record says its last adder has write access, by their permission, or is the app's bot, since someone with triage can add a label too. The start job checks, saying so on the issue if not, and the draft checks again. The draft step's token can only read, so it can't push (awml #26)Started by chrismdp/retry-a-buildTriggerretry-a-build starts the buildagain for an issueA retry's dispatch carries the issue's number and nothing the build trusts. The build checks the label and the issue's last edit itself, and reads CI's failed log from GitHub (#160 rule 2)Connection · untrustedThe issue and its comments,which anyone can open orwriteCode · sortSort by rule: is the label build?Person · reviewThe build label is the yes ofsomeone with write access tothe issue as it reads thenCode · sortSort by GitHub's record,passing on only the issue'snumber: was the build labellast added by someone withwrite access, by theirpermission, or by the app'sbot, and, on a retry's dispatch,does the issue still carry it,and is its lastEditedAt, fromGraphQL, older than thelabel's last labelled event?Used by chrismdp/ci-a-commit, chrismdp/fix-review-findings, chrismdp/land-a-pull-request, chrismdp/rebase-conflicting-pull-requests, chrismdp/retry-a-build and chrismdp/review-a-pull-requestConnectionThe repository, through itsown Actions tokenUsed by chrismdp/fix-review-findings, chrismdp/land-a-pull-request and chrismdp/rebase-conflicting-pull-requestsConnectionThe repository, through itsown GitHub AppGitHub starts other workflows from the app's pull request, but not from the Actions token's, so CI runs when the pull request opensCode · doPost a new comment on theissue that the build hasstarted, linking the runDecided in #160's follow-up: one new comment when the build starts, linking the run. It's never edited or parsed. The pull request links to the issue by Closes #n (#160 rule 5)Outside actionComment on the issueAllowCode · doSay in a new comment on theissue, from fixed text, that thebuild label must be added bysomeone with write access,linking the runA stranger's comment starts nothing: the build label counts only when GitHub's record says its last adder has write access, by their permission, or is the app's bot, since someone with triage can add a label too. The start job checks, saying so on the issue if not, and the draft checks again. The draft step's token can only read, so it can't push (awml #26)Code · sortKeep only the issue's text,unedited since the label waslast added, and the commentsof people with admin, maintainor write permission on therepository, by each author'scollaborator permissionAnyone can open an issue or comment. The issue reaches Claude only as the text a person with write access approved by adding the label, and only the comments of people who can write to the repository are passed on, never those of a member who can only read The label approves the issue as the maintainer saw it, so the issue and its people's comments are read as GitHub renders them, bodyHTML from GraphQL, never the Markdown behind them: an HTML comment or other text the page hides never reaches Claude (#150)2Code · bring-inBring in the approved text andcomments, and the failedtests' log of CI's latestpull_request run on the issue'sbranch, if it has oneDataThe issue's text, uneditedsince the label was last added,and its people's commentsDecided in #160's follow-up: a try drafts from the issue's text as it reads now, only if it hasn't been edited since the build label was last added, by comparing the issue's last edit with the label event. An edited issue waits for a person to add the label again (awml #120)Data · untrustedWhy the last try failed: thefailed tests' log of CI's latestrun on the branchCI's failed log is the output of the branch's code, which a fix commit drafted from review findings may have changed, so the next draft reads it as untrusted. Nothing in the run stops it, so the app's push and pull request go under standing approvalsDataThe spec, guide, code,AGENTS.md and REVIEW.md,from mainAI · draftWrite the change test first,then redraw the examples italters and picture, before andafter, those that look differentOnly a change to what a drawing or a page shows is pictured, and a picture that looks the same before and after is left out. A moving image only for something that movesDataThe change, as a patch, withits pictures, Claude's note andits description for the pullrequestCode · sortSort by git alone: does thedraft touch .github/ or ClaudeCode's own files?Decided in #160's follow-up: the build works as the fixer does. A draft touching .github/ or Claude Code's own settings, .claude/, .mcp.json or a CLAUDE.md, isn't pushed: it's offered in a new comment, and the build stops without a retry, since nothing is pushed for CI to fail. No session loads settings or servers from the treeCode · doOffer the draft in a newcomment on the issue fromfixed text: gh run download<run> -n change, the git applycommand, and that theartifact lasts 30 days, quotingnone of itOutside actionComment on the issue withthe commandsAllowCode · doPush the branch and itspictures as the appDecided in #160's follow-up: the build runs no checks of its own. It always pushes and opens the pull request, CI judges it, and retry-a-build wakes when CI's tests fail (#160 rule 4)Person · standing approvalThe maintainer's standingapproval: the app's pushes tothe issue's own branch only,up to three builds an issue,accepted by the maintainer in#160, under rule 4Outside actionPush the issue's branch andits picturesAskCode · doOpen a pull request that saysCloses #n, or give the oneopen from the branch alreadythis try's title and descriptionThe description is Claude's note, escaped, then what changed, the decisions the issue didn't settle, the pictures, and Closes #n. No record line and no digests: nothing reads the description back (#160) The branch is reused, so a new try's push updates the open pull request's commits, and the build gives it the new try's title and description before the push, which starts CI, so the reviews judge the new commit against what it says and a squash keeps the new title. No earlier one needs closing (#160's follow-up)2Person · standing approvalThe maintainer's standingapproval: one open pullrequest an issue, from its ownbranch, accepted by themaintainer in #160, under rule4Outside actionOpen the pull requestAskCode · doSay in a new comment on theissue, from fixed text, that thebuild stopped before itschange reached a pullrequest, linking the runA draft or open job that fails leaves no pull request, so CI never runs and retry-a-build never wakes. A last job says so on the issue, so the build never stops unseenOutside actionComment on the issueAllowSurfaceThe repository's branches andpull requests, where eachpush is listed with its commit