opa
opa copied to clipboard
race-detector: data race in tests
ok github.com/open-policy-agent/opa/runtime 0.546s
==================
WARNING: DATA RACE
Read at 0x00c000496030 by goroutine 47:
github.com/open-policy-agent/opa/logging/test.(*Logger).append()
/src/logging/test/test.go:94 +0x164
github.com/open-policy-agent/opa/logging/test.(*Logger).Debug()
/src/logging/test/test.go:56 +0x64
github.com/open-policy-agent/opa/download.(*Downloader).loop()
/src/download/download.go:223 +0x511
github.com/open-policy-agent/opa/download.(*Downloader).doStart.func1()
/src/download/download.go:167 +0x58
Previous write at 0x00c000496030 by goroutine 38:
github.com/open-policy-agent/opa/logging/test.(*Logger).append()
/src/logging/test/test.go:94 +0x266
github.com/open-policy-agent/opa/logging/test.(*Logger).Info()
/src/logging/test/test.go:61 +0x64
github.com/open-policy-agent/opa/plugins/bundle.(*Plugin).Stop()
/src/plugins/bundle/plugin.go:139 +0x33d
github.com/open-policy-agent/opa/plugins.(*Manager).Stop()
/src/plugins/plugins.go:626 +0x194
github.com/open-policy-agent/opa/sdk.(*OPA).Stop()
/src/sdk/opa.go:211 +0x9d
github.com/open-policy-agent/opa/sdk_test.TestPrintStatements.func2()
/src/sdk/opa_test.go:837 +0x58
runtime.deferreturn()
/usr/local/go/src/runtime/panic.go:436 +0x32
testing.tRunner()
/usr/local/go/src/testing/testing.go:1439 +0x213
testing.(*T).Run.func1()
/usr/local/go/src/testing/testing.go:1486 +0x47
Goroutine 47 (running) created at:
github.com/open-policy-agent/opa/download.(*Downloader).doStart()
/src/download/download.go:167 +0x119
github.com/open-policy-agent/opa/download.(*Downloader).Start.func1()
/src/download/download.go:158 +0x58
Goroutine 38 (running) created at:
testing.(*T).Run()
/usr/local/go/src/testing/testing.go:1486 +0x724
testing.runTests.func1()
/usr/local/go/src/testing/testing.go:1839 +0x99
testing.tRunner()
/usr/local/go/src/testing/testing.go:1439 +0x213
testing.runTests()
/usr/local/go/src/testing/testing.go:1837 +0x7e4
testing.(*M).Run()
/usr/local/go/src/testing/testing.go:1719 +0xa71
main.main()
_testmain.go:79 +0x2e4
==================
--- FAIL: TestPrintStatements (0.02s)
testing.go:1[312](https://github.com/open-policy-agent/opa/runs/6192759383?check_suite_focus=true#step:3:312): race detected during execution of test
FAIL
FAIL github.com/open-policy-agent/opa/sdk 0.495s
This isn't found every time, but it happened more than once.
This issue has been automatically marked as inactive because it has not had any activity in the last 30 days.
Lets re-open if we observe this again.