Closed
Description
WARNING: DATA RACE
Read at 0x00c000036110 by goroutine 55:
go/pkg/mod/github.com/bitfield/[email protected]/script.go:388 +0x1e9
github.com/bitfield/script.(*Pipe).Filter.func1()
go/pkg/mod/github.com/bitfield/[email protected]/script.go:484 +0xc7
Previous write at 0x00c000036110 by goroutine 49:
github.com/bitfield/script.(*Pipe).WithStderr()
go/pkg/mod/github.com/bitfield/[email protected]/script.go:887 +0x798
There seems to be a data race with stdErr when executing the following piece of code in parallel (test with errgroup).
stdOut := new(bytes.Buffer)
stdErr := new(bytes.Buffer)
if _, err := script.Exec(cmdLine).WithStdout(stdOut).WithStderr(stdErr).Stdout(); err != nil {
return nil, err
}
Metadata
Metadata
Assignees
Labels
No labels