We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent74f2771 commit365231bCopy full SHA for 365231b
cli/exp_scaletest.go
@@ -14,7 +14,6 @@ import (
14
"strconv"
15
"strings"
16
"sync"
17
-"syscall"
18
"time"
19
20
"github.com/google/uuid"
@@ -245,14 +244,8 @@ func (o *scaleTestOutput) write(res harness.Results, stdout io.Writer) error {
245
244
246
// Sync the file to disk if it's a file.
247
ifs,ok:=w.(interface{Sync()error });ok {
248
-err:=s.Sync()
249
-// On Linux, EINVAL is returned when calling fsync on /dev/stdout. We
250
-// can safely ignore this error.
251
-// On macOS, ENOTTY is returned when calling sync on /dev/stdout. We
252
253
-iferr!=nil&&!xerrors.Is(err,syscall.EINVAL)&&!xerrors.Is(err,syscall.ENOTTY) {
254
-returnxerrors.Errorf("flush output file: %w",err)
255
-}
+// Best effort. If we get an error from syncing, just ignore it.
+_=s.Sync()
256
}
257
258
ifc!=nil {