We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I ran the vim-bootstrap-server and hit a data race requesting several configurations at the same time.
vim-bootstrap-server
#!/usr/bin/env bash theme="$1" while true; do colorscheme=$(curl -sS -d "theme=$theme" http://localhost:3000/generate.vim | grep colorscheme) if [ "$colorscheme" == "colorscheme $theme" ]; then echo "Ok: $colorscheme" else echo "Bad: $colorscheme" exit 1 fi done
Try to run the above script at the same time and you will have a data race.
# Run this at same time $ ./run.sh wombat $ ./run.sh molokai
WARNING: DATA RACE Read at 0x00c000237118 by goroutine 87: runtime.slicecopy() /usr/lib/go/src/runtime/slice.go:247 +0x0 bytes.(*Buffer).grow() /usr/lib/go/src/bytes/buffer.go:143 +0x269 bytes.(*Buffer).Write() /usr/lib/go/src/bytes/buffer.go:172 +0x184 text/template.(*state).walk() /usr/lib/go/src/text/template/exec.go:271 +0x747 text/template.(*state).walk() /usr/lib/go/src/text/template/exec.go:264 +0x1a4 text/template.(*Template).execute() /usr/lib/go/src/text/template/exec.go:220 +0x2fb text/template.(*Template).Execute() /usr/lib/go/src/text/template/exec.go:203 +0xaa4 github.com/editor-bootstrap/vim-bootstrap/generate.Generate() /home/ezra/dev/thirdparty/vim-bootstrap/generate/generate.go:130 +0xa66 github.com/editor-bootstrap/vim-bootstrap/web.HandleGenerate() /home/ezra/dev/thirdparty/vim-bootstrap/web/web.go:49 +0x484 net/http.HandlerFunc.ServeHTTP() /usr/lib/go/src/net/http/server.go:2069 +0x51 github.com/gorilla/mux.(*Router).ServeHTTP() /home/ezra/go/pkg/mod/github.com/gorilla/mux@v1.8.0/mux.go:210 +0x132 github.com/urfave/negroni.Wrap.func1() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:46 +0x68 github.com/urfave/negroni.HandlerFunc.ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:29 +0x5b github.com/urfave/negroni.middleware.ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:38 +0x116 github.com/urfave/negroni.middleware.ServeHTTP-fm() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:37 +0x7e github.com/urfave/negroni.(*Static).ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/static.go:34 +0x99b github.com/urfave/negroni.middleware.ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:38 +0x116 github.com/urfave/negroni.middleware.ServeHTTP-fm() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:37 +0x7e github.com/urfave/negroni.(*Logger).ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/logger.go:62 +0x9c github.com/urfave/negroni.middleware.ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:38 +0x116 github.com/urfave/negroni.middleware.ServeHTTP-fm() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:37 +0x7e github.com/urfave/negroni.(*Recovery).ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/recovery.go:193 +0xd6 github.com/urfave/negroni.middleware.ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:38 +0x116 github.com/urfave/negroni.(*Negroni).ServeHTTP() /home/ezra/go/pkg/mod/github.com/urfave/negroni@v1.0.0/negroni.go:96 +0x186 net/http.serverHandler.ServeHTTP() /usr/lib/go/src/net/http/server.go:2887 +0xca net/http.(*conn).serve() /usr/lib/go/src/net/http/server.go:1952 +0x87d
The text was updated successfully, but these errors were encountered:
cassiobotaro
Successfully merging a pull request may close this issue.
I ran the
vim-bootstrap-server
and hit a data race requesting several configurations at the same time.Try to run the above script at the same time and you will have a data race.
# Run this at same time $ ./run.sh wombat $ ./run.sh molokai
Data race output
The text was updated successfully, but these errors were encountered: