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

cbindgen failures after bumping Rust dependencies #1777

Closed
jlebon opened this issue Mar 7, 2019 · 3 comments
Closed

cbindgen failures after bumping Rust dependencies #1777

jlebon opened this issue Mar 7, 2019 · 3 comments

Comments

@jlebon
Copy link
Member

jlebon commented Mar 7, 2019

Still tracking this down, but it seems like I can no longer build git master from scratch after 3f722b5. It fails on the step to call cbindgen to generate the header:

$ cbindgen -c rust/cbindgen.toml -o rpmostree-rust.h ./rust -vv
ERROR: Couldn't execute `cargo metadata` with manifest "./rust/Cargo.toml": Json(Error("EOF while parsing a value", line: 1, column: 0))
ERROR: Couldn't generate bindings for ./rust.
@jlebon
Copy link
Member Author

jlebon commented Mar 7, 2019

OK, so one obvious thing here is that CI is using cbindgen: internal, which currently pulls in v0.6.8, while I'm using the packaged one, which is at v0.6.3. Trying internal.

@jlebon
Copy link
Member Author

jlebon commented Mar 7, 2019

Hmm nope, even internal fails:

   Compiling cbindgen v0.6.8
   Compiling rpmostree-bindgen v0.1.0 (file:///home/jlebon/Code/github.com/projectatomic/rpm-ostree/bindgen)
    Finished dev [unoptimized + debuginfo] target(s) in 1m 40s
  GEN      rpmostree-rust.h
error: Couldn't execute `cargo metadata` with manifest "./rust/Cargo.toml": Json(Error("EOF while parsing a value", line: 1, column: 0))
make: *** [Makefile:5362: rpmostree-rust.h] Error 1

@jlebon
Copy link
Member Author

jlebon commented Mar 7, 2019

OK, so I think this is due to cargo v1.29.2 erroring out on fuchsia-cprng now using editions:

$ cargo metadata
warning: please specify `--format-version` flag explicitly to avoid compatibility problems
error: unable to get packages from source

Caused by:
  failed to parse manifest at `/home/jlebon/.cargo/registry/src/github.aaakk.us.kg-1ecc6299db9ec823/fuchsia-cprng-0.1.1/Cargo.toml`

Caused by:
  editions are unstable

Caused by:
  feature `edition` is required

It works fine with the latest cargo. So I think CI is just not hitting this because it's pulling in cargo from the Fedora repos, while the rust check we have doesn't actually go through the cbindgen path. Will fix.

jlebon added a commit to jlebon/rpm-ostree that referenced this issue Mar 7, 2019
The recent dep bump caused rand to jump to v0.6.5, which pulled in
`fuchsia-cprng`. Sadly, the cargo version we're frozen on chokes on it
because its manifest makes use of the `edition` keyword, which wasn't
stabilized yet.

Let's just freeze the problematic crate for now. We should be able to
bump our Rust toolchain soon-ish.

(Note this commit also does some other minor crate bumps as a result of
regenerating the lockfile to prune away `fuchsia-cprng`.)

Closes: coreos#1777
rh-atomic-bot pushed a commit that referenced this issue Mar 7, 2019
The recent dep bump caused rand to jump to v0.6.5, which pulled in
`fuchsia-cprng`. Sadly, the cargo version we're frozen on chokes on it
because its manifest makes use of the `edition` keyword, which wasn't
stabilized yet.

Let's just freeze the problematic crate for now. We should be able to
bump our Rust toolchain soon-ish.

(Note this commit also does some other minor crate bumps as a result of
regenerating the lockfile to prune away `fuchsia-cprng`.)

Closes: #1777

Closes: #1778
Approved by: cgwalters
jlebon added a commit to jlebon/rpm-ostree that referenced this issue Mar 7, 2019
The recent dep bump caused rand to jump to v0.6.5, which pulled in
`fuchsia-cprng`. Sadly, the cargo version we're frozen on chokes on it
because its manifest makes use of the `edition` keyword, which wasn't
stabilized yet.

Let's just freeze the problematic crate for now. We should be able to
bump our Rust toolchain soon-ish.

(Note this commit also does some other minor crate bumps as a result of
regenerating the lockfile to prune away `fuchsia-cprng`.)

Closes: coreos#1777
jlebon added a commit to jlebon/rpm-ostree that referenced this issue Apr 3, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for coreos#1777.
rh-atomic-bot pushed a commit that referenced this issue Apr 3, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for #1777.

Closes: #1810
Approved by: cgwalters
rh-atomic-bot pushed a commit that referenced this issue Apr 3, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for #1777.

Closes: #1810
Approved by: cgwalters
rh-atomic-bot pushed a commit that referenced this issue Apr 3, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for #1777.

Closes: #1810
Approved by: cgwalters
rh-atomic-bot pushed a commit that referenced this issue Apr 4, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for #1777.

Closes: #1810
Approved by: cgwalters
rh-atomic-bot pushed a commit that referenced this issue Apr 5, 2019
Now that our minimum Rust toolchain version was bumped, we can bump all
our deps to the latest and drop the frozen `rand` version that was done
for #1777.

Closes: #1810
Approved by: jlebon
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant