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 detected during execution of test #10340

Closed
zhouqiang-cl opened this issue May 4, 2019 · 4 comments
Closed

race detected during execution of test #10340

zhouqiang-cl opened this issue May 4, 2019 · 4 comments
Labels
component/parser type/bug The issue is confirmed as a bug.

Comments

@zhouqiang-cl
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
    Run CI for multi times

  2. What did you expect to see?
    All tests pass

  3. What did you see instead?

--- FAIL: TestT (8.95s)

testing.go:809: race detected during execution of test

FAIL

FAIL github.com/pingcap/tidb/bindinfo 9.055s

  1. What version of TiDB are you using (tidb-server -V or run select tidb_version(); on TiDB)?
    pr/10328. but this pr did not change bindinfo, I think it is master

More Info can see as below:

https://internal.pingcap.net/idc-jenkins/blue/rest/organizations/jenkins/pipelines/tidb_ghpr_unit_test/runs/2876/nodes/61/steps/267/log/?start=0

@zhouqiang-cl
Copy link
Contributor Author

==================
WARNING: DATA RACE
Write at 0x00c000a6c2a8 by goroutine 141:
  github.com/pingcap/tidb/session.(*session).ParseSQL()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/lexer.go:210 +0x153
  github.com/pingcap/tidb/session.(*session).execute()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/session.go:979 +0x2c7
  github.com/pingcap/tidb/session.(*session).Execute()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/session.go:961 +0xd4
  github.com/pingcap/tidb/bindinfo.(*BindHandle).AddBindRecord()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/handle.go:134 +0x113
  github.com/pingcap/tidb/executor.(*SQLBindExec).createSQLBind()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/executor/bind.go:85 +0x3ba
  github.com/pingcap/tidb/executor.(*SQLBindExec).Next()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/executor/bind.go:51 +0x1d7
  github.com/pingcap/tidb/executor.(*ExecStmt).handleNoDelayExecutor()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/executor/adapter.go:296 +0x1ec
  github.com/pingcap/tidb/executor.(*ExecStmt).Exec()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/executor/adapter.go:251 +0x682
  github.com/pingcap/tidb/session.runStmt()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/tidb.go:218 +0x181
  github.com/pingcap/tidb/session.(*session).executeStatement()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/session.go:934 +0x203
  github.com/pingcap/tidb/session.(*session).execute()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/session.go:1032 +0xbc2
  github.com/pingcap/tidb/session.(*session).Execute()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/session/session.go:961 +0xd4
  github.com/pingcap/tidb/util/testkit.(*TestKit).Exec()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/util/testkit/testkit.go:137 +0x100
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).TestGlobalBinding()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:151 +0x476
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).TestGlobalBinding()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:145 +0x225
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).TestGlobalBinding()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:144 +0x1ee
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).TestGlobalBinding()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:143 +0x1b7
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).cleanBindingEnv()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:101 +0x62
  github.com/pingcap/tidb/bindinfo_test.(*testSuite).TestGlobalBinding()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/bind_test.go:139 +0xdb
  runtime.call32()
      /usr/local/go/src/runtime/asm_amd64.s:519 +0x3a
  reflect.Value.Call()
      /usr/local/go/src/reflect/value.go:308 +0xc0
  github.com/pingcap/check.(*suiteRunner).forkTest.func1()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/check.go:836 +0x9fc
  github.com/pingcap/check.(*suiteRunner).forkCall.func1()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/check.go:730 +0xb7

Previous read at 0x00c000a6c2a8 by goroutine 81:
  github.com/pingcap/parser.(*Scanner).isTokenIdentifier()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/misc.go:654 +0x551
  github.com/pingcap/parser.(*Scanner).Lex()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/lexer.go:165 +0x716
  github.com/pingcap/parser.yylex1()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/parser.go:7392 +0x66
  github.com/pingcap/parser.yyParse()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/parser.go:7447 +0x8f5a9
  github.com/pingcap/parser.(*Parser).Parse()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/pkg/mod/github.com/pingcap/[email protected]/yy_parser.go:130 +0x3a0
  github.com/pingcap/tidb/bindinfo.(*BindHandle).newBindMeta()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/handle.go:297 +0x194
  github.com/pingcap/tidb/bindinfo.(*BindHandle).Update()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/bindinfo/handle.go:112 +0x238
  github.com/pingcap/tidb/domain.(*Domain).loadBindInfoLoop.func1()
      /home/jenkins/workspace/tidb_ghpr_unit_test/go/src/github.com/pingcap/tidb/domain/domain.go:812 +0x1f2

@shenli shenli added type/bug The issue is confirmed as a bug. component/parser labels May 4, 2019
@shenli
Copy link
Member

shenli commented May 4, 2019

@tiancaiamao @lysu PTAL

@lysu
Copy link
Contributor

lysu commented May 5, 2019

@zhouqiang-cl this question is fixed by #10321

just merge lastest master will solve it.

@lysu lysu closed this as completed May 5, 2019
@zhouqiang-cl
Copy link
Contributor Author

just reopen for test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/parser type/bug The issue is confirmed as a bug.
Projects
None yet
Development

No branches or pull requests

3 participants