Skip to content

Commit

Permalink
Fix win32 assert
Browse files Browse the repository at this point in the history
  • Loading branch information
WillB97 committed Apr 6, 2024
1 parent 273d453 commit 0606da1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions april_vision/detect_cameras.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,9 @@ def windows_discovery() -> List[CameraIdentifier]:
"""
import asyncio

assert sys.platform != 'win32', "This method is only for Windows"
assert sys.platform == 'win32', "This method is only for Windows"

import winsdk.windows.devices.enumeration as windows_devices # type: ignore[import, unused-ignore] # noqa: E501
import winsdk.windows.devices.enumeration as windows_devices # type: ignore[import-not-found,unused-ignore]

async def get_camera_info(): # type: ignore
device_class = windows_devices.DeviceClass.VIDEO_CAPTURE
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies = [
dev = [
"poethepoet >=0.0.1,<1",
"ruff >=0.3.0,<0.4",
"mypy",
"mypy==1.9.0",
"build",
"types-Pillow",
"types-tabulate",
Expand Down

0 comments on commit 0606da1

Please sign in to comment.