Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(api): clean up labware movement error strings #13198

Merged
merged 2 commits into from
Aug 1, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ async def move_labware_with_gripper(
return
ot3api = ensure_ot3_hardware(
hardware_api=self._hardware_api,
error_msg="Gripper is only available on the OT-3",
error_msg="Gripper is only available on Opentrons Flex",
)

if not ot3api.has_gripper():
Expand Down Expand Up @@ -230,7 +230,7 @@ def ensure_valid_gripper_location(
location, (DeckSlotLocation, ModuleLocation, OnLabwareLocation)
):
raise LabwareMovementNotAllowedError(
"Off-deck labware movements are not supported using the gripper."
"Cannot move labware off-deck using the gripper."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This string is used when the source location is off-deck, as well.

"Cannot move labware to or from off-deck using the gripper"? :\

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kinda just discovered off-deck -> on-deck movements today 😅
Going with Cannot perform off-deck labware movements with the gripper.

)
return location

Expand Down Expand Up @@ -260,10 +260,10 @@ async def ensure_movement_not_obstructed_by_module(
)
except ThermocyclerNotOpenError:
raise LabwareMovementNotAllowedError(
"Cannot move labware from/to a thermocycler with closed lid."
"Cannot move labware to or from a Thermocycler with its lid closed."
)
except HeaterShakerLabwareLatchNotOpenError:
raise LabwareMovementNotAllowedError(
"Cannot move labware from/to a heater-shaker"
"Cannot move labware to or from a Heater-Shaker"
" with its labware latch closed."
)