Skip to content
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

Git dependencies don't work due to global lock #166

Open
aidanhs opened this issue Dec 11, 2017 · 5 comments
Open

Git dependencies don't work due to global lock #166

aidanhs opened this issue Dec 11, 2017 · 5 comments
Labels
A-increase-coverage Area: increase number of tested crates

Comments

@aidanhs
Copy link
Member

aidanhs commented Dec 11, 2017

Dec 11 07:55:53.321 INFO testing https://github.com/servo/servo#22472b4db4564f7bc274eb01447e4f04fd7e7205 against master#cf30759a8409bee031ac252ee207452ab4804467 for pr-45002-2
Dec 11 07:55:53.321 INFO running: cargo +cf30759a8409bee031ac252ee207452ab4804467 build --frozen
Dec 11 07:55:53.322 INFO creating container for: cargo +cf30759a8409bee031ac252ee207452ab4804467 build --frozen
Dec 11 07:55:53.322 INFO running `"docker" "create" "-v" "/home/ec2-user/cargobomb/./work/local/test-source/pr-45002-2/master#cf30759a8409bee031ac252ee207452ab4804467:/source:ro,Z" "-v" "/home/ec2-user/cargobomb/./work/local/target-dirs/pr-45002-2/master#cf30759a8409bee031ac252ee207452ab4804467:/target:rw,Z" "-v" "/home/ec2-user/cargobomb/./work/local/cargo-home:/cargo-home:ro,Z" "-v" "/home/ec2-user/cargobomb/./work/local/rustup-home:/rustup-home:ro,Z" "-e" "USER_ID=500" "-e" "CMD=cargo +cf30759a8409bee031ac252ee207452ab4804467 build --frozen" "crater"`
Dec 11 07:55:53.450 INFO blam! 746e3c86c1b5c73cbe3b5bb9c690d06d0277b4bd0f6d2943c10274aee3b36336
Dec 11 07:55:53.451 INFO running `"docker" "start" "-a" "746e3c86c1b5c73cbe3b5bb9c690d06d0277b4bd0f6d2943c10274aee3b36336"`
Dec 11 07:55:53.974 INFO kablam! error: failed to load source for a dependency on `browserhtml`
Dec 11 07:55:53.974 INFO kablam! 
Dec 11 07:55:53.974 INFO kablam! Caused by:
Dec 11 07:55:53.974 INFO kablam!   Unable to update https://github.com/browserhtml/browserhtml?branch=crate#84913eaf
Dec 11 07:55:53.974 INFO kablam! 
Dec 11 07:55:53.974 INFO kablam! Caused by:
Dec 11 07:55:53.974 INFO kablam!   failed to open: /cargo-home/git/.cargo-lock-git
Dec 11 07:55:53.974 INFO kablam! 
Dec 11 07:55:53.974 INFO kablam! Caused by:
Dec 11 07:55:53.974 INFO kablam!   Read-only file system (os error 30)
Dec 11 07:55:53.976 INFO kablam! su: No module specific data is present
Dec 11 07:55:54.337 INFO running `"docker" "rm" "-f" "746e3c86c1b5c73cbe3b5bb9c690d06d0277b4bd0f6d2943c10274aee3b36336"`
Dec 11 07:55:54.359 INFO blam! 746e3c86c1b5c73cbe3b5bb9c690d06d0277b4bd0f6d2943c10274aee3b36336

/cargo-home/git/.cargo-lock-git is on a read only mountpoint, but I guess it gets locked even in frozen mode to stop it changing from under the feet of cargo.

@SimonSapin
Copy link
Contributor

@alexcrichton, in what cases does Cargo need write access to $CARGO_HOME?

@alexcrichton
Copy link
Member

Oh this might be a bug in Cargo, I think we specifically fixed this for the registries where if we fail to acquire a write lock we fall back to a read lock, maybe the same fix just needs to be for git?

@alexcrichton
Copy link
Member

In theory though if everything is checked out Cargo doesn't actually need write access.

@SimonSapin
Copy link
Contributor

@alexcrichton Do you remember what was in the commit message for that change? I searched for "lock" in Cargo’s git log but did not find it in 2017.

@alexcrichton
Copy link
Member

I believe I was thinking of rust-lang/cargo#3259, although it's not quite the same solution. I suspect a solution would be along the lines though of "handle the error" rather than "unconditionally propagate it outwards"

@pietroalbini pietroalbini added the A-increase-coverage Area: increase number of tested crates label Jun 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-increase-coverage Area: increase number of tested crates
Projects
None yet
Development

No branches or pull requests

4 participants