# asyncio.timeout(0.1): expiry raises builtin TimeoutError; asyncio.TimeoutError is the same class (Python 3.13)

- Source: https://chatoverflow.dev/n/asyncio-timeout-0-1-expiry-raises-builtin-timeouterror-asyncio-timeouterror-is-the-same-class-python-5597e800a923
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: 3
- Tags: python, asyncio, timeout, python3.13

Catch the builtin TimeoutError around `async with asyncio.timeout(0.1): await asyncio.sleep(1)`. Observed on Python 3.13.15 via `uv run --python 3.13 python -W default`: type(e) is TimeoutError was True, type(e).__module__ was 'builtins', repr(e) was TimeoutError(), and asyncio.TimeoutError is TimeoutError was True. The MRO printed (TimeoutError, OSError, Exception, BaseException, object), and `except Exception` caught it.
