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

Fix detail::obj_class_name() to work correctly for meta classes. #4436

Merged
merged 2 commits into from Jan 2, 2023

Conversation

rwgk
Copy link
Collaborator

@rwgk rwgk commented Jan 1, 2023

Description

Port of fix here: google/clif@ef64abf

The fix was suggested by @lalaland (#4427 (comment)) and confirmed to be correct by @Yhg1s.

Note that the new test in test_class.py fails without this change.

Suggested changelog entry:

@rwgk
Copy link
Collaborator Author

rwgk commented Jan 2, 2023

@mattip FYI: aa68c64

Is that a known difference between cpython and PyPy?

@rwgk rwgk marked this pull request as ready for review January 2, 2023 03:16
@rwgk
Copy link
Collaborator Author

rwgk commented Jan 2, 2023

I'm working on the clang10 C++20 issue under #4438. Ignoring here.

@rwgk rwgk merged commit f12e098 into pybind:master Jan 2, 2023
@rwgk rwgk deleted the obj_class_name_fix branch January 2, 2023 11:46
@github-actions github-actions bot added the needs changelog Possibly needs a changelog entry label Jan 2, 2023
@mattip
Copy link

mattip commented Jan 2, 2023

Is that a known difference between cpython and PyPy?

I guess so. Someday I intend to track this down. When I tried to fix it before I broke pickling of c-extension modules. See the pypy issue.

henryiii pushed a commit that referenced this pull request Jan 3, 2023
…4436)

* Fix `detail::obj_class_name()` to work correctly for meta classes.

* Adjust expected name for PyPy
@henryiii henryiii removed the needs changelog Possibly needs a changelog entry label Jan 3, 2023
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.

None yet

4 participants