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

Option::unwrap() in src/auditwheel/audit.rs:284 due to maturin publish #739

Closed
1 of 2 tasks
andreafioraldi opened this issue Dec 10, 2021 · 3 comments · Fixed by #740
Closed
1 of 2 tasks

Option::unwrap() in src/auditwheel/audit.rs:284 due to maturin publish #739

andreafioraldi opened this issue Dec 10, 2021 · 3 comments · Fixed by #740
Labels
bug Something isn't working

Comments

@andreafioraldi
Copy link

andreafioraldi commented Dec 10, 2021

Bug Description

Hi,
I'm trying to publish my crate from Ubuntu 20.04 so I choose to target the manylinux_2_31_x86_64 platform.
Doing maturin publish --compatibility manylinux_2_31_x86_64 maturin panics on src/auditwheel/audit.rs:284.

The report is:

name = 'maturin'
operating_system = 'unix:Ubuntu'
crate_version = '0.12.4'
explanation = '''
Panic occurred in file 'src/auditwheel/audit.rs' at line 284
'''
cause = 'called `Option::unwrap()` on a `None` value'
method = 'Panic'
backtrace = '''

   0: 0x7ffff707260d - core::panicking::panic::he7efc04572bf92e9
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/panicking.rs:50
   1: 0x7ffff72223c4 - maturin::auditwheel::audit::auditwheel_rs::hcb80b09017ce3bb6
   2: 0x7ffff717a930 - maturin::build_context::BuildContext::auditwheel::h2c132b4339ba39b5
   3: 0x7ffff717b50c - maturin::build_context::BuildContext::build_binding_wheels::h3e46d0d423842f2b
   4: 0x7ffff717a0a0 - maturin::build_context::BuildContext::build_wheels::h12a4f5f720f32891
   5: 0x7ffff70f2070 - maturin::run::h2982cc821dc0d748
   6: 0x7ffff70f52e5 - maturin::main::h7a95056e5be13f8f
   7: 0x7ffff70d63e3 - std::sys_common::backtrace::__rust_begin_short_backtrace::h6fe87ad523208d48
   8: 0x7ffff70eae69 - std::rt::lang_start::{{closure}}::h03f2095f796bbe4e
   9: 0x7ffff7b5ef31 - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::h37d528e2b7386a19
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/ops/function.rs:259
                 - std::panicking::try::do_call::h21f3d980e271aebe
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:403
                 - std::panicking::try::h6366c75894a5ee3f
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:367
                 - std::panic::catch_unwind::hbab33c6a69c714f4
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panic.rs:133
                 - std::rt::lang_start_internal::{{closure}}::h4a2c188522fb7f4a
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/rt.rs:128
                 - std::panicking::try::do_call::h9b4b672a4b3537ad
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:403
                 - std::panicking::try::h9c95acfa69428cd5
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:367
                 - std::panic::catch_unwind::h137c802160173f20
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panic.rs:133
                 - std::rt::lang_start_internal::h89221b25a17002da
                at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/rt.rs:128
  10: 0x7ffff70f8662 - main'''

The maturin version is the last from PyPI, 0.12.4

Your Python version (python -V)

3.8.10

Your pip version (pip -V)

20.0.2

What bindings you're using

pyo3

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

maturin publish --compatibility manylinux_2_31_x86_64

@andreafioraldi andreafioraldi added the bug Something isn't working label Dec 10, 2021
@andreafioraldi andreafioraldi changed the title Option::unwrap() in src/auditwheel/audit.rs:313 due to maturin publish Option::unwrap() in src/auditwheel/audit.rs:284 due to maturin publish Dec 10, 2021
@messense
Copy link
Member

Thanks for the report. There isn't a manylinux_2_31 auditwheel policy yet, but I agree this shouldn't panic.

@messense
Copy link
Member

For now you need to pass --skip-auditwheel to build a manylinux_2_31 wheel, we will add support for it when upstream auditwheel project defines the policy.

#740 will make it an error:

💥 maturin failed
  Caused by: Error ensuring manylinux_2_31 compliance
  Caused by: manylinux_2_31 compatibility policy is not defined by auditwheel yet, pass `--skip-auditwheel` to proceed anyway

konstin added a commit that referenced this issue Dec 11, 2021
@messense
Copy link
Member

FYI, manylinux_2_31 support added in #755

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants