Skip to content

I7b (audit-I25): nodeId exporter alias across --json catalogs#38

Merged
espadonne merged 5 commits into
trunkfrom
i7b/node-id-alias
May 24, 2026
Merged

I7b (audit-I25): nodeId exporter alias across --json catalogs#38
espadonne merged 5 commits into
trunkfrom
i7b/node-id-alias

Conversation

@espadonne
Copy link
Copy Markdown
Contributor

Summary

Closes audit-I25 (the CLI side of I7b). Every `--json` exporter that emits the sequential `id` field now also emits `nodeId` projected from the server's opaque `node_id`. Scripts should prefer `nodeId` going forward; `id` stays for one release cycle before the v0.2.0 strip.

Paired with shithub#395 (I7b server — `author_id` stripped from issue/PR/comment/review responses).

What landed

  • `internal/keys.SSHKey` — new `NodeID` field (the server-side I7a expansion landed `node_id` on the user-facing SSH-key surface).
  • `pkg/cmd/sshkey/list` exporter — `nodeId` field added to the catalog + projection.
  • `pkg/cmd/pr/list` exporter — same.
  • `pkg/cmd/issue/list` exporter — same.
  • `pkg/cmd/repo/view` exporter — same.

Behavior

  • `shithub ssh-key list --json id,nodeId` returns both fields. `id` is the sequential integer; `nodeId` is the opaque base64-encoded `gid://shithub/SSHKey/{id}` from the server.
  • Pre-deploy of I7a/I7b server (the field is server-emitted), `nodeId` is an empty string — graceful degradation rather than a hard fail.

Out of scope

  • Sequential `id` field strip — v0.2.0 work. This bundle only adds the alias.
  • README migration note — small follow-up doc PR.

Test plan

  • Build + vet clean across all packages
  • Targeted tests green for sshkey/list, pr/list, issue/list, repo/view
  • No new lint regressions on my files
  • Dogfood post-merge: `shithub ssh-key list --json id,nodeId` returns both fields populated

🤖 Generated with Claude Code

@espadonne espadonne merged commit 08839e3 into trunk May 24, 2026
3 checks passed
@espadonne espadonne deleted the i7b/node-id-alias branch May 24, 2026 05:24
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