clients/go: bootstrap the Go SDK module - #512
Open
bkeroack wants to merge 1 commit into
Open
Conversation
Stands up `clients/go` as an independently versioned Go module inside this repo (module path github.com/epochbtc/satd/clients/go, released as `clients/go/vX.Y.Z` tags — no collision with the node's own tags because there is no go.mod at the repo root). Why in-repo rather than a separate SDK repository: the Go E2E suite drives the same freshly built satd binary the Rust E2E suite does and gates every PR, proto changes and both SDKs land atomically, and nothing rots between releases in a repo nobody watches. The SDK will not be dogfooded directly, so CI is the only thing standing between a green badge and a rotted client. Codegen is buf with managed mode: `go_package` is injected at generation time, so the shared satd.events.v1 proto needs no Go-specific edit and the Rust prost build is untouched. The bindings are committed (`go get` must work with no protoc, no buf, no Rust toolchain) and CI re-runs `gen.sh` and fails on a diff, so they cannot drift from the proto. The generators and linters live in a sibling `tools` module. Declaring them in the SDK's own go.mod would put the whole buf tree in every consumer's module graph and could force MVS version bumps on applications that only import the client; this way the published graph stays exactly gRPC + protobuf. CI wiring: - Tests job: setup-go + `go test ./clients/go/...`. - Lint job: gofmt, go vet, staticcheck (SA + unused classes; style classes stay off), errcheck, and the codegen drift check. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GJqZbJtTUo7K7G9wJcrvHv
This was referenced Aug 5, 2026
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.
First of an 8-PR stack implementing the official Go SDK for satd's streaming events API, per
SATD_GO_SDK_PLAN.md. Merge bottom-up in stack order.What this lands
clients/goas an independently versioned Go module inside this repo — module pathgithub.com/epochbtc/satd/clients/go, released asclients/go/vX.Y.Ztags. No collision with the node'sv0.5.0tags because there is nogo.modat the repo root; consumers pull a zip of the module subtree only, not the Rust tree.go.mod—godirective at (latest stable − 1) for Go's two-release support window; dependencies are gRPC + protobuf only.tools/go.mod— pinnedbuf,protoc-gen-go,protoc-gen-go-grpc,staticcheck,errcheck, in their own module so the whole buf tree never enters a consumer's graph or forces an MVS bump on an application that just imports the client.buf.gen.yaml+gen.sh— buf with managed mode injectsgo_packageat generation time, so the sharedsatd-events-proto/proto/satd/events/v1/events.protoneeds no Go-specific edit and the Rust prost build is untouched. buf brings its own compiler, so nothing needs a systemprotoc.eventspb/— the generated bindings, committed:go getmust work with no protoc, no buf, and no Rust toolchain.lint.sh,staticcheck.conf,doc.go,README.md.CI
actions/setup-go(version fromgo.mod, module cache on) +go test ./clients/go/....go vet, staticcheck (SA + unused classes; style classes off), errcheck, and the codegen drift check (gen.shthengit diff --exit-code clients/go/eventspb) — so a proto change that lands without regenerated bindings fails the PR that made it.The SDK will not be dogfooded directly, so CI is the only thing between a green badge and a rotted client. Every layer gates PRs from its first landing; the E2E and differential-parity layers arrive with the surfaces they cover in later PRs of the stack.
🤖 Generated with Claude Code
https://claude.ai/code/session_01GJqZbJtTUo7K7G9wJcrvHv