gh-103272: add regression test for getattr that raises#103336
Conversation
|
Most changes to Python require a NEWS entry. Please add it using the blurb_it web app or the blurb command-line tool. |
Sorry, something went wrong.
There was a problem hiding this comment.
Awesome work, thanks for narrowing this down!
I think we can make the test case slightly simpler to make it clearer what's getting tested:
class A:
def __getattr__(self, name):
raise ValueError
@property
def foo(self):
return self.__getattr__("asdf")
A().foo
And maybe rename the test to test_getattr_raises or something
Sorry, something went wrong.
|
I've got the revert merged, now this test must pass :) |
Sorry, something went wrong.
sobolevn
left a comment
There was a problem hiding this comment.
Thank you!
Sorry, something went wrong.
sobolevn
left a comment
There was a problem hiding this comment.
Congrats on your first CPython PR 🎉
Sorry, something went wrong.
hauntsaninja
left a comment
There was a problem hiding this comment.
Thanks again, this is great!
Sorry, something went wrong.
|
Thanks @sunmy2019 for the PR, and @hauntsaninja for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11. |
Sorry, something went wrong.
…ythonGH-103336) (cherry picked from commit 5d7d86f) Co-authored-by: sunmy2019 <59365878+sunmy2019@users.noreply.github.com>
Add test case taken from gh-103272 for #103332.