You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
bazarr/libs/engineio/async_drivers/threading.py

20 lines
463 B

import queue
5 years ago
import threading
import time
from engineio.async_drivers._websocket_wsgi import SimpleWebSocketWSGI
5 years ago
class DaemonThread(threading.Thread): # pragma: no cover
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs, daemon=True)
5 years ago
_async = {
'thread': DaemonThread,
5 years ago
'queue': queue.Queue,
'queue_empty': queue.Empty,
'event': threading.Event,
'websocket': SimpleWebSocketWSGI,
5 years ago
'sleep': time.sleep,
}