From c657d538e1d5cbcb773019212f16e99b8ece5486 Mon Sep 17 00:00:00 2001 From: Rick Wierenga Date: Tue, 22 Oct 2024 17:25:42 -0700 Subject: [PATCH] deprecate _L and _P in resource definitions (#288) --- CHANGELOG.md | 5 +- docs/user_guide/basic.ipynb | 6 +- docs/user_guide/moving-channels-around.ipynb | 4 +- docs/user_guide/using-the-visualizer.ipynb | 12 +- docs/user_guide/using-trackers.ipynb | 8 +- pylabrobot/gui/gui.py | 52 ++--- .../backends/chatterbox_tests.py | 4 +- .../backends/hamilton/STAR_tests.py | 14 +- .../backends/hamilton/vantage_tests.py | 8 +- .../liquid_handling/backends/http_tests.py | 4 +- .../backends/serializing_backend_tests.py | 4 +- .../liquid_handling/liquid_handler_tests.py | 24 +-- pylabrobot/resources/azenta/plates.py | 12 +- pylabrobot/resources/carrier.py | 4 +- pylabrobot/resources/corning_axygen/plates.py | 8 +- pylabrobot/resources/corning_costar/plates.py | 23 ++- pylabrobot/resources/eppendorf/plates.py | 11 +- .../resources/hamilton/hamilton_deck_tests.py | 10 +- .../resources/hamilton/hamilton_decks.py | 2 +- pylabrobot/resources/ml_star/tip_racks.py | 194 +++++++++++++----- pylabrobot/resources/porvair/plates.py | 10 +- pylabrobot/resources/tecan/tecan_decks.py | 12 +- pylabrobot/resources/thermo_fisher/plates.py | 21 +- .../server/liquid_handling_api_tests.py | 4 +- 24 files changed, 292 insertions(+), 164 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8e8ca53105..115963aae4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -59,14 +59,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). - `Thermo_TS_96_wellplate_1200ul_Rb` (https://github.com/PyLabRobot/pylabrobot/pull/215) - `Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate` (https://github.com/PyLabRobot/pylabrobot/pull/215) - `adapter_hole_size_z` and `plate_z_offset` parameters to `PlateAdapter` (https://github.com/PyLabRobot/pylabrobot/pull/215) -- `wide_high_volume_tip_with_filter` and `HTF_L_WIDE` (https://github.com/PyLabRobot/pylabrobot/pull/222) +- `wide_high_volume_tip_with_filter` and `HTF_WIDE` (https://github.com/PyLabRobot/pylabrobot/pull/222) - Serialize code cells and closures (https://github.com/PyLabRobot/pylabrobot/pull/220) - `Container.get_anchor()` now supports `"cavity_bottom"` as an argument for `z` (https://github.com/PyLabRobot/pylabrobot/pull/205/) - `pylabrobot.resources.utils.query` for basic querying (https://github.com/PyLabRobot/pylabrobot/commit/4a07f6a32a9a33d0370eb9c29015567c98aea002) - `HamiltonLiquidHandler.allow_firmware_planning` to allow STAR/Vantage to plan complex liquid handling operations automatically (may break hardware agnosticity unexpectedly) (https://github.com/PyLabRobot/pylabrobot/pull/224) - `size_z` and `nesting_z_height` for `Cor_96_wellplate_360ul_Fb_Lid` (https://github.com/PyLabRobot/pylabrobot/pull/226) - `NestedTipRack` (https://github.com/PyLabRobot/pylabrobot/pull/228) -- `HTF_L_ULTRAWIDE`, `ultrawide_high_volume_tip_with_filter` (https://github.com/PyLabRobot/pylabrobot/pull/229/) +- `HTF_ULTRAWIDE`, `ultrawide_high_volume_tip_with_filter` (https://github.com/PyLabRobot/pylabrobot/pull/229/) - `get_absolute_size_x`, `get_absolute_size_y`, `get_absolute_size_z` for `Resource` (https://github.com/PyLabRobot/pylabrobot/pull/235) - `Cytation5Backend` for plate reading on BioTek Cytation 5 (https://github.com/PyLabRobot/pylabrobot/pull/238) - imaging (https://github.com/PyLabRobot/pylabrobot/pull/277) @@ -93,6 +93,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). - `ThermoScientific_96_DWP_1200ul_Rd` in favor of `Thermo_TS_96_wellplate_1200ul_Rb` (https://github.com/PyLabRobot/pylabrobot/pull/215) - `Azenta4titudeFrameStar_96_wellplate_skirted` in favor of `Azenta4titudeFrameStar_96_wellplate_200ul_Vb` (https://github.com/PyLabRobot/pylabrobot/pull/205/) - `Cos_96_DWP_2mL_Vb` in favor of `Cos_96_wellplate_2mL_Vb (https://github.com/PyLabRobot/pylabrobot/pull/205/)` +- Resource definitions with `_L` and `_P`, it is easy enough to use the stem and `.rotated(z=90)` for `_P` (https://github.com/PyLabRobot/pylabrobot/pull/288) ### Fixed diff --git a/docs/user_guide/basic.ipynb b/docs/user_guide/basic.ipynb index dcde4fd2fe..5d9b6e7a53 100644 --- a/docs/user_guide/basic.ipynb +++ b/docs/user_guide/basic.ipynb @@ -115,7 +115,7 @@ "- {class}`~pylabrobot.resources.ml_star.tip_carriers.TIP_CAR_480_A00` tip carrier\n", "- {class}`~pylabrobot.resources.ml_star.plate_carriers.PLT_CAR_L5AC_A00` plate carrier\n", "- {class}`~pylabrobot.resources.corning_costar.plates.Cor_96_wellplate_360ul_Fb` wells\n", - "- {class}`~pylabrobot.resources.ml_star.tip_racks.HTF_L` tips" + "- {class}`~pylabrobot.resources.ml_star.tip_racks.HTF` tips" ] }, { @@ -128,7 +128,7 @@ " TIP_CAR_480_A00,\n", " PLT_CAR_L5AC_A00,\n", " Cor_96_wellplate_360ul_Fb,\n", - " HTF_L,\n", + " HTF,\n", ")" ] }, @@ -146,7 +146,7 @@ "outputs": [], "source": [ "tip_car = TIP_CAR_480_A00(name=\"tip carrier\")\n", - "tip_car[0] = HTF_L(name=\"tips_01\")" + "tip_car[0] = HTF(name=\"tips_01\")" ] }, { diff --git a/docs/user_guide/moving-channels-around.ipynb b/docs/user_guide/moving-channels-around.ipynb index dec7ca2866..e6189abbb3 100644 --- a/docs/user_guide/moving-channels-around.ipynb +++ b/docs/user_guide/moving-channels-around.ipynb @@ -38,14 +38,14 @@ "outputs": [], "source": [ "from pylabrobot.liquid_handling import LiquidHandler, STAR\n", - "from pylabrobot.resources import STARDeck, TIP_CAR_480_A00, HTF_L\n", + "from pylabrobot.resources import STARDeck, TIP_CAR_480_A00, HTF\n", "\n", "lh = LiquidHandler(backend=STAR(), deck=STARDeck())\n", "await lh.setup()\n", "\n", "# assign a tip rack\n", "tip_carrier = TIP_CAR_480_A00(name=\"tip_carrier\")\n", - "tip_carrier[0] = tip_rack = HTF_L(name=\"tip_rack\")\n", + "tip_carrier[0] = tip_rack = HTF(name=\"tip_rack\")\n", "lh.deck.assign_child_resource(tip_carrier, rails=0)" ] }, diff --git a/docs/user_guide/using-the-visualizer.ipynb b/docs/user_guide/using-the-visualizer.ipynb index ec35050db4..6158a7eeb8 100644 --- a/docs/user_guide/using-the-visualizer.ipynb +++ b/docs/user_guide/using-the-visualizer.ipynb @@ -143,7 +143,7 @@ " TIP_CAR_480_A00,\n", " PLT_CAR_L5AC_A00,\n", " Cor_96_wellplate_360ul_Fb,\n", - " HTF_L\n", + " HTF\n", ")" ] }, @@ -155,11 +155,11 @@ "outputs": [], "source": [ "tip_car = TIP_CAR_480_A00(name='tip carrier')\n", - "tip_car[0] = tip_rack1 = HTF_L(name='tips_01', with_tips=False)\n", - "tip_car[1] = tip_rack2 = HTF_L(name='tips_02', with_tips=False)\n", - "tip_car[2] = tip_rack3 = HTF_L(name='tips_03', with_tips=False)\n", - "tip_car[3] = tip_rack4 = HTF_L(name='tips_04', with_tips=False)\n", - "tip_car[4] = tip_rack5 = HTF_L(name='tips_05', with_tips=False)" + "tip_car[0] = tip_rack1 = HTF(name='tips_01', with_tips=False)\n", + "tip_car[1] = tip_rack2 = HTF(name='tips_02', with_tips=False)\n", + "tip_car[2] = tip_rack3 = HTF(name='tips_03', with_tips=False)\n", + "tip_car[3] = tip_rack4 = HTF(name='tips_04', with_tips=False)\n", + "tip_car[4] = tip_rack5 = HTF(name='tips_05', with_tips=False)" ] }, { diff --git a/docs/user_guide/using-trackers.ipynb b/docs/user_guide/using-trackers.ipynb index 6f993dce10..8784965a73 100644 --- a/docs/user_guide/using-trackers.ipynb +++ b/docs/user_guide/using-trackers.ipynb @@ -31,7 +31,7 @@ "from pylabrobot.liquid_handling.backends.chatterbox_backend import ChatterboxBackend\n", "from pylabrobot.resources import (\n", " TIP_CAR_480_A00,\n", - " HTF_L,\n", + " HTF,\n", " PLT_CAR_L5AC_A00,\n", " Cor_96_wellplate_360ul_Fbate_360ul_Fb,\n", " set_tip_tracking,\n", @@ -105,7 +105,7 @@ "metadata": {}, "outputs": [], "source": [ - "tip_carrier[0] = tip_rack = HTF_L(name=\"tip rack\")" + "tip_carrier[0] = tip_rack = HTF(name=\"tip rack\")" ] }, { @@ -142,7 +142,7 @@ "metadata": {}, "outputs": [], "source": [ - "tip_carrier[1] = empty_tip_rack = HTF_L(name=\"empty tip rack\", with_tips=False)" + "tip_carrier[1] = empty_tip_rack = HTF(name=\"empty tip rack\", with_tips=False)" ] }, { @@ -996,4 +996,4 @@ }, "nbformat": 4, "nbformat_minor": 2 -} +} \ No newline at end of file diff --git a/pylabrobot/gui/gui.py b/pylabrobot/gui/gui.py index c0d0c9e1ef..1191785f83 100644 --- a/pylabrobot/gui/gui.py +++ b/pylabrobot/gui/gui.py @@ -50,58 +50,58 @@ def list_resources(): return jsonify( plates=[ "Cos_1536_10ul", - "Cos_1536_10ul_L", + "Cos_1536_10ul", "Cos_1536_10ul_P", "Cos_384_DW", - "Cos_384_DW_L", + "Cos_384_DW", "Cos_384_DW_P", "Cos_384_PCR", - "Cos_384_PCR_L", + "Cos_384_PCR", "Cos_384_PCR_P", "Cos_384_Sq", - "Cos_384_Sq_L", + "Cos_384_Sq", "Cos_384_Sq_P", "Cos_384_Sq_Rd", - "Cos_384_Sq_Rd_L", + "Cos_384_Sq_Rd", "Cos_384_Sq_Rd_P", "Cos_96_DW_1mL", - "Cos_96_DW_1mL_L", + "Cos_96_DW_1mL", "Cos_96_DW_1mL_P", "Cos_96_DW_2mL", - "Cos_96_DW_2mL_L", + "Cos_96_DW_2mL", "Cos_96_DW_2mL_P", "Cos_96_DW_500ul", - "Cos_96_DW_500ul_L", + "Cos_96_DW_500ul", "Cos_96_DW_500ul_P", "Cor_96_wellplate_360ul_Fb", - "Cor_96_wellplate_360ul_Fb_L", + "Cor_96_wellplate_360ul_Fb", "Cor_96_wellplate_360ul_Fb_P", "Cos_96_FL", "Cos_96_Filter", - "Cos_96_Filter_L", + "Cos_96_Filter", "Cos_96_Filter_P", - "Cos_96_Fl_L", + "Cos_96_Fl", "Cos_96_Fl_P", "Cos_96_HalfArea", - "Cos_96_HalfArea_L", + "Cos_96_HalfArea", "Cos_96_HalfArea_P", "Cos_96_PCR", - "Cos_96_PCR_L", + "Cos_96_PCR", "Cos_96_PCR_P", "Cos_96_ProtCryst", - "Cos_96_ProtCryst_L", + "Cos_96_ProtCryst", "Cos_96_ProtCryst_P", "Cos_96_Rd", - "Cos_96_Rd_L", + "Cos_96_Rd", "Cos_96_Rd_P", "Cos_96_SpecOps", - "Cos_96_SpecOps_L", + "Cos_96_SpecOps", "Cos_96_SpecOps_P", "Cos_96_UV", - "Cos_96_UV_L", + "Cos_96_UV", "Cos_96_UV_P", "Cos_96_Vb", - "Cos_96_Vb_L", + "Cos_96_Vb", "Cos_96_Vb_P", ], plate_carriers=[ @@ -197,21 +197,21 @@ def list_resources(): "TIP_CAR_NTR_A00", ], tip_racks=[ - "FourmlTF_L", + "FourmlTF", "FourmlTF_P", - "FivemlT_L", + "FivemlT", "FivemlT_P", - "HTF_L", + "HTF", "HTF_P", - "HT_L", + "HT", "HT_P", - "LTF_L", + "LTF", "LTF_P", - "LT_L", + "LT", "LT_P", - "STF_L", + "STF", "STF_P", - "ST_L", + "ST", "ST_P", ], ) diff --git a/pylabrobot/liquid_handling/backends/chatterbox_tests.py b/pylabrobot/liquid_handling/backends/chatterbox_tests.py index 203ab1f600..5862773a0d 100644 --- a/pylabrobot/liquid_handling/backends/chatterbox_tests.py +++ b/pylabrobot/liquid_handling/backends/chatterbox_tests.py @@ -6,7 +6,7 @@ ) from pylabrobot.resources import ( Cor_96_wellplate_360ul_Fb, - HTF_L, + HTF, Coordinate, ) from pylabrobot.resources.hamilton import STARLetDeck @@ -19,7 +19,7 @@ def setUp(self) -> None: self.deck = STARLetDeck() self.backend = LiquidHandlerChatterboxBackend(num_channels=8) self.lh = LiquidHandler(self.backend, deck=self.deck) - self.tip_rack = HTF_L(name="tip_rack") + self.tip_rack = HTF(name="tip_rack") self.deck.assign_child_resource(self.tip_rack, rails=3) self.plate = Cor_96_wellplate_360ul_Fb(name="plate") self.deck.assign_child_resource(self.plate, rails=9) diff --git a/pylabrobot/liquid_handling/backends/hamilton/STAR_tests.py b/pylabrobot/liquid_handling/backends/hamilton/STAR_tests.py index 288ac907f6..5a2e4f5fd9 100644 --- a/pylabrobot/liquid_handling/backends/hamilton/STAR_tests.py +++ b/pylabrobot/liquid_handling/backends/hamilton/STAR_tests.py @@ -17,13 +17,13 @@ TIP_CAR_480_A00, TIP_CAR_288_C00, PLT_CAR_L5AC_A00, - HT_P, - HTF_L, + HT, + HTF, Cor_96_wellplate_360ul_Fb, no_volume_tracking, ) from pylabrobot.resources.hamilton import STARLetDeck -from pylabrobot.resources.ml_star import STF_L +from pylabrobot.resources.ml_star import STF from tests.usb import MockDev, MockEndpoint @@ -221,8 +221,8 @@ async def asyncSetUp(self): self.lh = LiquidHandler(self.mockSTAR, deck=self.deck) self.tip_car = TIP_CAR_480_A00(name="tip carrier") - self.tip_car[1] = self.tip_rack = STF_L(name="tip_rack_01") - self.tip_car[2] = self.tip_rack2 = HTF_L(name="tip_rack_02") + self.tip_car[1] = self.tip_rack = STF(name="tip_rack_01") + self.tip_car[2] = self.tip_rack2 = HTF(name="tip_rack_02") self.deck.assign_child_resource(self.tip_car, rails=1) self.plt_car = PLT_CAR_L5AC_A00(name="plate carrier") @@ -900,12 +900,10 @@ async def test_discard_tips(self): ) async def test_portrait_tip_rack_handling(self): - # Test with an alternative setup. - deck = STARLetDeck() lh = LiquidHandler(self.mockSTAR, deck=deck) tip_car = TIP_CAR_288_C00(name="tip carrier") - tip_car[0] = tr = HT_P(name="tips_01") + tip_car[0] = tr = HT(name="tips_01").rotated(z=90) assert tr.rotation.z == 90 assert tr.location == Coordinate(82.6, 0, 0) deck.assign_child_resource(tip_car, rails=2) diff --git a/pylabrobot/liquid_handling/backends/hamilton/vantage_tests.py b/pylabrobot/liquid_handling/backends/hamilton/vantage_tests.py index 1f323867d7..8d32c12c9d 100644 --- a/pylabrobot/liquid_handling/backends/hamilton/vantage_tests.py +++ b/pylabrobot/liquid_handling/backends/hamilton/vantage_tests.py @@ -6,8 +6,8 @@ Coordinate, TIP_CAR_480_A00, PLT_CAR_L5AC_A00, - HT_L, - LT_L, + HT, + LT, Cor_96_wellplate_360ul_Fb, ) from pylabrobot.resources.hamilton import VantageDeck @@ -244,8 +244,8 @@ async def asyncSetUp(self): self.lh = LiquidHandler(self.mockVantage, deck=self.deck) self.tip_car = TIP_CAR_480_A00(name="tip carrier") - self.tip_car[0] = self.tip_rack = HT_L(name="tip_rack_01") - self.tip_car[1] = self.small_tip_rack = LT_L(name="tip_rack_02") + self.tip_car[0] = self.tip_rack = HT(name="tip_rack_01") + self.tip_car[1] = self.small_tip_rack = LT(name="tip_rack_02") self.deck.assign_child_resource(self.tip_car, rails=18) self.plt_car = PLT_CAR_L5AC_A00(name="plate carrier") diff --git a/pylabrobot/liquid_handling/backends/http_tests.py b/pylabrobot/liquid_handling/backends/http_tests.py index 248b5fb10c..31fc4e6a81 100644 --- a/pylabrobot/liquid_handling/backends/http_tests.py +++ b/pylabrobot/liquid_handling/backends/http_tests.py @@ -9,7 +9,7 @@ from pylabrobot.resources import ( PLT_CAR_L5AC_A00, TIP_CAR_480_A00, - HTF_L, + HTF, Cor_96_wellplate_360ul_Fb, no_tip_tracking, no_volume_tracking, @@ -74,7 +74,7 @@ async def asyncSetUp(self) -> None: # type: ignore self.deck = STARLetDeck() self.tip_carrier = TIP_CAR_480_A00(name="tip_carrier") - self.tip_carrier[0] = self.tip_rack = HTF_L(name="tiprack") + self.tip_carrier[0] = self.tip_rack = HTF(name="tiprack") self.plate_carrier = PLT_CAR_L5AC_A00(name="plate_carrier") self.plate_carrier[0] = self.plate = Cor_96_wellplate_360ul_Fb(name="plate") self.deck.assign_child_resource(self.tip_carrier, rails=3) diff --git a/pylabrobot/liquid_handling/backends/serializing_backend_tests.py b/pylabrobot/liquid_handling/backends/serializing_backend_tests.py index 7502b950d8..7124df35a6 100644 --- a/pylabrobot/liquid_handling/backends/serializing_backend_tests.py +++ b/pylabrobot/liquid_handling/backends/serializing_backend_tests.py @@ -9,7 +9,7 @@ TIP_CAR_480_A00, PLT_CAR_L5AC_A00, Cor_96_wellplate_360ul_Fb, - STF_L, + STF, Coordinate, no_tip_tracking, no_volume_tracking, @@ -27,7 +27,7 @@ async def asyncSetUp(self) -> None: await self.lh.setup() self.tip_car = TIP_CAR_480_A00(name="tip carrier") - self.tip_car[0] = self.tip_rack = STF_L(name="tip_rack_01") + self.tip_car[0] = self.tip_rack = STF(name="tip_rack_01") self.deck.assign_child_resource(self.tip_car, rails=1) self.plt_car = PLT_CAR_L5AC_A00(name="plate carrier") diff --git a/pylabrobot/liquid_handling/liquid_handler_tests.py b/pylabrobot/liquid_handling/liquid_handler_tests.py index 5647c3f860..d2ade413b7 100644 --- a/pylabrobot/liquid_handling/liquid_handler_tests.py +++ b/pylabrobot/liquid_handling/liquid_handler_tests.py @@ -45,7 +45,7 @@ ResourceNotFoundError, ) from pylabrobot.resources.hamilton import STARLetDeck -from pylabrobot.resources.ml_star import STF_L, HTF_L +from pylabrobot.resources.ml_star import STF, HTF from .standard import ( GripDirection, Pickup, @@ -102,9 +102,9 @@ def setUp(self): def test_resource_assignment(self): tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="tip_rack_01") - tip_car[1] = STF_L(name="tip_rack_02") - tip_car[3] = HTF_L("tip_rack_04") + tip_car[0] = STF(name="tip_rack_01") + tip_car[1] = STF(name="tip_rack_02") + tip_car[3] = HTF("tip_rack_04") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="aspiration plate") @@ -136,7 +136,7 @@ def test_resource_assignment(self): def test_get_resource(self): tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="tip_rack_01") + tip_car[0] = STF(name="tip_rack_01") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="aspiration plate") self.deck.assign_child_resource(tip_car, rails=1) @@ -159,8 +159,8 @@ def test_get_resource(self): def test_subcoordinates(self): tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="tip_rack_01") - tip_car[3] = HTF_L(name="tip_rack_04") + tip_car[0] = STF(name="tip_rack_01") + tip_car[3] = HTF(name="tip_rack_04") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="aspiration plate") plt_car[2] = Cor_96_wellplate_360ul_Fb(name="dispense plate") @@ -208,7 +208,7 @@ def test_illegal_subresource_assignment_before(self): # Test assigning subresource with the same name as another resource in another carrier. This # should raise an ValueError when the carrier is assigned to the liquid handler. tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="sub") + tip_car[0] = STF(name="sub") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="sub") self.deck.assign_child_resource(tip_car, rails=1) @@ -219,7 +219,7 @@ def test_illegal_subresource_assignment_after(self): # Test assigning subresource with the same name as another resource in another carrier, after # the carrier has been assigned. This should raise an error. tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="sub") + tip_car[0] = STF(name="sub") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="ok") self.deck.assign_child_resource(tip_car, rails=1) @@ -450,7 +450,7 @@ async def asyncSetUp(self): self.deck = STARLetDeck() self.lh = LiquidHandler(backend=self.backend, deck=self.deck) - self.tip_rack = STF_L(name="tip_rack") + self.tip_rack = STF(name="tip_rack") self.plate = Cor_96_wellplate_360ul_Fb(name="plate") self.deck.assign_child_resource(self.tip_rack, location=Coordinate(0, 0, 0)) self.deck.assign_child_resource(self.plate, location=Coordinate(100, 100, 0)) @@ -1017,7 +1017,7 @@ async def asyncSetUp(self): self.backend = backends.SaverBackend(num_channels=8) self.deck = STARLetDeck() self.lh = LiquidHandler(backend=self.backend, deck=self.deck) - self.tip_rack = STF_L(name="tip_rack") + self.tip_rack = STF(name="tip_rack") self.plate = Cor_96_wellplate_360ul_Fb(name="plate") self.deck.assign_child_resource(self.tip_rack, location=Coordinate(0, 0, 0)) self.deck.assign_child_resource(self.plate, location=Coordinate(100, 100, 0)) @@ -1060,7 +1060,7 @@ async def asyncSetUp(self): self.backend = backends.SaverBackend(num_channels=8) self.deck = STARLetDeck() self.lh = LiquidHandler(backend=self.backend, deck=self.deck) - self.tip_rack = STF_L(name="tip_rack") + self.tip_rack = STF(name="tip_rack") self.plate = Cor_96_wellplate_360ul_Fb(name="plate") self.deck.assign_child_resource(self.tip_rack, location=Coordinate(0, 0, 0)) self.deck.assign_child_resource(self.plate, location=Coordinate(100, 100, 0)) diff --git a/pylabrobot/resources/azenta/plates.py b/pylabrobot/resources/azenta/plates.py index 3030351747..a83a63e019 100644 --- a/pylabrobot/resources/azenta/plates.py +++ b/pylabrobot/resources/azenta/plates.py @@ -89,9 +89,17 @@ def Azenta4titudeFrameStar_96_wellplate_200ul_Vb(name: str, with_lid: bool = Fal #: Azenta4titudeFrameStar_96_wellplate_Vb_L def Azenta4titudeFrameStar_96_wellplate_200ul_Vb_L(name: str, with_lid: bool = False) -> Plate: - return Azenta4titudeFrameStar_96_wellplate_200ul_Vb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Azenta4titudeFrameStar_96_wellplate_200ul_Vb instead." + ) #: Azenta4titudeFrameStar_96_wellplate_Vb_P def Azenta4titudeFrameStar_96_wellplate_200ul_Vb_P(name: str, with_lid: bool = False) -> Plate: - return Azenta4titudeFrameStar_96_wellplate_200ul_Vb(name=name, with_lid=with_lid).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. For portrait, use " + "Azenta4titudeFrameStar_96_wellplate_200ul_Vb().rotated(z=90) instead." + ) diff --git a/pylabrobot/resources/carrier.py b/pylabrobot/resources/carrier.py index 7cd0096abd..107495ac73 100644 --- a/pylabrobot/resources/carrier.py +++ b/pylabrobot/resources/carrier.py @@ -70,13 +70,13 @@ class Carrier(Resource, Generic[S]): Creating a `TipCarrier` and assigning one set of tips at location 0 (the bottom): >>> tip_car = TIP_CAR_480_A00(name='tip carrier') - >>> tip_car[0] = STF_L(name='tips_1') + >>> tip_car[0] = STF(name='tips_1') Getting the tips: >>> tip_car[0] - STF_L(name='tips_1') + STF(name='tips_1') Deleting the tips: diff --git a/pylabrobot/resources/corning_axygen/plates.py b/pylabrobot/resources/corning_axygen/plates.py index c3cee09308..184dabf77d 100644 --- a/pylabrobot/resources/corning_axygen/plates.py +++ b/pylabrobot/resources/corning_axygen/plates.py @@ -62,9 +62,13 @@ def Axy_24_DW_10ML(name: str, with_lid: bool = False) -> Plate: #: Axy_24_DW_10ML_L def Axy_24_DW_10ML_L(name: str, with_lid: bool = False) -> Plate: - return Axy_24_DW_10ML(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "Axy_24_DW_10ML instead.") #: Axy_24_DW_10ML_P def Axy_24_DW_10ML_P(name: str, with_lid: bool = False) -> Plate: - return Axy_24_DW_10ML(name=name, with_lid=with_lid).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Axy_24_DW_10ML().rotated(z=90) instead." + ) diff --git a/pylabrobot/resources/corning_costar/plates.py b/pylabrobot/resources/corning_costar/plates.py index 704147a7dc..4884a7b5c9 100644 --- a/pylabrobot/resources/corning_costar/plates.py +++ b/pylabrobot/resources/corning_costar/plates.py @@ -88,11 +88,18 @@ def Cos_6_wellplate_16800ul_Fb(name: str, with_lid: bool = True) -> Plate: def Cos_6_wellplate_16800ul_Fb_L(name: str, with_lid: bool = True) -> Plate: - return Cos_6_wellplate_16800ul_Fb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Cos_6_wellplate_16800ul_Fb instead." + ) def Cos_6_wellplate_16800ul_Fb_P(name: str, with_lid: bool = True) -> Plate: - return Cos_6_wellplate_16800ul_Fb(name=name, with_lid=with_lid).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Cos_6_wellplate_16800ul_Fb().rotated(z=90) instead." + ) # # # # # # # # # # Cos_96_wellplate_2mL_Vb # # # # # # # # # # @@ -182,13 +189,17 @@ def Cos_96_wellplate_2mL_Vb(name: str, with_lid: bool = False) -> Plate: def Cos_96_wellplate_2mL_Vb_L(name: str, with_lid: bool = False) -> Plate: - """Cos_96_wellplate_2mL_Vb""" - return Cos_96_wellplate_2mL_Vb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Cos_96_wellplate_2mL_Vb instead." + ) def Cos_96_wellplate_2mL_Vb_P(name: str, with_lid: bool = False) -> Plate: - """Cos_96_wellplate_2mL_Vb""" - return Cos_96_wellplate_2mL_Vb(name=name, with_lid=with_lid).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Cos_96_wellplate_2mL_Vb().rotated(z=90) instead." + ) # # # # # # # # # # Cor_96_wellplate_360ul_Fb # # # # # # # # # # diff --git a/pylabrobot/resources/eppendorf/plates.py b/pylabrobot/resources/eppendorf/plates.py index 1e4e2b1fa7..c70f320606 100644 --- a/pylabrobot/resources/eppendorf/plates.py +++ b/pylabrobot/resources/eppendorf/plates.py @@ -102,8 +102,15 @@ def Eppendorf_96_wellplate_250ul_Vb(name: str, with_lid: bool = False) -> Plate: def Eppendorf_96_wellplate_250ul_Vb_L(name: str, with_lid: bool = False) -> Plate: - return Eppendorf_96_wellplate_250ul_Vb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Eppendorf_96_wellplate_250ul_Vb instead." + ) def Eppendorf_96_wellplate_250ul_Vb_P(name: str, with_lid: bool = False) -> Plate: - return Eppendorf_96_wellplate_250ul_Vb(name=name, with_lid=with_lid).rotated(90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Eppendorf_96_wellplate_250ul_Vb.rotated(90) instead." + ) diff --git a/pylabrobot/resources/hamilton/hamilton_deck_tests.py b/pylabrobot/resources/hamilton/hamilton_deck_tests.py index 9830cceed0..fe506c3c60 100644 --- a/pylabrobot/resources/hamilton/hamilton_deck_tests.py +++ b/pylabrobot/resources/hamilton/hamilton_deck_tests.py @@ -9,8 +9,8 @@ ) from pylabrobot.resources.hamilton import STARLetDeck from pylabrobot.resources.ml_star import ( - STF_L, - HTF_L, + STF, + HTF, TIP_CAR_480_A00, PLT_CAR_L5AC_A00, ) @@ -24,9 +24,9 @@ def build_layout(self): deck = STARLetDeck() tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = STF_L(name="tip_rack_01") - tip_car[1] = STF_L(name="tip_rack_02") - tip_car[3] = HTF_L(name="tip_rack_04") + tip_car[0] = STF(name="tip_rack_01") + tip_car[1] = STF(name="tip_rack_02") + tip_car[3] = HTF(name="tip_rack_04") plt_car = PLT_CAR_L5AC_A00(name="plate carrier") plt_car[0] = Cor_96_wellplate_360ul_Fb(name="aspiration plate") diff --git a/pylabrobot/resources/hamilton/hamilton_decks.py b/pylabrobot/resources/hamilton/hamilton_decks.py index 2e2b5384d3..d45453fa3f 100644 --- a/pylabrobot/resources/hamilton/hamilton_decks.py +++ b/pylabrobot/resources/hamilton/hamilton_decks.py @@ -207,7 +207,7 @@ def summary(self) -> str: Rail Resource Type Coordinates (mm) ============================================================================================= (1) ├── tip_car TIP_CAR_480_A00 (x: 100.000, y: 240.800, z: 164.450) - │ ├── tip_rack_01 STF_L (x: 117.900, y: 240.000, z: 100.000) + │ ├── tip_rack_01 STF (x: 117.900, y: 240.000, z: 100.000) """ if len(self.get_all_resources()) == 0: diff --git a/pylabrobot/resources/ml_star/tip_racks.py b/pylabrobot/resources/ml_star/tip_racks.py index ab407e20c4..21a98e9461 100644 --- a/pylabrobot/resources/ml_star/tip_racks.py +++ b/pylabrobot/resources/ml_star/tip_racks.py @@ -1,5 +1,3 @@ -"""ML Star tips""" - from pylabrobot.resources.utils import create_ordered_items_2d from pylabrobot.resources.tip_rack import ( TipSpot, @@ -23,14 +21,14 @@ ) -def FourmlTF_L(name: str, with_tips: bool = True) -> TipRack: +def FourmlTF(name: str, with_tips: bool = True) -> TipRack: """Tip Rack 24x 4ml Tip with Filter landscape oriented""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=7.0, - model="FourmlTF_L", + model="FourmlTF", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=6, @@ -48,19 +46,26 @@ def FourmlTF_L(name: str, with_tips: bool = True) -> TipRack: ) +def FourmlTF_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "FourmlTF instead.") + + def FourmlTF_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack 24x 4ml Tip with Filter portrait oriented""" - return FourmlTF_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "FourmlTF().rotated(z=90) instead." + ) -def FivemlT_L(name: str, with_tips: bool = True) -> TipRack: +def FivemlT(name: str, with_tips: bool = True) -> TipRack: """Tip Rack 24x 5ml Tip landscape oriented""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=7.0, - model="FivemlT_L", + model="FivemlT", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=6, @@ -78,19 +83,26 @@ def FivemlT_L(name: str, with_tips: bool = True) -> TipRack: ) +def FivemlT_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "FivemlT instead.") + + def FivemlT_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack 24x 5ml Tip portrait oriented""" - return FivemlT_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "FivemlT().rotated(z=90) instead." + ) -def HTF_L(name: str, with_tips: bool = True) -> TipRack: +def HTF(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 1000ul High Volume Tip with filter""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="HTF_L", + model="HTF", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -108,14 +120,26 @@ def HTF_L(name: str, with_tips: bool = True) -> TipRack: ) -def HTF_L_WIDE(name: str, with_tips: bool = True) -> TipRack: +def HTF_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "HTF instead.") + + +def HTF_P(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "HTF().rotated(z=90) instead." + ) + + +def HTF_WIDE(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 1000ul High Volume Tip with filter""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model=HTF_L_WIDE.__name__, + model=HTF_WIDE.__name__, ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -133,14 +157,18 @@ def HTF_L_WIDE(name: str, with_tips: bool = True) -> TipRack: ) -def HTF_L_ULTRAWIDE(name: str, with_tips: bool = True) -> TipRack: +def HTF_L_WIDE(name: str, with_tips: bool = True) -> TipRack: + raise NotImplementedError("_L and _P definitions are deprecated. Use " "HTF_WIDE instead.") + + +def HTF_ULTRAWIDE(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 1000ul High Volume Tip with filter""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model=HTF_L_ULTRAWIDE.__name__, + model=HTF_ULTRAWIDE.__name__, ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -158,19 +186,18 @@ def HTF_L_ULTRAWIDE(name: str, with_tips: bool = True) -> TipRack: ) -def HTF_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 1000ul High Volume Tip with filter (portrait)""" - return HTF_L(name=name, with_tips=with_tips).rotated(z=90) +def HTF_L_ULTRAWIDE(name: str, with_tips: bool = True) -> TipRack: + raise NotImplementedError("_L and _P definitions are deprecated. Use " "HTF_ULTRAWIDE instead.") -def HT_L(name: str, with_tips: bool = True) -> TipRack: +def HT(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 1000ul High Volume Tip""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="HT_L", + model="HT", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -188,19 +215,26 @@ def HT_L(name: str, with_tips: bool = True) -> TipRack: ) +def HT_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "HT instead.") + + def HT_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 1000ul High Volume Tip (portrait)""" - return HT_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "HT().rotated(z=90) instead." + ) -def LTF_L(name: str, with_tips: bool = True) -> TipRack: +def LTF(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 10ul Low Volume Tip with filter""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="LTF_L", + model="LTF", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -218,19 +252,26 @@ def LTF_L(name: str, with_tips: bool = True) -> TipRack: ) +def LTF_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "LTF instead.") + + def LTF_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 10ul Low Volume Tip with filter (portrait)""" - return LTF_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "LTF().rotated(z=90) instead." + ) -def LT_L(name: str, with_tips: bool = True) -> TipRack: +def LT(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 10ul Low Volume Tip""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="LT_L", + model="LT", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -248,19 +289,26 @@ def LT_L(name: str, with_tips: bool = True) -> TipRack: ) +def LT_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "LT instead.") + + def LT_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 10ul Low Volume Tip (portrait)""" - return LT_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "LT().rotated(z=90) instead." + ) -def STF_L(name: str, with_tips: bool = True) -> TipRack: +def STF(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 300ul Standard Volume Tip with filter""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="STF_L", + model="STF", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -278,12 +326,19 @@ def STF_L(name: str, with_tips: bool = True) -> TipRack: ) +def STF_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "STF instead.") + + def STF_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 300ul Standard Volume Tip with filter (portrait)""" - return STF_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "STF().rotated(z=90) instead." + ) -def STF_Slim_L(name: str, with_tips: bool = True) -> TipRack: +def STF_Slim(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 300ul Slim Standard Volume Tip with filter""" return TipRack( name=name, @@ -308,19 +363,26 @@ def STF_Slim_L(name: str, with_tips: bool = True) -> TipRack: ) +def STF_Slim_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "STF_Slim instead.") + + def STF_Slim_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 300ul Slim Standard Volume Tip with filter (portrait)""" - return STF_Slim_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "STF_Slim().rotated(z=90) instead." + ) -def ST_L(name: str, with_tips: bool = True) -> TipRack: +def ST(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 300ul Standard Volume Tip""" return TipRack( name=name, size_x=122.4, size_y=82.6, size_z=20.0, - model="ST_L", + model="ST", ordered_items=create_ordered_items_2d( TipSpot, num_items_x=12, @@ -338,12 +400,19 @@ def ST_L(name: str, with_tips: bool = True) -> TipRack: ) +def ST_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "ST instead.") + + def ST_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 300ul Standard Volume Tip (portrait)""" - return ST_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "ST().rotated(z=90) instead." + ) -def TIP_50ul_w_filter_L(name: str, with_tips: bool = True) -> TipRack: +def TIP_50ul_w_filter(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 50ul Tip with filter""" return TipRack( name=name, @@ -368,12 +437,21 @@ def TIP_50ul_w_filter_L(name: str, with_tips: bool = True) -> TipRack: ) +def TIP_50ul_w_filter_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "TIP_50ul_w_filter instead." + ) + + def TIP_50ul_w_filter_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 50ul Tip with filter (portrait)""" - return TIP_50ul_w_filter_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "TIP_50ul_w_filter().rotated(z=90) instead." + ) -def TIP_50ul_L(name: str, with_tips: bool = True) -> TipRack: +def TIP_50ul(name: str, with_tips: bool = True) -> TipRack: """Tip Rack with 96 50ul Tip""" return TipRack( name=name, @@ -398,9 +476,16 @@ def TIP_50ul_L(name: str, with_tips: bool = True) -> TipRack: ) +def TIP_50ul_L(name: str, with_tips: bool = True) -> TipRack: + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError("_L and _P definitions are deprecated. Use " "TIP_50ul instead.") + + def TIP_50ul_P(name: str, with_tips: bool = True) -> TipRack: - """Tip Rack with 96 50ul Tip (portrait)""" - return TIP_50ul_L(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "TIP_50ul().rotated(z=90) instead." + ) def Hamilton_96_tiprack_50ul_NTR(name: str, with_tips: bool = True) -> NestedTipRack: @@ -431,10 +516,15 @@ def Hamilton_96_tiprack_50ul_NTR(name: str, with_tips: bool = True) -> NestedTip def Hamilton_96_tiprack_50ul_NTR_L(name: str, with_tips: bool = True) -> NestedTipRack: - """Nested Tip Rack with 96 50ul Tip (landscape, i.e. default)""" - return Hamilton_96_tiprack_50ul_NTR(name=name, with_tips=with_tips) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Hamilton_96_tiprack_50ul_NTR instead." + ) def Hamilton_96_tiprack_50ul_NTR_P(name: str, with_tips: bool = True) -> NestedTipRack: - """Nested Tip Rack with 96 50ul Tip (portrait)""" - return Hamilton_96_tiprack_50ul_NTR(name=name, with_tips=with_tips).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Hamilton_96_tiprack_50ul_NTR().rotated(z=90) instead." + ) diff --git a/pylabrobot/resources/porvair/plates.py b/pylabrobot/resources/porvair/plates.py index 06046699c8..7d3e37c2c5 100644 --- a/pylabrobot/resources/porvair/plates.py +++ b/pylabrobot/resources/porvair/plates.py @@ -93,12 +93,18 @@ def Porvair_6_reservoir_47ml_Vb(name: str, with_lid: bool = False) -> Plate: #: Porvair_6_reservoir_47ml_Vb_L def Porvair_6_reservoir_47ml_Vb_L(name: str, with_lid: bool = False) -> Plate: - return Porvair_6_reservoir_47ml_Vb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Porvair_6_reservoir_47ml_Vb instead." + ) #: Porvair_6_reservoir_47ml_Vb_P def Porvair_6_reservoir_47ml_Vb_P(name: str, with_lid: bool = False) -> Plate: - return Porvair_6_reservoir_47ml_Vb(name=name, with_lid=with_lid).rotated(z=90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Porvair_6_reservoir_47ml_Vb.rotated(90) instead." + ) def Porvair_24_wellplate_Vb(name: str, lid: Optional[Lid] = None) -> Plate: diff --git a/pylabrobot/resources/tecan/tecan_decks.py b/pylabrobot/resources/tecan/tecan_decks.py index 7b6681cfdc..48b7071609 100644 --- a/pylabrobot/resources/tecan/tecan_decks.py +++ b/pylabrobot/resources/tecan/tecan_decks.py @@ -147,17 +147,7 @@ def _rails_for_x_coordinate(self, x: float): return round((x + _RAILS_WIDTH - 101) / _RAILS_WIDTH) + 1 def summary(self) -> str: - """Return a summary of the deck. - - Example: - Printing a summary of the deck layout: - - >>> print(deck.summary()) - Rail Resource Type Coordinates (mm) - ============================================================================================== - (1) ├── tip_car TIP_CAR_480_A00 (x: 100.000, y: 240.800, z: 164.450) - │ ├── tip_rack_01 STF_L (x: 117.900, y: 240.000, z: 100.000) - """ + """Return a summary of the deck.""" if len(self.get_all_resources()) == 0: raise ValueError( diff --git a/pylabrobot/resources/thermo_fisher/plates.py b/pylabrobot/resources/thermo_fisher/plates.py index 82d7190527..9453d1a3ea 100644 --- a/pylabrobot/resources/thermo_fisher/plates.py +++ b/pylabrobot/resources/thermo_fisher/plates.py @@ -119,11 +119,18 @@ def Thermo_TS_96_wellplate_1200ul_Rb(name: str, with_lid: bool = False) -> Plate def Thermo_TS_96_wellplate_1200ul_Rb_L(name: str, with_lid: bool = False) -> Plate: - return Thermo_TS_96_wellplate_1200ul_Rb(name=name, with_lid=with_lid) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " "Thermo_TS_96_wellplate_1200ul_Rb instead." + ) def Thermo_TS_96_wellplate_1200ul_Rb_P(name: str, with_lid: bool = False) -> Plate: - return Thermo_TS_96_wellplate_1200ul_Rb(name=name, with_lid=with_lid).rotated(90) + # https://github.com/PyLabRobot/pylabrobot/issues/252 + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Thermo_TS_96_wellplate_1200ul_Rb().rotated(z=90) instead." + ) # # # # # # # # # # Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate # # # # # # # # # # @@ -226,8 +233,14 @@ def Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate(name: str, with_lid: bool = Fals def Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate_L(name: str, with_lid: bool = False) -> Plate: - return Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate(name=name, with_lid=with_lid) + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate instead." + ) def Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate_P(name: str, with_lid: bool = False) -> Plate: - return Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate(name=name, with_lid=with_lid).rotated(90) + raise NotImplementedError( + "_L and _P definitions are deprecated. Use " + "Thermo_AB_96_wellplate_300ul_Vb_EnduraPlate.rotated(90) instead." + ) diff --git a/pylabrobot/server/liquid_handling_api_tests.py b/pylabrobot/server/liquid_handling_api_tests.py index 6e703cc44f..59cfbfc934 100644 --- a/pylabrobot/server/liquid_handling_api_tests.py +++ b/pylabrobot/server/liquid_handling_api_tests.py @@ -12,7 +12,7 @@ from pylabrobot.resources import ( Plate, TipRack, - HTF_L, + HTF, Cor_96_wellplate_360ul_Fb, TIP_CAR_480_A00, PLT_CAR_L5AC_A00, @@ -26,7 +26,7 @@ def build_layout() -> HamiltonDeck: # copied from liquid_handler_tests.py, can we make this shared? tip_car = TIP_CAR_480_A00(name="tip_carrier") - tip_car[0] = HTF_L(name="tip_rack_01") + tip_car[0] = HTF(name="tip_rack_01") plt_car = PLT_CAR_L5AC_A00(name="plate_carrier") plt_car[0] = plate = Cor_96_wellplate_360ul_Fb(name="aspiration plate")