Skip to content

Support PyO3's abi3-py38 feature #79

Support PyO3's abi3-py38 feature

Support PyO3's abi3-py38 feature #79

GitHub Actions / clippy failed Jun 6, 2024 in 1s

clippy

3 errors

Details

Results

Message level Amount
Internal compiler error 0
Error 3
Warning 0
Note 0
Help 0

Versions

  • rustc 1.78.0 (9b00956e5 2024-04-29)
  • cargo 1.78.0 (54d8815d0 2024-03-26)
  • clippy 0.1.78 (9b00956 2024-04-29)

Annotations

Check failure on line 415 in src/de.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied

error[E0277]: the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied
    --> src/de.rs:415:39
     |
415  |                     let variant = key.extract()?;
     |                                       ^^^^^^^ the trait `pyo3::PyClass` is not implemented for `&str`, which is required by `&str: pyo3::conversion::FromPyObjectBound<'_, '_>`
     |
     = help: the following other types implement trait `pyo3::conversion::FromPyObjectBound<'a, 'py>`:
               std::borrow::Cow<'a, [u8]>
               std::borrow::Cow<'a, str>
               &'a [u8]
     = note: required for `&str` to implement `pyo3::FromPyObject<'_>`
     = note: required for `&str` to implement `pyo3::conversion::FromPyObjectBound<'_, '_>`
note: required by a bound in `pyo3::prelude::PyAnyMethods::extract`
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pyo3-0.21.2/src/types/any.rs:1649:12
     |
1647 |     fn extract<'a, T>(&'a self) -> PyResult<T>
     |        ------- required by a bound in this associated function
1648 |     where
1649 |         T: FromPyObjectBound<'a, 'py>;
     |            ^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `PyAnyMethods::extract`

Check failure on line 401 in src/de.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied

error[E0277]: the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied
    --> src/de.rs:401:34
     |
401  |             let variant = self.0.extract()?;
     |                                  ^^^^^^^ the trait `pyo3::PyClass` is not implemented for `&str`, which is required by `&str: pyo3::conversion::FromPyObjectBound<'_, '_>`
     |
     = help: the following other types implement trait `pyo3::conversion::FromPyObjectBound<'a, 'py>`:
               std::borrow::Cow<'a, [u8]>
               std::borrow::Cow<'a, str>
               &'a [u8]
     = note: required for `&str` to implement `pyo3::FromPyObject<'_>`
     = note: required for `&str` to implement `pyo3::conversion::FromPyObjectBound<'_, '_>`
note: required by a bound in `pyo3::prelude::PyAnyMethods::extract`
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pyo3-0.21.2/src/types/any.rs:1649:12
     |
1647 |     fn extract<'a, T>(&'a self) -> PyResult<T>
     |        ------- required by a bound in this associated function
1648 |     where
1649 |         T: FromPyObjectBound<'a, 'py>;
     |            ^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `PyAnyMethods::extract`

Check failure on line 319 in src/de.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied

error[E0277]: the trait bound `&str: pyo3::conversion::FromPyObjectBound<'_, '_>` is not satisfied
    --> src/de.rs:319:45
     |
319  |             return visitor.visit_str(self.0.extract()?);
     |                                             ^^^^^^^ the trait `pyo3::PyClass` is not implemented for `&str`, which is required by `&str: pyo3::conversion::FromPyObjectBound<'_, '_>`
     |
     = help: the following other types implement trait `pyo3::conversion::FromPyObjectBound<'a, 'py>`:
               std::borrow::Cow<'a, [u8]>
               std::borrow::Cow<'a, str>
               &'a [u8]
     = note: required for `&str` to implement `pyo3::FromPyObject<'_>`
     = note: required for `&str` to implement `pyo3::conversion::FromPyObjectBound<'_, '_>`
note: required by a bound in `pyo3::prelude::PyAnyMethods::extract`
    --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pyo3-0.21.2/src/types/any.rs:1649:12
     |
1647 |     fn extract<'a, T>(&'a self) -> PyResult<T>
     |        ------- required by a bound in this associated function
1648 |     where
1649 |         T: FromPyObjectBound<'a, 'py>;
     |            ^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `PyAnyMethods::extract`