-
-
Notifications
You must be signed in to change notification settings - Fork 288
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
Bugfix: async curl timer leak (Suppress Pending Task Messages During Shutdown) #245
Conversation
…out checker to finish)
Problem with checks:
These checks cannot be completed and are canceled after 6 hours. |
@yifeikong |
Hi @deedy5, have you finished your PR? |
@yifeikong |
@yifeikong Hi. Can you release a new beta version with this change? |
I'll be releasing 0.6 soon, probably tomorrow. |
0.6.0 was released. |
The A new release(0.6.1) was published to address this issue, you may need to adjust your code accordingly. |
Reason:
Sometimes there are messages like this one:
Description:
This PR addresses the issue of warning messages being logged when the AsyncCurl object is closed. Specifically, it resolves the "Task was destroyed but it is pending!" warnings that occur when the _checker task is cancelled.
Changes Made:
Modified close method: added a try/except block to catch and ignore asyncio.CancelledError when cancelling the _checker task. This prevents the warning message from being logged.
These changes ensure that the _checker task is cancelled gracefully, and the cancellation is confirmed before continuing with the cleanup process. This should eliminate the warning messages related to pending tasks during object closure.