forked from Github/frigate
Typing Part 3: events.py (#3352)
* Typing: events.py * Remove unused variable * Fix return Any from return statement Not all elements from the event dict are sure to be something that can be evaluated See e.g.: https://github.com/python/mypy/issues/5697 * Sort out Event disambiguity There was a name collision of multiprocessing Event type and frigate events Co-authored-by: Sebastian Englbrecht <sebastian.englbrecht@kabelmail.de>
This commit is contained in:
@@ -7,13 +7,13 @@ import signal
|
||||
|
||||
from frigate.object_detection import ObjectDetectProcess
|
||||
from frigate.util import restart_frigate
|
||||
from multiprocessing.synchronize import Event
|
||||
from multiprocessing.synchronize import Event as MpEvent
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class FrigateWatchdog(threading.Thread):
|
||||
def __init__(self, detectors: dict[str, ObjectDetectProcess], stop_event: Event):
|
||||
def __init__(self, detectors: dict[str, ObjectDetectProcess], stop_event: MpEvent):
|
||||
threading.Thread.__init__(self)
|
||||
self.name = "frigate_watchdog"
|
||||
self.detectors = detectors
|
||||
|
||||
Reference in New Issue
Block a user