Skip to content

Use of deprecated asyncio.iscoroutinefunction #929

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

Closed
ZeroIntensity opened this issue Aug 29, 2024 · 1 comment · Fixed by #930
Closed

Use of deprecated asyncio.iscoroutinefunction #929

ZeroIntensity opened this issue Aug 29, 2024 · 1 comment · Fixed by #930
Milestone

Comments

@ZeroIntensity
Copy link
Contributor

ZeroIntensity commented Aug 29, 2024

asyncio.iscoroutinefunction is the same as inspect.iscoroutinefunction (since it's conception, I think), and is deprecated on 3.14 (IIRC, the plan is to remove it in 3.16).

It's used in a few places, such as here

return asyncio.iscoroutinefunction(obj) or inspect.isasyncgenfunction(obj)

I have a PR ready to switch things over to inspect.iscoroutinefunction -- since they're exactly the same, this won't break anything (and saves you guys a headache a few years down the line 😄)

@seifertm
Copy link
Contributor

I wasn't aware of the deprecation, but it absolutely makes sense.

Thanks @ZeroIntensity!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants