-
Notifications
You must be signed in to change notification settings - Fork 788
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
ambiguous associated item 'Error' since 0.23 #4723
Labels
Comments
I can replicate this and I've bisected it to 0a185cd. I can confirm that any of the associated types |
LilyFoote
added a commit
that referenced
this issue
Nov 21, 2024
This uses the fix described in rust-lang/rust#57644
LilyFoote
added a commit
that referenced
this issue
Nov 22, 2024
This uses the fix described in rust-lang/rust#57644
LilyFoote
added a commit
that referenced
this issue
Nov 22, 2024
This uses the fix described in rust-lang/rust#57644
LilyFoote
added a commit
that referenced
this issue
Nov 23, 2024
This uses the fix described in rust-lang/rust#57644 Also apply fix to `#[derive(IntoPyObject)]`.
LilyFoote
added a commit
that referenced
this issue
Nov 23, 2024
This uses the fix described in rust-lang/rust#57644 Also apply fix to `#[derive(IntoPyObject)]`.
github-merge-queue bot
pushed a commit
that referenced
this issue
Nov 23, 2024
* Add test for ambiguous associated item The `#[pyclass]` macro implements `IntoPyObject` for the annotated enum. When the enum has any of `Error`, `Output` or `Target` as members, this clashes with the associated types of `IntoPyObject`. This also happens when deriving `IntoPyObject` directly. * Fix #4723: ambiguous associated item in #[pyclass] This uses the fix described in rust-lang/rust#57644 Also apply fix to `#[derive(IntoPyObject)]`.
davidhewitt
pushed a commit
that referenced
this issue
Nov 25, 2024
* Add test for ambiguous associated item The `#[pyclass]` macro implements `IntoPyObject` for the annotated enum. When the enum has any of `Error`, `Output` or `Target` as members, this clashes with the associated types of `IntoPyObject`. This also happens when deriving `IntoPyObject` directly. * Fix #4723: ambiguous associated item in #[pyclass] This uses the fix described in rust-lang/rust#57644 Also apply fix to `#[derive(IntoPyObject)]`.
davidhewitt
pushed a commit
that referenced
this issue
Nov 25, 2024
* Add test for ambiguous associated item The `#[pyclass]` macro implements `IntoPyObject` for the annotated enum. When the enum has any of `Error`, `Output` or `Target` as members, this clashes with the associated types of `IntoPyObject`. This also happens when deriving `IntoPyObject` directly. * Fix #4723: ambiguous associated item in #[pyclass] This uses the fix described in rust-lang/rust#57644 Also apply fix to `#[derive(IntoPyObject)]`.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Description
Since 0.23 I get the following error message when I define an enum which contains the name 'Error':
The enum is defined as follows:
Steps to Reproduce
Just changed the version from 0.22 to 0.23 and this error message is shown.
Backtrace
No response
Your operating system and version
Ubuntu 24.04.1 LTS
Your Python version (
python --version
)Python 3.12.7
Your Rust version (
rustc --version
)rustc 1.84.0-nightly (5ec7d6eee 2024-11-17)
Your PyO3 version
0.23.1
How did you install python? Did you use a virtualenv?
pyenv
Additional Info
No response
The text was updated successfully, but these errors were encountered: