Skip to content

gh-148398: add type watcher in _CHECK_ATTR_CLASS#148399

Merged
Fidget-Spinner merged 4 commits intopython:mainfrom
NekoAsakura:gh-148398/add-type-watcher
Apr 12, 2026
Merged

gh-148398: add type watcher in _CHECK_ATTR_CLASS#148399
Fidget-Spinner merged 4 commits intopython:mainfrom
NekoAsakura:gh-148398/add-type-watcher

Conversation

@NekoAsakura
Copy link
Copy Markdown
Contributor

@NekoAsakura NekoAsakura commented Apr 11, 2026

@Fidget-Spinner
Copy link
Copy Markdown
Member

I'm not sure whether this went out in an alpha. If it did you probably need a shorts news entry about fixing a bug.

@NekoAsakura
Copy link
Copy Markdown
Contributor Author

Yes, it's been in since a1. I will write it.

}
else {
sym_set_const(owner, type);
PyType_Watch(TYPE_WATCHER_ID, type);
Copy link
Copy Markdown
Contributor

@kumaraditya303 kumaraditya303 Apr 12, 2026

Choose a reason for hiding this comment

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

You don't need to add type watcher if type is immutable.

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.

Ref #148383

@Fidget-Spinner Fidget-Spinner merged commit 30c698a into python:main Apr 12, 2026
76 checks passed
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