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

replace socket.timeout on py3.10+ and asyncio.TimeoutError/concurrent.futures.TimeoutError on py3.11+ with TimeoutError #819

Open
graingert opened this issue May 4, 2023 · 1 comment

Comments

@graingert
Copy link
Contributor

There are now a number of deprecated aliases for TimeoutError:

https://docs.python.org/3/library/socket.html#socket.timeout

Changed in version 3.10: This class was made an alias of TimeoutError.

https://docs.python.org/3/library/asyncio-exceptions.html#asyncio.TimeoutError

Changed in version 3.11: This class was made an alias of TimeoutError.

https://docs.python.org/3/library/concurrent.futures.html#concurrent.futures.TimeoutError

Changed in version 3.11: This class was made an alias of TimeoutError.

lancelote added a commit to lancelote/pyupgrade that referenced this issue May 13, 2023
* socket.timeout 3.10+
* asyncio.TimeoutError 3.11+
* concurrent.futures.TimeoutError 3.11+
@asottile
Copy link
Owner

#885 handles everything except for concurrent.futures.TimeoutError

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

No branches or pull requests

2 participants