Skip to content

Commit

Permalink
cast Version
Browse files Browse the repository at this point in the history
  • Loading branch information
vegano1 committed Aug 6, 2024
1 parent 477d385 commit cf0a67c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/src/opentrons/hardware_control/modules/mod_abc.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import asyncio
import logging
import re
from typing import ClassVar, Mapping, Optional, TypeVar
from typing import ClassVar, Mapping, Optional, TypeVar, cast
from packaging.version import InvalidVersion, parse, Version
from opentrons.config import IS_ROBOT, ROBOT_FIRMWARE_DIR
from opentrons.drivers.rpi_drivers.types import USBPort
Expand Down Expand Up @@ -31,7 +31,7 @@ def parse_fw_version(version: str) -> Version:
raise InvalidVersion()
except InvalidVersion:
device_version = parse("v0.0.0")
return device_version
return cast(Version, device_version)


class AbstractModule(abc.ABC):
Expand Down

0 comments on commit cf0a67c

Please sign in to comment.