Skip to content

Commit 12e4162

Browse files
Document that errors in goro.Group.Go functions are ignored (#3734)
1 parent fb3f2f9 commit 12e4162

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/goro/group.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,13 @@ type Group struct {
4949
// If the supplied func does not abide by `ctx.Done()` of the provided
5050
// `context.Context` then `Wait()` on this `Group` will hang until all functions
5151
// exit on their own (possibly never).
52+
// NOTE: Errors returned by the supplied function are ignored.
5253
func (g *Group) Go(f func(ctx context.Context) error) {
5354
g.initOnce.Do(g.init)
5455
g.wg.Add(1)
5556
go func() {
5657
defer g.wg.Done()
57-
f(g.ctx)
58+
_ = f(g.ctx)
5859
}()
5960
}
6061

0 commit comments

Comments
 (0)