-
-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
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
failure in GitLab runner: error: unexpected argument 'sh' found #742
Comments
What I wonder though is why there is no output in the runner. In an interactive shell I get: $ cargo msrv verify
Fetching index
Verifying the Minimum Supported Rust Version (MSRV) for toolchain x86_64-unknown-linux-gnu
Using check command cargo check
Finished Satisfied MSRV check: 1.56.1 █████████ 00:00:00 In the GitLab runner logs there is just nothing. I'm assuming that's because CI jobs are non-interactive shells, no TERM env var is set, or some other reason, dunno for what you're checking. It would certainly be nice if there was a more CI-friendly output mode for $ cargo msrv verify
success: MSRV 1.56.1 verified ... and the output of the verify commands in case of failure, so you can immediately see what the problems are: $ cargo msrv verify [-- <COMMANDS>...]
error: MSRV 1.56.1 not verified
[output of <COMMANDS>... here] |
Certainly! |
Would Alternatively, I could modify the output of the This is what
and
|
I think it would be beneficial for CI output to show the actual failures to avoid having to run case everything okminimalistic output:
case failureinclude output of the check command:
|
original snippet from
.gitlab-ci.yml
:error is: (full job log here)
It's due to the way GitLab runner works with the entrypoint, which requires a shell, docs here. The current image (as is) is not compatible with the GitLab runner workflow, because the entrypoint doesn't point to a shell but to the
cargo-msrv
binary. This was unexpected and I wondered for a bit where thissh
came from. Luckily, the entrypoint can be overriden with configuration, this now passes (job log here):I don't want to request to change the entrypoint you currently have in your Dockerfile, because that would likely screw with ppls current usage of the image/container. Would you be open to adding a CI section to the cargo-msrv book so others have an easier reference in avoiding this? I'd be open to provide a PR.
Note: I explicitly avoided doing
cargo install cargo-msrv
becausing building that every time the pipelines runs just takes too long, wastes energy, and would quickly consume the compute usage quota that the gitlab.com instance has.The text was updated successfully, but these errors were encountered: