Skip to content

Commit

Permalink
Make cache_tip() overwrite any existing tip.
Browse files Browse the repository at this point in the history
  • Loading branch information
SyntaxColoring committed Oct 23, 2024
1 parent 1f9bbff commit 0cb1605
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,9 @@ def add_tip(self, mount: MountType, tip_length: float) -> None:

def cache_tip(self, mount: MountType, tip_length: float) -> None:
instrument = self.get_pipette(mount)
if instrument.has_tip:
# instrument.add_tip() would raise an AssertionError if we tried to overwrite an existing tip.
instrument.remove_tip()
instrument.add_tip(tip_length=tip_length)
instrument.set_current_volume(0)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,9 @@ def add_tip(self, mount: OT3Mount, tip_length: float) -> None:

def cache_tip(self, mount: OT3Mount, tip_length: float) -> None:
instrument = self.get_pipette(mount)

if instrument.has_tip:
# instrument.add_tip() would raise an AssertionError if we tried to overwrite an existing tip.
instrument.remove_tip()
instrument.add_tip(tip_length=tip_length)
instrument.set_current_volume(0)

Expand Down

0 comments on commit 0cb1605

Please sign in to comment.