# rpc error: code = Internal desc = grpc: error while marshaling: proto: field tags don't match

- **ID:** `go/grpc-internal-error-proto-mismatch`
- **Domain:** go
- **Category:** data_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The protobuf definition used by client and server are out of sync (e.g., different field numbers or types), causing marshaling/unmarshaling failures.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 1.22 | active | — | — |
| 1.23 | active | — | — |

## Workarounds

1. **Regenerate protobuf stubs from the same .proto file for both client and server.** (95% success)
   ```
   protoc --go_out=. --go-grpc_out=. *.proto
# ensure same .proto version is used everywhere
   ```
2. **Use buf tool to enforce proto compatibility checks.** (90% success)
   ```
   buf breaking --against '.git#branch=main'
   ```

## Dead Ends

- **Clearing the client cache and retrying.** — The proto definitions are still mismatched; cache is irrelevant. (95% fail)
- **Manually editing the generated .pb.go files.** — Files are auto-generated; manual edits break regeneration. (90% fail)
