Repository navigation
feat(issues): write to GitHub issues, each write off until the owner turns it on - #59
Merged
Merged
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
leemour
force-pushed
the
feat/issue-writes
branch
from
December 6, 2026 10:57
b477edc to
c0f48a1
Compare
…turns it on The owner's ruling NEED-3013. cli-core's `issues create`, `issues update` and `issues comments create` now reach GitHub through a GitHub writer: title, text, open or closed (completed, not planned, duplicate), labels and the one assignee, and comments. - Each key (issues.create, issues.update, issues.comments.create) is deny by default; issues.assign-others keeps cli-core's deny. Only the exact key lifts it. `ask` asks at a terminal, needs --yes elsewhere, and goes ahead over MCP (WC-MCP-7). - Writes go through serviceApiWriter over three allowlisted operations kept by the spec model; the api group stays read-only. The command key is checked again on the send path, and the owner is asked once. - A write follows no redirect: an issue transferred since the sync is refused, never changed in a repository the owner did not choose (security review; cli-core#3798 for the shared fix). - Labels and logins come from the copy; only chosen repositories are written. Labels GitHub drops for a sign-in without push access are reported; a read-only token's 403 names Issues: Read and write. - The strict fake takes the writes and refuses as GitHub does (403, 301, silent drops); the live check proves a write is refused by default. - cli-testing 0.7.5: its deny contract accepts a key denied by default. Plan: cli-private plans/2026-12-01-github-cli/writes.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… terminal Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
leemour
force-pushed
the
feat/issue-writes
branch
from
December 6, 2026 11:19
f400b17 to
7bd6098
Compare
leemour
added a commit
that referenced
this pull request
Dec 6, 2026
0.2.4's registry publish failed with 422: the description had grown to 113 characters in #59. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
leemour
added a commit
that referenced
this pull request
Dec 6, 2026
0.2.4's registry publish failed with 422: the description had grown to 113 characters in #59. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The owner's ruling NEED-3013: gthb writes to issues, off by default. Plan: cli-private
plans/2026-12-01-github-cli/writes.md(cli-private #659). Slice 1 of 3; pull requests and Projects v2 are planned only.What
issues create,issues update(title, text,--status Closed/"Closed as not planned"/"Closed as duplicate"/Open,--label,--add-label,--remove-label,--assignee) andissues comments createnow reach GitHub throughsrc/github/writer.ts.issues.create,issues.update,issues.comments.createaredeny(WRITE_DEFAULTS,src/config.ts);issues.assign-otherskeeps cli-core'sdeny. Only the exact key lifts it (issues: allowdoes not).askasks at a terminal and needs--yeselsewhere; over MCPaskgoes ahead (WC-MCP-7), documented in README and skill.serviceApiWriterover three allowlisted operations (WRITES,scripts/spec-model.ts); theapigroup keepseffects: ["read"]and offers no raw write. The command key is checked again on the send path; the owner is asked once.sent: true); a read-only token's 403 says it needs Issues: Read and write.--priority,--project,--due,--parent, moving an issue and creating a closed one are refused before any call (cli-core gap G-W1).denyby default.Testing
src/writes.test.ts(18 tests over the strict fake): refused at defaults (with--yes,--dry-run,GTHB_READ_ONLY, a broaderissues: allow,askwithout a terminal), one question withapi: asktoo, text sent as one JSON value, create/close/reopen/labels/assignee, fresh labels, silent drops, 403, 301 not followed (mutation-checked), no rawapi issues create.src/mcp.test.ts: an agent'sgthb_writeis refused at defaults with no request.leemour,leemour/brazecli#49:issues comments create … --yes, its--dry-run, andissues create … --yesall exit 5permission_error(deny from the default), no request. The profile's token is read-only, so a real write is left to the owner.🤖 Generated with Claude Code
Conformance
0.2.3 7bd609844437dd11252442b6084020165ce14257 2026-12-06 scripts/live.sh v2:1cb00bcf495a813b51e8cb87ec0776625f16d02bf4b91ccc3d124ac2f1f8b0900.2.2 c0f48a14c1a4798cb21b21ead5165c38395dd046 2026-12-06 scripts/live.sh v2:ba81ab8056289e4f7ccf52fe4e91ac63e110043cf5b1bc5969575e95fdb96b670.2.2 170697794abbdc671b14d27b8f6b623ace207e78 2026-12-06 scripts/live.sh v2:7316351187a70a3fbc25108962cee784a05cea0e125367a77f51682680fe33f1