Skip to content

Commit

Permalink
fix(api): ignore missing aionotify more properly (#8154)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrakitin authored Jul 23, 2021
1 parent d9c7ed2 commit bb0e3a0
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion api/src/opentrons/hardware_control/controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from typing_extensions import Final
try:
import aionotify # type: ignore
except OSError:
except (OSError, ModuleNotFoundError):
aionotify = None # type: ignore

from opentrons.drivers.smoothie_drivers import driver_3_0
Expand Down
2 changes: 1 addition & 1 deletion api/tests/opentrons/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

try:
import aionotify
except OSError:
except (OSError, ModuleNotFoundError):
aionotify = None # type: ignore
import asyncio
import os
Expand Down
2 changes: 1 addition & 1 deletion api/tests/opentrons/hardware_control/test_instruments.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from unittest import mock
try:
import aionotify
except OSError:
except (OSError, ModuleNotFoundError):
aionotify = None # type: ignore
import pytest
import typeguard
Expand Down
4 changes: 0 additions & 4 deletions api/tests/opentrons/hardware_control/test_modules.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
from pathlib import Path
from unittest import mock
import pytest
try:
import aionotify
except OSError:
aionotify = None # type: ignore
from opentrons.hardware_control import ExecutionManager
from opentrons.hardware_control.modules import ModuleAtPort
from opentrons.hardware_control.modules.types import (
Expand Down

0 comments on commit bb0e3a0

Please sign in to comment.