Travis CI Linux builds failing for a rustup.rs PR


#1

For the past several days I’ve been working on a PR to reintegrate hyper into rustup, and for the last two build attempts I’m getting a strange failure for all Linux builds. The build image first successfully fetches, builds and installs OpenSSL, then fails at the beginning of cargo build:

+ cargo build --release --target i686-unknown-linux-gnu
    Updating registry `https://github.com/rust-lang/crates.io-index`
    Updating git repository `https://github.com/Diggsey/markdown.rs.git`
    Updating git repository `https://github.com/sfackler/winapi-rs`
    Updating git repository `https://github.com/sfackler/rust-native-tls.git`
    Updating git repository `https://github.com/sfackler/schannel-rs`
error: failed to write /buildslave/Cargo.lock

Caused by:
  failed to open: /buildslave/Cargo.lock

To learn more, run the command again with --verbose.

Full logs for reference.


#2

Oh, gah. I retried the build and lost the logs you were linking. Maybe trying to add the suggested --verbose flag would help. cc @alexcrichton.


#3

Update: my mistake, @alexcrichton correctly diagnosed it as a not-up-to-date Cargo.lock in the commit which caused the build script to attempt modifying it and failing (it’s read-only during the build.)

Therefore, a cargo build followed by git status are in order before pushing any commit to a PR.