From e1c8460033a405105214424f844c58878c7f8b44 Mon Sep 17 00:00:00 2001 From: Ed Cormany Date: Thu, 26 Sep 2024 12:28:52 -0400 Subject: [PATCH] docs(api): hide API reference entries for post-2.20 features (#16304) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # Overview 🤫 Hides 2.21 features from the 2.20 docs. ## Test Plan and Hands on Testing [Sandbox](http://sandbox.docs.opentrons.com/docs-hide-post-2.20-ref-entries/v2/new_protocol_api.html) Things you shouldn't see: - `RobotContext` stuff - Future liquid level stuff ## Changelog - `:meta private:` tags for `ProtocolContext.robot` and `Well.meniscus` - Bumped the required version for `ProtocolContext.robot` because it's not useful in 2.20. ## Review requests OK with the version change? It will still be 2.20 in the release branch. I can revert that line if we prefer. ## Risk assessment v low --- api/src/opentrons/protocol_api/labware.py | 2 ++ api/src/opentrons/protocol_api/protocol_context.py | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/api/src/opentrons/protocol_api/labware.py b/api/src/opentrons/protocol_api/labware.py index 43c2c0ce5a8..6f38c123c7a 100644 --- a/api/src/opentrons/protocol_api/labware.py +++ b/api/src/opentrons/protocol_api/labware.py @@ -229,6 +229,8 @@ def meniscus(self, z: float = 0.0) -> Location: :return: A :py:class:`~opentrons.types.Location` corresponding to the absolute position of the meniscus-center of the well, plus the ``z`` offset (if specified). + + :meta private: """ return Location(self._core.get_meniscus(z_offset=z), self) diff --git a/api/src/opentrons/protocol_api/protocol_context.py b/api/src/opentrons/protocol_api/protocol_context.py index 0fca3fdc8f3..64a73457608 100644 --- a/api/src/opentrons/protocol_api/protocol_context.py +++ b/api/src/opentrons/protocol_api/protocol_context.py @@ -209,8 +209,12 @@ def api_version(self) -> APIVersion: return self._api_version @property - @requires_version(2, 20) + @requires_version(2, 21) def robot(self) -> RobotContext: + """The :py:class:`.RobotContext` for the protocol. + + :meta private: + """ return self._robot @property