integrate hashlogger#3647
Conversation
|
The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #3647 +/- ##
==========================================
- Coverage 58.95% 58.59% -0.36%
==========================================
Files 2261 2223 -38
Lines 186891 184007 -2884
==========================================
- Hits 110174 107824 -2350
+ Misses 66795 66446 -349
+ Partials 9922 9737 -185
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
| done := make(chan struct{}) | ||
| select { | ||
| case h.controlChan <- controlMessage{kind: ctrlColumnChange, hashType: hashType, add: add, done: done}: | ||
| select { |
There was a problem hiding this comment.
sendColumnChange returns nil when the context is cancelled or the sender context is done:
Consider returning a sentinel error or at least h.ctx.Err() / h.senderCtx.Err() so the caller knows the registration didn't actually land.
| } | ||
|
|
||
| // containsString reports whether s is present in xs. | ||
| func containsString(xs []string, s string) bool { |
There was a problem hiding this comment.
Nit: The containsString function can be replaced with slices.Contains
| } | ||
| } | ||
| } | ||
| for _, category := range desired { |
There was a problem hiding this comment.
A set-based approach would be clearer?
desiredSet := make(map[string]struct{}, len(desired))
for _, c := range desired { desiredSet[c] = struct{}{} }
Describe your changes and provide context
Wire in the hashlogger to report hashes for lots of different things