mirror of
https://github.com/blakeblackshear/frigate.git
synced 2024-11-21 19:07:46 +01:00
Lower onvif timeouts to 10s (#13473)
This commit is contained in:
parent
ecaba82c9d
commit
e3da5ef2d5
@ -8,6 +8,7 @@ from pathlib import Path
|
||||
import numpy
|
||||
from onvif import ONVIFCamera, ONVIFError
|
||||
from zeep.exceptions import Fault, TransportError
|
||||
from zeep.transports import Transport
|
||||
|
||||
from frigate.config import FrigateConfig, ZoomingModeEnum
|
||||
from frigate.types import PTZMetricsTypes
|
||||
@ -45,6 +46,7 @@ class OnvifController:
|
||||
|
||||
if cam.onvif.host:
|
||||
try:
|
||||
transport = Transport(timeout=10, operation_timeout=10)
|
||||
self.cams[cam_name] = {
|
||||
"onvif": ONVIFCamera(
|
||||
cam.onvif.host,
|
||||
@ -55,6 +57,7 @@ class OnvifController:
|
||||
Path(find_spec("onvif").origin).parent / "wsdl"
|
||||
).replace("dist-packages/onvif", "site-packages"),
|
||||
adjust_time=cam.onvif.ignore_time_mismatch,
|
||||
transport=transport,
|
||||
),
|
||||
"init": False,
|
||||
"active": False,
|
||||
|
Loading…
Reference in New Issue
Block a user