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

Add supporting for async callable object #5506

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

sviat9440
Copy link

No description provided.

@codecov
Copy link

codecov bot commented Oct 17, 2022

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (cf73051) 100.00% compared to head (3d0072e) 100.00%.
Report is 1074 commits behind head on master.

❗ Current head 3d0072e differs from pull request most recent head 7bc17f0. Consider uploading reports for the commit 7bc17f0 to get more accurate results

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #5506   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          540       540           
  Lines        13969     13967    -2     
=========================================
- Hits         13969     13967    -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions
Copy link
Contributor

📝 Docs preview for commit 3d0072e at: https://634d4461e3a2ec1d01feb169--fastapi.netlify.app

@sviat9440 sviat9440 changed the title Add supporting for callable object Add supporting for async callable object Oct 17, 2022
@sviat9440
Copy link
Author

What are the next steps?

Comment on lines +266 to +272
def is_coroutine_function(obj: Any) -> bool:
while isinstance(obj, functools.partial):
obj = obj.func

return asyncio.iscoroutinefunction(obj) or (
callable(obj) and asyncio.iscoroutinefunction(obj.__call__)
)
Copy link
Sponsor Collaborator

Choose a reason for hiding this comment

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

Copy link
Author

@sviat9440 sviat9440 Oct 19, 2022

Choose a reason for hiding this comment

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

image
Ignore it?

Copy link
Author

Choose a reason for hiding this comment

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

Copy link
Sponsor Collaborator

Choose a reason for hiding this comment

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

yes, ignore it.

@sviat9440 sviat9440 requested a review from Kludex October 23, 2022 05:33
@Kludex
Copy link
Sponsor Collaborator

Kludex commented Oct 23, 2022

The next step is to wait for Sebastián to review it. 🙏

@sviat9440
Copy link
Author

@tiangolo @Kludex @iudeen any progress?

@sviat9440
Copy link
Author

...

@sviat9440
Copy link
Author

Is the project dead?

@Kludex
Copy link
Sponsor Collaborator

Kludex commented Jul 17, 2023

Nop.

@Kludex
Copy link
Sponsor Collaborator

Kludex commented Jul 17, 2023

I'll review tomorrow.

Comment on lines +266 to +272
def is_coroutine_function(obj: Any) -> bool:
while isinstance(obj, functools.partial):
obj = obj.func

return asyncio.iscoroutinefunction(obj) or (
callable(obj) and asyncio.iscoroutinefunction(obj.__call__)
)
Copy link
Sponsor Collaborator

Choose a reason for hiding this comment

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

yes, ignore it.

@alejsdev alejsdev added feature New feature or request p3 and removed hacktoberfest-accepted investigate labels Jan 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request p3
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants