-
-
Notifications
You must be signed in to change notification settings - Fork 30.8k
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
bpo-34148: Dont log exception traceback when TimeoutError is occurred in asyncio transports #11576
Conversation
Sorry I don't have the bandwidth to review this change. @1st1 maybe? |
A couple word to the context: we have a list of expected exceptions like We've added certificate errors to the expected list during the last core devs sprint, Sure, @1st1 is familiar with it; I guess |
Edit: just saw the previous comment (sorry, typing this on my phone, and the GH is harder to use) That said i'm still not sure we should mask timeouts from logging. |
The long story is: in aiohttp bug tracker I had reports about Now I'm sure that it is a network behavior. TCP keepalive ( There is no reason to log timeout errors, user code still receives the exception in
This is a very good question actually. As I said exceptions are passed into the user-side callback. Usually, I use logging for reporting about warnings etc., in other words for cases when I cannot raise an exception (function call should proceed successfully) but want to inform a caller about something. We have the logging in asyncio for now. It served an important role: give us usage feedback. But after collecting more experience I'm inclining to drop the logging. If we decide to keep it -- let's don't log P.S. |
@1st1 I think |
Superseded by #13548 |
The exception is normal behavior,
ETIMEDOUT
can be set by NAT gateways and IP bridge hardware for example.https://bugs.python.org/issue34148