chore(style): update mypy config (#2257)

* chore(style): update mypy config

* fix(cameras): mypy check
This commit is contained in:
Steven Palma
2025-10-20 16:25:03 +02:00
committed by GitHub
parent aa1d906802
commit 9db6213895
2 changed files with 7 additions and 8 deletions
@@ -244,6 +244,10 @@ class OpenCVCamera(Camera):
"""Validates and sets the camera's FOURCC code."""
fourcc_code = cv2.VideoWriter_fourcc(*self.config.fourcc)
if self.videocapture is None:
raise DeviceNotConnectedError(f"{self} videocapture is not initialized")
success = self.videocapture.set(cv2.CAP_PROP_FOURCC, fourcc_code)
actual_fourcc_code = self.videocapture.get(cv2.CAP_PROP_FOURCC)