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
[BUG] Using a dataclass with positional and non-positional args causes a runtime exception #4934
Comments
Cython 0.29.x doesn't support class annotations (and won't support class annotations). Therefore dataclasses will not usefully work with it. They will work with the Cython 3 alpha branch. Duplicate of #2552 |
It just doesn't generate the |
Is 3 considered stable enough? I would love to use these python features, but not at the risk of destabilizing our application |
Considered by whom? 0.29.31 isn't a great story of not breaking things right now... It's reasonably stable I think, but it obviously depends on what the risk is. The current 3.0a10 release has been out for a while without major issue. The next release may well break some |
I'm on an older cython than 0.29.31, I just tried to to make sure it wasn't fixed in the latest. Thanks, ill give it a try, is 3 published to anaconda? |
It doesn't look it it unfortunately |
Describe the bug
Execute the code below after cythonizing it and it will generate a runtime exception.
Vanilla Python has no issues
To Reproduce
Code to reproduce the behaviour:
Expected behavior
I expect the code to run, and not crash at runtime
Environment (please complete the following information):
Additional context
There seems to be other weirdness with dataclasses as well, I can file issues for those as well.
The text was updated successfully, but these errors were encountered: