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

Build failure on some linux build servers #817

Closed
dilawar opened this issue Nov 23, 2024 · 2 comments · Fixed by #821
Closed

Build failure on some linux build servers #817

dilawar opened this issue Nov 23, 2024 · 2 comments · Fixed by #821

Comments

@dilawar
Copy link

dilawar commented Nov 23, 2024

On some of my build servers (debian 12, openSuse 15.6), I am getting the following error for last two days. I am not sure what changed!

 Compiling magika v0.1.0-rc.2 (https://github.com/google/magika#906afc82)
error[E0432]: unresolved import `ort::GraphOptimizationLevel`
  --> /home/dilawar/.cargo/git/checkouts/magika-0dc2ca1a149e7051/906afc8/rust/lib/src/builder.rs:15:5
   |
15 | use ort::GraphOptimizationLevel;
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `GraphOptimizationLevel` in the root 
   |
help: consider importing this enum instead
   |
15 | use ort::session::builder::GraphOptimizationLevel;
   |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

error[E0433]: failed to resolve: could not find `Session` in `ort`
  --> /home/dilawar/.cargo/git/checkouts/magika-0dc2ca1a149e7051/906afc8/rust/lib/src/builder.rs:55:32
   |
55 |         let mut session = ort::Session::builder()?;
   |                                ^^^^^^^ could not find `Session` in `ort`
   |
help: consider importing one of these structs
   |                                                           

Either of the following causes the same error.

  # magika = { git = "https://github.com/google/magika", features = [ "_test", "serde" ]}                                                             
  magika = { version = "0.1.0-rc.2", features = [ "_test", "serde" ]}                                                                                 
@dilawar dilawar changed the title Build failure on some build servers Build failure on some linux build servers Nov 23, 2024
dilawar added a commit to dilawar/magika that referenced this issue Nov 23, 2024
@reyammer
Copy link
Collaborator

Thanks for reporting! @ia0, any ideas?

@ia0
Copy link
Member

ia0 commented Nov 26, 2024

Yes, there was a new release of ort and cargo seems to consider all pre-release versions compatible (which I'm not sure follows semver). We should use =2.0.0-rc.8 in rust/lib/Cargo.toml. I'll do that next week.

In the meantime (and until next release), the solution is to cargo update --precise=2.0.0-rc.8 ort from the crate that depends on magika.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants