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

gh-102103: add module argument to dataclasses.make_dataclass #102104

Merged
merged 4 commits into from
Mar 11, 2023

Conversation

sobolevn
Copy link
Member

@sobolevn sobolevn commented Feb 21, 2023

Now, dataclasses created by this function are also pickleable (as a side effect of fixing __module__ attribute).

Copy link
Member

@carljm carljm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a real issue, and solving it in the same way as namedtuple seems reasonable (though it's too bad to add more stack-walking.)

Lib/test/test_dataclasses.py Outdated Show resolved Hide resolved
Lib/test/test_dataclasses.py Show resolved Hide resolved
Co-authored-by: Carl Meyer <carl@oddbird.net>
@sobolevn
Copy link
Member Author

sobolevn commented Mar 8, 2023

@ericvsmith friendly ping :)

@sobolevn
Copy link
Member Author

Thanks!

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.

3 participants