asdf shim issue when running test suite
I've been working on adding a test but I'm bumping into an issue with the ruby
and bundle
commands not picking up the asdf
shims. Example output from the test run:
{"level":"warning","msg":"git path not configured. Using default path resolution","resolvedPath":"/usr/bin/git","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"clearing disk cache object folder","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"moving disk cache object folder to /home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/tmp/diskcache056959580","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"disk cache object folder doesn't exist, no need to remove","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"Starting file walker for /home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/cache","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/cache","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"Starting file walker for /home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/state","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/state","time":"2020-11-20T17:53:33.630Z"}
{"level":"info","msg":"cleared all cache object files in /home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data/+gitaly/tmp/diskcache056959580 after 29.068µs","path":"/home/robotmay/Development/gitlab/gitlab-development-kit/gitaly/internal/testhelper/testdata/data","time":"2020-11-20T17:53:33.630Z"}
unknown command: bundle. Perhaps you have to reshim?
{"level":"fatal","msg":"error configuring tests: exit status 1; stderr: \"\"","time":"2020-11-20T17:53:33.637Z"}
FAIL gitlab.com/gitlab-org/gitaly/internal/gitaly/service/remote 0.113s
FAIL
I've poked about a bit and I can get it to skip the bundle
failure above but it then hits the same issue with the ruby
binary. I suspect the PATH
env var isn't being passed through when spinning up the rubyserver
. The initial calls to ConfigureRuby
pass, the error seems to be thrown later on (so I suspect when actually performing calls to bundle
/ruby
)
I've also tried adding a .tool-versions
file specifying the Ruby version in both the root dir and /ruby
dir but that didn't seem to have any effect.
It might be worth asking if the GDK team had any encounters with something like this, as they recently added support there.