pylabrobot.opentrons.flex.flex_gripper.FlexGripper.move_labware#

async FlexGripper.move_labware(resource: Resource, to_slot: str, grip_distance_from_top: float | None = None) → None#

Move resource from its current deck slot to to_slot with the gripper.

Validates PLR-side first (resource on deck, destination a valid empty slot), then sends ONE atomic moveLabware command. On wire success the deck is re-parented to match; on wire failure the deck is left untouched and the error propagates. Standard slots ride slotName; the column-4 staging slots A4-D4 are addressable areas server-side and ride addressableAreaName.

Parameters:
  • resource (Resource) – A resource currently placed on the deck.

  • to_slot (str) – Destination slot, e.g. "C2" (standard) or "B4" (staging).

  • grip_distance_from_top (float | None) – How far below the labware’s top the paddles grab (mm), baked into the grip height of a custom definition pylabrobot uploads. It therefore applies ONLY to labware pylabrobot uploads a definition for: a resource resolving to an official Opentrons load name (identity metadata set, a standard tip-rack name, or a name starting with opentrons_) loads the catalogue definition instead, whose grip height is the vendor’s to state – and when that definition states none, the robot grips at the labware’s mid-height rather than at this value. Honored on the labware’s FIRST load in the run only; once the robot holds a definition for it, later values are ignored too. Every ignored value is logged. None keeps the definition’s grip height (the robot’s mid-height default for custom definitions built without one).

Raises:

OpentronsError – If the resource is not on the deck, or to_slot is invalid or occupied. Raised before any wire command is sent.

Return type:

None