Skip to content

Respect msgspec.Struct default-copy semantics#7786

Merged
charliermarsh merged 1 commit intomainfrom
charlie/msgspec
Oct 3, 2023
Merged

Respect msgspec.Struct default-copy semantics#7786
charliermarsh merged 1 commit intomainfrom
charlie/msgspec

Conversation

@charliermarsh
Copy link
Member

Summary

The carve-out we have in RUF012 for Pydantic classes also applies to msgspec.Struct.

Closes #7785.

@charliermarsh charliermarsh changed the title Respect msgspec.Struct's default-copy semantics Respect msgspec.Struct default-copy semantics Oct 3, 2023
@charliermarsh charliermarsh added the bug Something isn't working label Oct 3, 2023
@jcrist
Copy link

jcrist commented Oct 3, 2023

Thanks for the fix!

@charliermarsh charliermarsh enabled auto-merge (squash) October 3, 2023 16:42
@charliermarsh charliermarsh merged commit 90c259b into main Oct 3, 2023
@charliermarsh charliermarsh deleted the charlie/msgspec branch October 3, 2023 16:51
@github-actions
Copy link
Contributor

github-actions bot commented Oct 3, 2023

PR Check Results

Ecosystem

✅ ecosystem check detected no changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

False RUF012 on empty mutable collections as default values in msgspec.Structs

2 participants