The repo's proto-gen was non-idempotent and the committed *.pb.go had drifted from the
.proto sources across 5 modules (docs/known-issues/proto-generated-drift.md). Root causes:
1. scripts/sync-generated-go-pb.sh left buf's ./clawchain staging tree in place, creating a
duplicate Go package that broke 'go build ./...' and made every regen non-idempotent.
Fixed by 'rm -rf clawchain' after the copy.
2. .gitignore 'clawchain/' over-matched proto/clawchain/, so the proto SOURCES were never
tracked and drifted freely (the gitignore trap). Added a targeted negation; the root
buf-staging clawchain/ stays ignored. Versioned all 47 proto sources (27 were untracked).
Reconciliation (proto = source of truth, matched to code the chain actually uses):
- modelregistry tx.proto: re-added MsgRegisterModel.price_subscription_uclaw(16) +
subscription_period_blocks(17) (used by grpc_msg_server); removed unimplemented P4
MsgSubmitUsageAttestation/MsgDisputeInferenceJob (no keeper/codec, absent from pb.go).
- modelregistry types.proto: removed unused InferenceJob fields 18-23; kept Model 25/26.
- Deleted hand-written stopgap types/msg_renew_subscription.go (regen produces the struct);
removed module/depinject.go ProvideCustomGetSigners (regenerated type carries the signer
annotation; the custom getter panicked at startup — caught by TestNewApp).
- Regenerated governance/messaging/reputation/oracle pb.go (descriptor/accessor-level).
Verified: make proto-gen idempotent (byte-identical on re-run, no stray dir, no new
untracked), go build ./... clean, go test ./... 30 ok / 0 FAIL.