diff options
author | Andrew Svetlov <andrew.svetlov@gmail.com> | 2018-01-19 18:04:29 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-19 18:04:29 (GMT) |
commit | 7464e87a6511d3626b04c9833a262a77b1f21e23 (patch) | |
tree | 4d7bc17260536bd3d91902b521cbf30957cdc1c8 /Lib/asyncio/events.py | |
parent | 2507e29a9e4e9dcac6eab46546bd3d34a69342ba (diff) | |
download | cpython-7464e87a6511d3626b04c9833a262a77b1f21e23.zip cpython-7464e87a6511d3626b04c9833a262a77b1f21e23.tar.gz cpython-7464e87a6511d3626b04c9833a262a77b1f21e23.tar.bz2 |
bpo-32410: Make SendfileNotAvailableError exception public (#5243)
Diffstat (limited to 'Lib/asyncio/events.py')
-rw-r--r-- | Lib/asyncio/events.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Lib/asyncio/events.py b/Lib/asyncio/events.py index b06721f..d5365dc 100644 --- a/Lib/asyncio/events.py +++ b/Lib/asyncio/events.py @@ -3,7 +3,7 @@ __all__ = ( 'AbstractEventLoopPolicy', 'AbstractEventLoop', 'AbstractServer', - 'Handle', 'TimerHandle', + 'Handle', 'TimerHandle', 'SendfileNotAvailableError', 'get_event_loop_policy', 'set_event_loop_policy', 'get_event_loop', 'set_event_loop', 'new_event_loop', 'get_child_watcher', 'set_child_watcher', @@ -20,6 +20,14 @@ import threading from . import format_helpers +class SendfileNotAvailableError(RuntimeError): + """Sendfile syscall is not available. + + Raised if OS does not support senfile syscall for given socket or + file type. + """ + + class Handle: """Object returned by callback registration methods.""" |