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

Error when compiling Libium with Cargo install #416

Closed
1 task done
SusStew opened this issue May 21, 2024 · 2 comments
Closed
1 task done

Error when compiling Libium with Cargo install #416

SusStew opened this issue May 21, 2024 · 2 comments
Labels
bug Something doesn't work as expected fixed in source Bug has been fixed in source-code, but has not been released yet priority I'm working on it, or will be soon

Comments

@SusStew
Copy link

SusStew commented May 21, 2024

Description

When attempting to install Ferium using Cargo that I installed using the script from rustup.rs, I receive the following error message near the end of the installation steps:

Compiling libium v1.26.2
error[E0432]: unresolved import `ferinth::structures::version::Hashes`
 --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libium-1.26.2/src/modpack/modrinth/structs.rs:1:57
  |
1 | use ferinth::structures::{project::ProjectSupportRange, version::Hashes, Int};
  |                                                         ^^^^^^^^^------
  |                                                         |        |
  |                                                         |        help: a similar name exists in the module: `Hash`
  |                                                         no `Hashes` in `structures::version`

error[E0308]: mismatched types
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libium-1.26.2/src/add.rs:36:47
   |
36 |             if Some(StatusCode::NOT_FOUND) == source.status() {
   |                                               ^^^^^^^^^^^^^^^ expected `StatusCode`, found `http::status::StatusCode`
   |
   = note: `http::status::StatusCode` and `StatusCode` have similar names, but are actually distinct types
note: `http::status::StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-1.1.0/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
note: `StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-0.2.12/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
   = note: perhaps two different versions of crate `http` are being used?

error[E0308]: mismatched types
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libium-1.26.2/src/add.rs:50:47
   |
50 |             if Some(StatusCode::NOT_FOUND) == source.status() {
   |                                               ^^^^^^^^^^^^^^^ expected `StatusCode`, found `http::status::StatusCode`
   |
   = note: `http::status::StatusCode` and `StatusCode` have similar names, but are actually distinct types
note: `http::status::StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-1.1.0/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
note: `StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-0.2.12/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
   = note: perhaps two different versions of crate `http` are being used?

error[E0308]: mismatched types
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libium-1.26.2/src/modpack/add.rs:26:47
   |
26 |             if Some(StatusCode::NOT_FOUND) == source.status() {
   |                                               ^^^^^^^^^^^^^^^ expected `StatusCode`, found `http::status::StatusCode`
   |
   = note: `http::status::StatusCode` and `StatusCode` have similar names, but are actually distinct types
note: `http::status::StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-1.1.0/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
note: `StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-0.2.12/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
   = note: perhaps two different versions of crate `http` are being used?

error[E0308]: mismatched types
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libium-1.26.2/src/modpack/add.rs:40:47
   |
40 |             if Some(StatusCode::NOT_FOUND) == source.status() {
   |                                               ^^^^^^^^^^^^^^^ expected `StatusCode`, found `http::status::StatusCode`
   |
   = note: `http::status::StatusCode` and `StatusCode` have similar names, but are actually distinct types
note: `http::status::StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-1.1.0/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
note: `StatusCode` is defined in crate `http`
  --> /home/azureuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/http-0.2.12/src/status.rs:45:1
   |
45 | pub struct StatusCode(NonZeroU16);
   | ^^^^^^^^^^^^^^^^^^^^^
   = note: perhaps two different versions of crate `http` are being used?

Some errors have detailed explanations: E0308, E0432.
For more information about an error, try `rustc --explain E0308`.
error: could not compile `libium` (lib) due to 5 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `ferium v4.5.2`, intermediate artifacts can be found at `/tmp/cargo-install1iboZk`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.

I previously had Ferium installed using Pacstall, but since its version is outdated, I decided to install it using Cargo instead.

Steps to reproduce

No response

Operating System

Linux

Are you using the latest version of ferium?

  • I am using the latest version of ferium

Additional Information

No response

@SusStew SusStew added the bug Something doesn't work as expected label May 21, 2024
@theRookieCoder
Copy link
Collaborator

theRookieCoder commented May 21, 2024

The problem is I accidentally published a libium version that was technically a work in progress. In an attempt to 'fix' things it seems I've made them even worse:

error: could not compile `ferium` (bin "ferium") due to 17 previous errors

Anyways I'll release a new version probably tomorrow to fix things and sync up ferium with libium once again.

@theRookieCoder theRookieCoder added fixed in source Bug has been fixed in source-code, but has not been released yet priority I'm working on it, or will be soon labels Jun 10, 2024
@theRookieCoder
Copy link
Collaborator

Fixed in f17a60a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something doesn't work as expected fixed in source Bug has been fixed in source-code, but has not been released yet priority I'm working on it, or will be soon
Development

No branches or pull requests

2 participants