Skip to content

Data race while running tests that fixes with retry #8035

@rudrakhp

Description

@rudrakhp
==================
WARNING: DATA RACE
Read at 0x00c000d8cacb by goroutine 250:
  testing.(*common).destination()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1049 +0x96
  testing.(*outputWriter).Write()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1133 +0x9a
  go.uber.org/zap/zapcore.(*writerWrapper).Write()
      <autogenerated>:1 +0x6c
  go.uber.org/zap/zapcore.(*ioCore).Write()
      /home/runner/go/pkg/mod/go.uber.org/[email protected]/zapcore/core.go:99 +0x18d
  go.uber.org/zap/zapcore.(*CheckedEntry).Write()
      /home/runner/go/pkg/mod/go.uber.org/[email protected]/zapcore/entry.go:258 +0x1ec
  github.com/go-logr/zapr.(*zapLogger).Info()
      /home/runner/go/pkg/mod/github.com/go-logr/[email protected]/zapr.go:201 +0xce
  github.com/go-logr/logr.Logger.Info()
      /home/runner/go/pkg/mod/github.com/go-logr/[email protected]/logr.go:280 +0x107
  github.com/envoyproxy/gateway/internal/gatewayapi/runner.(*Runner).subscribeAndTranslate()
      /home/runner/work/gateway/gateway/internal/gatewayapi/runner/runner.go:401 +0x178
  github.com/envoyproxy/gateway/internal/gatewayapi/runner.(*Runner).Start.gowrap2()
      /home/runner/work/gateway/gateway/internal/gatewayapi/runner/runner.go:95 +0x44

Previous write at 0x00c000d8cacb by goroutine 204:
  testing.tRunner.func1()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1921 +0x904
  runtime.deferreturn()
      /opt/hostedtoolcache/go/1.25.6/x64/src/runtime/panic.go:589 +0x5d
  testing.(*T).Run.gowrap1()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1997 +0x44

Goroutine 250 (running) created at:
  github.com/envoyproxy/gateway/internal/gatewayapi/runner.(*Runner).Start()
      /home/runner/work/gateway/gateway/internal/gatewayapi/runner/runner.go:95 +0x5e4
  github.com/envoyproxy/gateway/internal/cmd.startRunner()
      /home/runner/work/gateway/gateway/internal/cmd/server.go:302 +0x1d1
  github.com/envoyproxy/gateway/internal/cmd.startRunners()
      /home/runner/work/gateway/gateway/internal/cmd/server.go:258 +0x1bdb
  github.com/envoyproxy/gateway/internal/cmd.testHook()
      /home/runner/work/gateway/gateway/internal/cmd/server_test.go:81 +0x3c
  github.com/envoyproxy/gateway/internal/envoygateway/config/loader.(*Loader).runHook.func1()
      /home/runner/work/gateway/gateway/internal/envoygateway/config/loader/configloader.go:129 +0x13d
  github.com/envoyproxy/gateway/internal/envoygateway/config/loader.(*Loader).runHook.gowrap1()
      /home/runner/work/gateway/gateway/internal/envoygateway/config/loader/configloader.go:135 +0x4f

Goroutine 204 (running) created at:
  testing.(*T).Run()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1997 +0x9d2
  testing.runTests.func1()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:2477 +0x85
  testing.tRunner()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:1934 +0x21c
  testing.runTests()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:2475 +0x96c
  testing.(*M).Run()
      /opt/hostedtoolcache/go/1.25.6/x64/src/testing/testing.go:2337 +0xed4
  main.main()
      _testmain.go:73 +0x164
==================

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions