-
-
Notifications
You must be signed in to change notification settings - Fork 385
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
attr.evolve
no longer supports setting an attr object as attribute
#804
Comments
attr.evolve
no longer supports setting an attr class as attributeattr.evolve
no longer supports setting an attr object as attribute
same here. Issue is in attr._funcs.evolve at:
|
Yeah, we'll have to revert #759 and push out 21.2. I'm gonna wait a bit with the release to see if there's other breakages that should be fixed. |
There is a regression that breaks attr.evolve() when updating attributes that contain an attr class; which we use (eg. for Person or TimestampWithTimezone). v21.2.0 is expected to fix the issue, but won't be released immediately: python-attrs/attrs#804 (comment)
21.2 with the fix is on PyPI. |
Hi,
I don't know if this is an intentional side-effect of #759, but
attr.evolve
no longer works in the non-recursive recursive case if the argument is an attr class.Here is a snippet to reproduce it:
Before fe6eb31, it printed this:
Cls1(param1=Cls2(param2='b'))
But after this commit, it raises this error:
Thanks!
The text was updated successfully, but these errors were encountered: