RuntimeError: Can't clone gitaly after runing git pull
Summary
rspec
fails to execute specs following a git pull
with the aforementioned error
Steps to reproduce
- rm -rf tmp/tests/gitaly
- echo v0.10.0 > GITALY_SERVER_VERSION
- rspec ...
- echo v0.11.0 > GITALY_SERVER_VERSION
- rspec ...
What is the current bug behavior?
Second rspec run fails
What is the expected correct behavior?
Specs should run
Relevant logs and/or screenshots
Gitlab::TaskFailedError: rm -rf /home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/tmp/tests/gitaly/_build
mkdir -p /home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/tmp/tests/gitaly/_build/src/gitlab.com/gitlab-org/gitaly
tar -cf - --exclude _build --exclude .git . | (cd /home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/tmp/tests/gitaly/_build/src/gitlab.com/gitlab-org/gitaly && tar -xf -)
touch /home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/tmp/tests/gitaly/_build
tar: ./gitaly.socket: socket ignored
make: *** No rule to make target '_build/src/gitlab.com/gitlab-org/gitaly/vendor/golang.org/x/net/http2/fixed_buffer.go', needed by 'build'. Stop.
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/lib/tasks/gitlab/task_helpers.rb:84:in `run_command!'
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/lib/tasks/gitlab/gitaly.rake:22:in `block (4 levels) in <top (required)>'
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/lib/tasks/gitlab/gitaly.rake:20:in `chdir'
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/lib/tasks/gitlab/gitaly.rake:20:in `block (3 levels) in <top (required)>'
Tasks: TOP => gitlab:gitaly:install
(See full trace by running task with --trace)
Finished in 11.03 seconds (files took 7.43 seconds to load)
0 examples, 0 failures
bundler: failed to load command: rspec (/home/lupine/.gem/ruby/2.3.4/bin/rspec)
RuntimeError: Can't clone gitaly
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/spec/support/test_env.rb:135:in `setup_gitaly'
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/spec/support/test_env.rb:72:in `init'
/home/lupine/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab/spec/spec_helper.rb:70:in `block (2 levels) in <top (required)>'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/example.rb:441:in `instance_exec'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/example.rb:441:in `instance_exec'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/hooks.rb:350:in `run'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/configuration.rb:1880:in `block in run_hooks_with'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/configuration.rb:1880:in `each'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/configuration.rb:1880:in `run_hooks_with'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/configuration.rb:1836:in `with_suite_hooks'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/runner.rb:112:in `block in run_specs'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/reporter.rb:77:in `report'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/runner.rb:111:in `run_specs'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/runner.rb:87:in `run'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/runner.rb:71:in `run'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/lib/rspec/core/runner.rb:45:in `invoke'
/home/lupine/.gem/ruby/2.3.4/gems/rspec-core-3.5.0/exe/rspec:4:in `<top (required)>'
/home/lupine/.gem/ruby/2.3.4/bin/rspec:22:in `load'
/home/lupine/.gem/ruby/2.3.4/bin/rspec:22:in `<top (required)>'
lupine@gitlab-t470p:~/dev/gitlab.com/gitlab-org/gitlab-development-kit/gitlab$
Possible fixes
Removing tmp/tests/gitaly makes the problem go away, but we should probably fix this.
Edited by Nick Thomas