You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Everything is in the title. Currently, #[pyo3(from_py_with)] is just ignored for dunder methods like __eq__ in my case, you can even write fake function name, it has not effect at all.
I've started looking at the code, it seems that dunder methods use a completely different code for generation, so fixing this issue seems not so trivial.
Waiting for the solution, this behavior should at least be documented, to avoid the surprise for the users.
The text was updated successfully, but these errors were encountered:
wyfo
added a commit
to ZettaScaleLabs/zenoh-python
that referenced
this issue
Apr 24, 2024
I think it makes sense to allow [pyo3(from_py_with= ...)] there, given that extracting types directly is already allowed. I implemented a fix in #4117, which should now handle them correctly.
wyfo
added a commit
to ZettaScaleLabs/zenoh-python
that referenced
this issue
Apr 25, 2024
Everything is in the title. Currently,
#[pyo3(from_py_with)]
is just ignored for dunder methods like__eq__
in my case, you can even write fake function name, it has not effect at all.I've started looking at the code, it seems that dunder methods use a completely different code for generation, so fixing this issue seems not so trivial.
Waiting for the solution, this behavior should at least be documented, to avoid the surprise for the users.
The text was updated successfully, but these errors were encountered: