mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-python
synced 2026-01-15 09:53:32 +01:00
Add Process and Signals support
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
6123a68195
commit
c96ffe52c0
6 changed files with 139 additions and 0 deletions
10
tools/python/jwutils/asyncio/Signals.py
Normal file
10
tools/python/jwutils/asyncio/Signals.py
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
import asyncio
|
||||
from ..Signals import Signals as SignalsBase
|
||||
|
||||
class Signals(SignalsBase):
|
||||
|
||||
# reimplemented from Signals
|
||||
@classmethod
|
||||
def _add_handler(cls, signal, handler):
|
||||
loop = asyncio.get_running_loop()
|
||||
loop.add_signal_handler(signal, handler, None) # None = *args
|
||||
Loading…
Add table
Add a link
Reference in a new issue