Comment 1 for bug 1640192

Revision history for this message
Curtis Hovey (sinzui) wrote : Re: Race in github.com/juju/juju/cmd/testing.RunCommand

==================
WARNING: DATA RACE
Read by goroutine 71:
  github.com/juju/juju/provider/dummy.(*environProvider).CredentialSchemas()
      <autogenerated>:3 +0xa2
  github.com/juju/juju/cmd/juju/commands.(*bootstrapCommand).cloud()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap.go:645 +0xc23
  github.com/juju/juju/cmd/juju/commands.(*bootstrapCommand).Run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap.go:336 +0x252
  github.com/juju/juju/cmd/juju/commands.(*bootstrapCommandWrapper).Run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap_test.go:137 +0x95
  github.com/juju/juju/cmd/modelcmd.(*modelCommandWrapper).Run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/modelcmd/modelcommand.go:282 +0x6e
  github.com/juju/juju/cmd/modelcmd.(*baseCommandWrapper).Run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/modelcmd/base.go:325 +0x10b
  github.com/juju/juju/cmd/testing.RunCommand.func1()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/testing/testing.go:86 +0x12c

Previous write by goroutine 169:
  sync/atomic.AddInt32()
      /usr/lib/go-1.6/src/runtime/race_amd64.s:255 +0xb
  sync.(*Mutex).Unlock()
      /usr/lib/go-1.6/src/sync/mutex.go:107 +0x55
  github.com/juju/juju/provider/dummy.Listen()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/provider/dummy/environs.go:467 +0x1ee
  github.com/juju/juju/cmd/testing.RunCommand.func1.1()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/testing/testing.go:74 +0x2d
  github.com/juju/juju/cmd/testing.RunCommand.func1()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/testing/testing.go:87 +0x17c

Goroutine 71 (running) created at:
  github.com/juju/juju/cmd/testing.RunCommand()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/testing/testing.go:87 +0x21f
  github.com/juju/juju/cmd/juju/commands.(*BootstrapSuite).run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap_test.go:228 +0xb54
  github.com/juju/juju/cmd/juju/commands.(*BootstrapSuite).TestRunTests()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap_test.go:155 +0x2e0
  runtime.call32()
      /usr/lib/go-1.6/src/runtime/asm_amd64.s:472 +0x3d
  reflect.Value.Call()
      /usr/lib/go-1.6/src/reflect/value.go:303 +0xcd
  gopkg.in/check%2ev1.(*suiteRunner).forkTest.func1()
      /home/ubuntu/juju-core_2.0.2/src/gopkg.in/check.v1/check.go:772 +0x5d1
  gopkg.in/check%2ev1.(*suiteRunner).forkCall.func1()
      /home/ubuntu/juju-core_2.0.2/src/gopkg.in/check.v1/check.go:666 +0x80

Goroutine 169 (finished) created at:
  github.com/juju/juju/cmd/testing.RunCommand()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/testing/testing.go:87 +0x21f
  github.com/juju/juju/cmd/juju/commands.(*BootstrapSuite).run()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap_test.go:228 +0xb54
  github.com/juju/juju/cmd/juju/commands.(*BootstrapSuite).TestRunTests()
      /home/ubuntu/juju-core_2.0.2/src/github.com/juju/juju/cmd/juju/commands/bootstrap_test.go:155 +0x2e0
  runtime.call32()
      /usr/lib/go-1.6/src/runtime/asm_amd64.s:472 +0x3d
  reflect.Value.Call()
      /usr/lib/go-1.6/src/reflect/value.go:303 +0xcd
  gopkg.in/check%2ev1.(*suiteRunner).forkTest.func1()
      /home/ubuntu/juju-core_2.0.2/src/gopkg.in/check.v1/check.go:772 +0x5d1
  gopkg.in/check%2ev1.(*suiteRunner).forkCall.func1()
      /home/ubuntu/juju-core_2.0.2/src/gopkg.in/check.v1/check.go:666 +0x80
==================