diff --git a/api/src/opentrons/hardware_control/backends/flex_protocol.py b/api/src/opentrons/hardware_control/backends/flex_protocol.py index 05c416f20ba..4a7e28dc28b 100644 --- a/api/src/opentrons/hardware_control/backends/flex_protocol.py +++ b/api/src/opentrons/hardware_control/backends/flex_protocol.py @@ -396,3 +396,6 @@ def get_estop_state(self) -> EstopState: def add_estop_callback(self, cb: HardwareEventHandler) -> HardwareEventUnsubscriber: ... + + def _update_tip_state(self, mount: OT3Mount, status: bool) -> None: + ... diff --git a/api/src/opentrons/protocol_api/instrument_context.py b/api/src/opentrons/protocol_api/instrument_context.py index 70a6132041e..dd2db1bfb44 100644 --- a/api/src/opentrons/protocol_api/instrument_context.py +++ b/api/src/opentrons/protocol_api/instrument_context.py @@ -1458,7 +1458,7 @@ def _retract( ) -> None: self._core.retract() - @property # type: ignore + @property @requires_version(2, 0) def mount(self) -> str: """ diff --git a/hardware-testing/hardware_testing/gravimetric/__main__.py b/hardware-testing/hardware_testing/gravimetric/__main__.py index f5e525131ab..d2b0f8e92c5 100644 --- a/hardware-testing/hardware_testing/gravimetric/__main__.py +++ b/hardware-testing/hardware_testing/gravimetric/__main__.py @@ -186,8 +186,8 @@ def _get_protocol_context(cls, args: argparse.Namespace) -> ProtocolContext: engine.state_view._labware_store._add_labware_offset(offset) return _ctx - @classmethod # noqa: C901 - def build_run_args(cls, args: argparse.Namespace) -> "RunArgs": + @classmethod + def build_run_args(cls, args: argparse.Namespace) -> "RunArgs": # noqa: C901 """Build.""" _ctx = RunArgs._get_protocol_context(args) operator_name = helpers._get_operator_name(_ctx.is_simulating()) diff --git a/hardware-testing/hardware_testing/gravimetric/helpers.py b/hardware-testing/hardware_testing/gravimetric/helpers.py index 9b6878d65f1..6ee5acccce6 100644 --- a/hardware-testing/hardware_testing/gravimetric/helpers.py +++ b/hardware-testing/hardware_testing/gravimetric/helpers.py @@ -40,6 +40,8 @@ WellLocation, DropTipWellLocation, ) + + def _add_fake_simulate( ctx: protocol_api.ProtocolContext, is_simulating: bool ) -> protocol_api.ProtocolContext: @@ -233,10 +235,13 @@ def _override_add_current_volume(self, volume_incr: float) -> None: # noqa: ANN def _override_ok_to_add_volume(self, volume_incr: float) -> bool: # noqa: ANN001 return True -def _override_validate_aspirate_volume(state_view: StateView, pipette_id: str, aspirate_volume: float + +def _override_validate_asp_vol( + state_view: StateView, pipette_id: str, aspirate_volume: float ) -> float: return aspirate_volume + def _override_check_deck_conflict_for_8_channel( engine_state: StateView, pipette_id: str, @@ -246,6 +251,7 @@ def _override_check_deck_conflict_for_8_channel( ) -> None: return None + def _override_software_supports_high_volumes() -> None: # yea so ok this is pretty ugly but this is super helpful for us # with this we don't need to apply patches, and can run the testing scripts @@ -254,8 +260,11 @@ def _override_software_supports_high_volumes() -> None: Pipette.set_current_volume = _override_set_current_volume # type: ignore[assignment] Pipette.ok_to_add_volume = _override_ok_to_add_volume # type: ignore[assignment] Pipette.add_current_volume = _override_add_current_volume # type: ignore[assignment] - PE_pipetting._validate_aspirate_volume = _override_validate_aspirate_volume # type: ignore[assignment] - PE_deck_conflict._check_deck_conflict_for_8_channel = _override_check_deck_conflict_for_8_channel # type: ignore[assignment] + PE_pipetting._validate_aspirate_volume = _override_validate_asp_vol # type: ignore[assignment] + PE_deck_conflict._check_deck_conflict_for_8_channel = ( + _override_check_deck_conflict_for_8_channel + ) # type: ignore[assignment] + def _get_channel_offset(cfg: config.VolumetricConfig, channel: int) -> Point: assert ( @@ -337,9 +346,12 @@ def _drop_tip( pipette.return_tip(home_after=False) else: if offset is not None: - #we don't actually need the offset, if this is an 8 channel we always center channel a1 over the back of the trash - trash_well = pipette.trash_container.well(0) - trash_container = trash_well.center().move(Point(0,trash_well.width/2,0)) + # we don't actually need the offset, if this is an 8 channel we always center channel + # a1 over the back of the trash + trash_well = pipette.trash_container.well(0) # type: ignore[union-attr] + trash_container = trash_well.center().move( + Point(0, trash_well.width / 2, 0) # type: ignore[union-attr, operator] + ) pipette.drop_tip( trash_container, home_after=False,