-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Make sure inspect.iscoroutinefunction works on coroutines decorated with @validate_call
#10374
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
Conversation
|
@sydney-runkle , please review. |
CodSpeed Performance ReportMerging #10374 will not alter performanceComparing Summary
|
Coverage reportClick to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, could you please add a test as well? Thanks!
I don't quite understand what changes need to be made to the test cases. I add some codes to check if it is a coroutine the async function under decorator. Please check it, thank you! |
Something like: import inspect
@validate_call
async def test():
pass
assert inspect.iscoroutinefunction(test) |
inspect.iscoroutinefunction works on coroutines decorated with @validate_call
|
Happy to do another review here after we:
currently: desired: Thanks, great work here! |
|
@Viicos @sydney-runkle I finish all @sydney-runkle mentioned. Please check it, thank you! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome job, thanks for the help here!!
Change Summary
Add judgement for validate_call decorator. Now we can get
Truereturn frominpect.iscoroutinefunction().Related issue number
fix #10370
Checklist
Selected Reviewer: @sydney-runkle