-
-
Notifications
You must be signed in to change notification settings - Fork 105
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
Bug: default store directory does not respect CARGO_TARGET_DIR
#2066
Comments
Thanks -- yeah, this has been a problem for a while. I'd definitely like to change the default at some point, but that would have to be a carefully-managed behavior change. I think for now we should let you set the target directory to be the same as CARGO_TARGET_DIR. |
Would some form of environment interpolation in config be possible? Maybe the default could change to be |
Yeah -- though in this other case we decided to let you say https://nexte.st/docs/ci-features/archiving/#adding-extra-files-to-an-archive So you'd say store.dir = { path = "nextest", relative-to = "target" } and we'd eventually make this the default. |
I have a build container that mounts the root dir and writes all of its output to the folder There are occasions where it is quite useful to be able to do that, so it would be nice if the To work around that, I use a wrapping bash script that checks for |
Absolutely agreed that this is an issue -- please submit a PR! |
I've started on this in #2154. I would love somebody's help completing this (in particular, writing tests for this). I'm also not sure how temporary target directories should be handled, and would appreciate ideas there as well. |
Description of the issue
Description:
Nextest always tries to create the store directory at the workspace root, which fails if the workspace is read-only.
Steps to reproduce:
target
directory is clean (or at leasttarget/nextest
does not exist)CARGO_TARGET_DIR
. :docker run --rm -e CARGO_TARGET_DIR=/target -v "$(pwd):/checkout:ro" -it rust bash
cargo install cargo-nextest
cd /checkout
cargo test
. This should workcargo nextest run
. This fails with something like:Expected outcome
By default, rather than using a path relative to the workspace root, nextest should create its store directory within
CARGO_TARGET_DIR
if it is set.Actual result
Unable to create the file (see above)
Nextest version
Additional context
No response
The text was updated successfully, but these errors were encountered: