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

Show attrs auto_detect incompleteness #16704

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

meshy
Copy link
Contributor

@meshy meshy commented Dec 23, 2023

This test demonstrates that addition of dunder methods in attrs classes isn't quite complete.

While the existing test demonstrated that the __attrs_init__ method was generated in classes defined with init=False, it wasn't generated in the same way when __init__ was defined with auto_detect=True enabled (either explicitly, or by default).

The auto-generated __attrs_init__ has been enabled in Attrs since version 21.1.0.

Related to: #10328
Ref: python-attrs/attrs#793
Ref: python-attrs/attrs#731
Ref: https://www.attrs.org/en/stable/changelog.html

This test demonstrates that addition of dunder methods in attrs classes
isn't quite complete.

While the existing test demonstrates that it was working for classes
defined with `init=False`, the `__attrs_init__` method wasn't generated
in the same way when `__init__` was defined with `auto_detect=True`
enabled (either explicitly, or by default).

This auto-generated `__attrs_init__` has been enabled in Attrs as of
version 21.1.0.

Related to: python#10328
Ref: python-attrs/attrs#793
Ref: https://www.attrs.org/en/stable/changelog.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant