Make sure inspect.iscoroutinefunction works on coroutines decorated with @validate_call#10374
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 |
||||||||||||||||||||||||
sydney-runkle
left a comment
There was a problem hiding this comment.
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! |
sydney-runkle
left a comment
There was a problem hiding this comment.
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