-
Notifications
You must be signed in to change notification settings - Fork 70
Closed
Description
Recently, I got an error when I was installing cargo component in GitHub actions. The error is:
error[E0061]: this method takes 1 argument but 0 arguments were supplied
--> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-component-core-0.11.0/src/registry.rs:882:38
|
882 | .load_package(client.get_warg_registry(), e.key())
| ^^^^^^^^^^^^^^^^^-- an argument of type `&str` is missing
|
note: method defined here
--> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/warg-client-0.4.3/src/lib.rs:118:18
|
118 | pub async fn get_warg_registry(
| ^^^^^^^^^^^^^^^^^
help: provide the argument
|
882 | .load_package(client.get_warg_registry(/* &str */), e.key())
| ~~~~~~~~~~~~
error[E0308]: mismatched types
--> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-component-core-0.11.0/src/registry.rs:882:31
|
882 | .load_package(client.get_warg_registry(), e.key())
| ------------ ^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Option<&RegistryDomain>`, found future
| |
| arguments to this method are incorrect
|
note: method defined here
--> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/warg-client-0.4.3/src/storage.rs:111:14
|
111 | async fn load_package(
| ^^^^^^^^^^^^
error[E0599]: no method named `upsert` found for struct `Arc<warg_client::Client<FileSystemRegistryStorage, FileSystemContentStorage, FileSystemNamespaceMapStorage>>` in the current scope
--> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-component-core-0.11.0/src/registry.rs:594:32
|
594 | (index, client.upsert(upserts.iter()).await)
| ^^^^^^ method not found in `Arc<Client<FileSystemRegistryStorage, FileSystemContentStorage, FileSystemNamespaceMapStorage>>`
Some errors have detailed explanations: E0061, E0308, E0599.
For more information about an error, try `rustc --explain E0061`.
error: could not compile `cargo-component-core` (lib) due to 3 previous errors
This happens for version 0.10.1 (see here) as well as 0.11.0 (see here). I get the same error when I install on my Windows 10 computer with --force.
I think the install command was working fine a week or two ago, so my first guess would be that a dependency crate released a new minor version with breaking changes (not following semver), and cargo install is now fetching that new version and the build fails because of the breaking change.
EDIT:
You can install cargo component with the lock file using
cargo install cargo-component --locked
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels