data race in searchSymbolsInRepo
Created by: ijt
I got this log output while doing a search for func main
against an instance started by dev/launch
, searching in some local repos served via fakehub:
13:25:54 frontend | WARNING: DATA RACE
13:25:54 frontend | Read at 0x00c000940320 by goroutine 104:
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.searchSymbolsInRepo()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_symbols.go:157 +0x303
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.searchSymbols.func2()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_symbols.go:81 +0x1a2
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/internal/goroutine.Go.func1()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/internal/goroutine/goroutine.go:24 +0x50
13:25:54 frontend | Previous write at 0x00c000940320 by goroutine 108:
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.zoektIndexedRepos()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/textsearch.go:863 +0x634
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.searchFilesInRepos()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/textsearch.go:899 +0x2316
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).doResults.func5()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_results.go:922 +0x12e
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/internal/goroutine.Go.func1()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/internal/goroutine/goroutine.go:24 +0x50
13:25:54 frontend | Goroutine 104 (running) created at:
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/internal/goroutine.Go()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/internal/goroutine/goroutine.go:17 +0x4c
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.searchSymbols()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_symbols.go:79 +0xc26
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).Suggestions.func3()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_suggestions.go:119 +0x302
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).Suggestions.func5()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_suggestions.go:204 +0xec
13:25:54 frontend | Goroutine 108 (running) created at:
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/internal/goroutine.Go()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/internal/goroutine/goroutine.go:17 +0x4c
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).doResults()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_results.go:919 +0x1bdc
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).Suggestions.func4()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_suggestions.go:169 +0x235
13:25:54 frontend | github.com/sourcegraph/sourcegraph/cmd/frontend/graphqlbackend.(*searchResolver).Suggestions.func5()
13:25:54 frontend | /Users/issactrotts/sg/sourcegraph/cmd/frontend/graphqlbackend/search_suggestions.go:204 +0xec