atharvalade opened a new pull request, #3164: URL: https://github.com/apache/iggy/pull/3164
## Which issue does this PR close? Closes #3131 ## Rationale `DeserializeClient` (Go) and `MapClient` (C#) return duplicate/zero-valued consumer groups due to incorrect slice pre-allocation and a redundant outer loop. ## What changed? In Go, `make([]ConsumerGroupInfo, Count)` pre-allocated `Count` zero-valued entries, then `append` added real data after them—doubling the slice. The outer `for position < length` loop could also re-read groups if trailing bytes existed. Fixed both SDKs by using `make([], 0, Count)` (Go) / `new List<>(Count)` (C#) for correct capacity-only allocation, and replaced the outer `while`/`for` loop with a single bounded `for i < Count` pass. ## Local Execution - Passed - Pre-commit hooks ran ## AI Usage 1. Opus 4.6 2. Minimal AI used 3. Verified via `go build`, `go vet`, `go test`, `dotnet build`, `dotnet test` (100/100 passed), and CI lint scripts 4. Yes, all code can be explained -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
