Skip to content

Cargo install now fails due to crate_version issue #9

Open
@timwsuqld

Description

@timwsuqld

Possibly similar issue to tauri-apps/tauri#3050??

Attempt to install via cargo has the following error.

$ cargo install i3owm
<snip>
   Compiling i3owm v0.2.15
error[E0432]: unresolved import `clap::crate_version`
 --> /home/timw/.cargo/registry/src/github.com-1ecc6299db9ec823/i3owm-0.2.15/src/main.rs:6:12
  |
6 | use clap::{crate_version, load_yaml, App};
  |            ^^^^^^^^^^^^^ no `crate_version` in the root

error: cannot determine resolution for the macro `crate_version`
  --> /home/timw/.cargo/registry/src/github.com-1ecc6299db9ec823/i3owm-0.2.15/src/main.rs:28:40
   |
28 |     let args = App::from(yaml).version(crate_version!()).get_matches();
   |                                        ^^^^^^^^^^^^^
   |
   = note: import resolution is stuck, try simplifying macro imports

error[E0308]: mismatched types
  --> /home/timw/.cargo/registry/src/github.com-1ecc6299db9ec823/i3owm-0.2.15/src/main.rs:28:26
   |
28 |     let args = App::from(yaml).version(crate_version!()).get_matches();
   |                          ^^^^ expected struct `App`, found `&yaml_rust::yaml::Yaml`

Some errors have detailed explanations: E0308, E0432.
For more information about an error, try `rustc --explain E0308`.
error: failed to compile `i3owm v0.2.15`, intermediate artifacts can be found at `/tmp/cargo-installo3FXlz`

Caused by:
  could not compile `i3owm` due to 3 previous errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions