Skip to content

"hyper" is being rebuilt on each cargo miri run #1722

@RalfJung

Description

@RalfJung

To reproduce, do cargo init to create a new project, and replace the Cargo.toml file by

[package]
name = "playground"
version = "0.0.1"
authors = ["The Rust Playground"]

[dependencies.hyper]
package = "hyper"
version = "=0.14.4"
features = ["full"]

Then run cargo miri run, and then run the same command again.

Expected behavior: the second time, the program is being run immediately.

Actual behavior: hyper is being rebuilt, as the build log shows:

$ cargo +miri miri run
   Compiling hyper v0.14.4
   Compiling playground v0.0.1 (/home/r/src/rust/rust-playground/playground)
    Finished dev [unoptimized + debuginfo] target(s) in 4.29s
     Running `/home/r/.cargo/bin/cargo-miri target/x86_64-unknown-linux-gnu/debug/playground`
Hello, world!

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-cargoArea: affects the cargo wrapper (cargo miri)C-bugCategory: This is a bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions