Skip to content

gh-150069: Test frozen dataclass and properties interaction - #150070

Merged
sobolevn merged 3 commits into
python:mainfrom
sobolevn:issue-150069
Jul 2, 2026
Merged

sobolevn merged 3 commits into
python:mainfrom
sobolevn:issue-150069

Conversation

@sobolevn

@sobolevn sobolevn commented May 19, 2026 •

Copy link
Copy Markdown
Member

Since #144021 was backported to 3.13, I also mark my PR with the same backports.

@sobolevn

Copy link
Copy Markdown
Member Author

@carljm @ericvsmith friendly ping 👋

@carljm carljm left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks fine to me, comments are nits.

Comment thread Lib/test/test_dataclasses/__init__.py Resolved
Comment thread Lib/test/test_dataclasses/__init__.py Resolved
Comment thread Lib/test/test_dataclasses/__init__.py Resolved
with self.assertRaises(FrozenInstanceError):
d.i = 5

def test_non_frozen_normal_derived(self):

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This test is now quite large and checking quite a few only loosely related behaviors. Not a blocker but might be ideal to break it up.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I thought about it, but I don't see a clean way to do that :(
It is rather big, but pretty clear. So, I decided to keep it as-is :)

@sobolevn

sobolevn commented Jul 2, 2026

Copy link
Copy Markdown
Member Author

@carljm thanks a lot for your feedback, I updated my test with your suggestions and scheduled it to be merged :)

@sobolevn
sobolevn enabled auto-merge (squash) July 2, 2026 12:20
@sobolevn
sobolevn merged commit 753f82d into python:main Jul 2, 2026
44 checks passed
@miss-islington-app

Copy link
Copy Markdown

Thanks @sobolevn for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14, 3.15.
🐍🍒⛏🤖

@bedevere-app

bedevere-app Bot commented Jul 2, 2026

Copy link
Copy Markdown

GH-152882 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Jul 2, 2026
@miss-islington-app

Copy link
Copy Markdown

Sorry, @sobolevn, I could not cleanly backport this to 3.13 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 753f82db2fed38bf725ded2b333ea3749c81fe82 3.13
@bedevere-app

bedevere-app Bot commented Jul 2, 2026

Copy link
Copy Markdown

GH-152883 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Jul 2, 2026
@bedevere-app

bedevere-app Bot commented Jul 2, 2026

Copy link
Copy Markdown

GH-152887 is a backport of this pull request to the 3.13 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.13 only security fixes label Jul 2, 2026
sobolevn added a commit that referenced this pull request Jul 2, 2026
…H-150070) (#152883)

gh-150069: Test frozen dataclass and properties interaction (GH-150070)
(cherry picked from commit 753f82d)

Co-authored-by: sobolevn <mail@sobolevn.me>
sobolevn added a commit that referenced this pull request Jul 2, 2026
…H-150070) (#152882)

gh-150069: Test frozen dataclass and properties interaction (GH-150070)
(cherry picked from commit 753f82d)

Co-authored-by: sobolevn <mail@sobolevn.me>
sobolevn added a commit that referenced this pull request Jul 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

2 participants