Skip to content

Cargo install doesn't work without --locked #2659

@arielb1

Description

@arielb1

Bug Description

Cargo install doesn't work without --locked due to rust-cross/cargo-xwin#160 - you'll need to update to cargo-xwin 0.19.0

Your maturin version (maturin --version)

1.9.0

Your Python version (python -V)

Python 3.12.10

Your pip version (pip -V)

pip 24.3.1

What bindings you're using

None

Does cargo build work?

  • Yes, it works

If on windows, have you checked that you aren't accidentally using unix path (those with the forward slash /)?

  • Yes

Steps to Reproduce

cargo install maturin does not work

error:

error[E0061]: this function takes 4 arguments but 3 arguments were supplied
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/cargo-xwin-0.18.6/src/compiler/clang_cl.rs:172:19
    |
172 | ... = xwin::Ctx::with_dir(xwin::PathBuf::from(xwin_dir), draw_target, agent)?;
    |       ^^^^^^^^^^^^^^^^^^^---------------------------------------------------
    |                          |                                            |
    |                          |                                            expected `xwin::ureq::Agent`, found `ureq::Agent`
    |                          argument #4 of type `u8` is missing
    |
note: two different versions of crate `ureq` are being used; two types coming from two different versions of the same crate are different types even if they look the same
    |
   ::: /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/ureq-3.0.12/src/agent.rs:90:1
    |
90  | pub struct Agent {
    | ^^^^^^^^^^^^^^^^ this is the expected type `xwin::ureq::Agent`
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/ureq-2.12.1/src/agent.rs:112:1
    |
112 | pub struct Agent {
    | ^^^^^^^^^^^^^^^^ this is the found type `ureq::Agent`
    |
   ::: /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/cargo-xwin-0.18.6/src/compiler/clang_cl.rs:14:5
    |
14  | use xwin::util::ProgressTarget;
    |     ---- one version of crate `ureq` used here, as a dependency of crate `xwin`
    |
   ::: /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/cargo-xwin-0.18.6/src/compiler/clang.rs:152:59
    |
152 | ...wnload_url(&self, agent: ureq::Agent) -> Result<String> {
    |                             ---- one version of crate `ureq` used here, as a direct dependency of the current crate
    = help: you can use `cargo tree` to explore your dependency tree
note: associated function defined here
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/xwin-0.6.6/src/ctx.rs:46:12
    |
46  |     pub fn with_dir(
    |            ^^^^^^^^
help: provide the argument
    |
172 -         let ctx = xwin::Ctx::with_dir(xwin::PathBuf::from(xwin_dir), draw_target, agent)?;
172 +         let ctx = xwin::Ctx::with_dir(xwin::PathBuf::from(xwin_dir), draw_target, /* xwin::ureq::Agent */, /* u8 */)?;
    |

error[E0061]: this function takes 7 arguments but 6 arguments were supplied
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/cargo-xwin-0.18.6/src/compiler/clang_cl.rs:186:22
    |
186 |         let pruned = xwin::prune_pkg_list(
    |                      ^^^^^^^^^^^^^^^^^^^^
...
191 |             self.xwin_options.xwin_sdk_version.clone(),
    |             ------------------------------------------ argument #5 of type `bool` is missing
    |
note: function defined here
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/xwin-0.6.6/src/lib.rs:198:8
    |
198 | pub fn prune_pkg_list(
    |        ^^^^^^^^^^^^^^
help: provide the argument
    |
186 -         let pruned = xwin::prune_pkg_list(
   --> /tmp/tmp.6MIQvA7jtp/registry/src/index.crates.io-1949cf8c6b5b557f/xwin-0.6.6/src/ctx.rs:259:12
    |
259 |     pub fn execute(
    |            ^^^^^^^
help: provide the argument
    |
262 -         ctx.execute(
263 -             pkgs,
264 -             work_items,
265 -             pruned.crt_version,
266 -             pruned.sdk_version,
267 -             arches,
268 -             variants,
269 -             op,
270 -         )?;
262 +         ctx.execute(pkgs, work_items, pruned.crt_version, pruned.sdk_version, /* std::option::Option<std::string::String> */, variants, arches, op)?;
    |

For more information about this error, try `rustc --explain E0061`.
error: could not compile `cargo-xwin` (lib) due to 3 previous errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions