Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

race test failed #735

Closed
Smityz opened this issue Mar 9, 2023 · 0 comments · Fixed by #736
Closed

race test failed #735

Smityz opened this issue Mar 9, 2023 · 0 comments · Fixed by #736

Comments

@Smityz
Copy link
Contributor

Smityz commented Mar 9, 2023

go test -race ./...

race test may failed

error info:

WARNING: DATA RACE
Read at 0x00c000406610 by goroutine 410:
  github.com/tikv/client-go/v2/internal/locate.(*Store).requestLiveness()
      /Users/yanzhao.tang/Code/client-go/internal/locate/region_cache.go:2594 +0x1bb
  github.com/tikv/client-go/v2/internal/locate.(*Store).checkUntilHealth()
      /Users/yanzhao.tang/Code/client-go/internal/locate/region_cache.go:2571 +0x59a
  github.com/tikv/client-go/v2/internal/locate.(*Store).startHealthCheckLoopIfNeeded.func1()
      /Users/yanzhao.tang/Code/client-go/internal/locate/region_cache.go:2542 +0x47

Previous write at 0x00c000406610 by goroutine 398:
  github.com/tikv/client-go/v2/internal/locate.(*testRegionRequestToThreeStoresSuite).TestReplicaSelector()
      /Users/yanzhao.tang/Code/client-go/internal/locate/region_request3_test.go:498 +0x396b
  runtime.call16()
      /usr/local/Cellar/go/1.19.5/libexec/src/runtime/asm_amd64.s:724 +0x48
  reflect.Value.Call()
      /usr/local/Cellar/go/1.19.5/libexec/src/reflect/value.go:368 +0xc7
  github.com/stretchr/testify/suite.Run.func1()
      /Users/yanzhao.tang/go/pkg/mod/github.com/stretchr/[email protected]/suite/suite.go:175 +0x6e6
  testing.tRunner()
      /usr/local/Cellar/go/1.19.5/libexec/src/testing/testing.go:1446 +0x216
  testing.(*T).Run.func1()
      /usr/local/Cellar/go/1.19.5/libexec/src/testing/testing.go:1493 +0x47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant