From a81ef47d29153047cc8944b4b50e4948bc797729 Mon Sep 17 00:00:00 2001 From: Frank Sinapi Date: Thu, 12 Oct 2023 14:20:51 -0400 Subject: [PATCH] Updates from Seth's review - Updated the can-related extra requirement in opentrons_hardware to "flex" - Added extra requirements to API for either "ot2-hardware" or "flex-hardware" --- api/Pipfile | 2 +- api/setup.py | 7 ++++++- hardware/setup.py | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/api/Pipfile b/api/Pipfile index 3b742d4e7b9..33ffec93015 100755 --- a/api/Pipfile +++ b/api/Pipfile @@ -36,7 +36,7 @@ types-mock = "==4.0.1" types-setuptools = "==57.0.2" opentrons-shared-data = { editable = true, path = "../shared-data/python" } opentrons = { editable = true, path = "." } -opentrons-hardware = { editable = true, path = "./../hardware", extras= ["CAN"] } +opentrons-hardware = { editable = true, path = "./../hardware", extras= ["FLEX"] } # specify typing-extensions explicitly to force lockfile inclusion on Python >= 3.8 typing-extensions = ">=4.0.0,<5" pytest-profiling = "~=1.7.0" diff --git a/api/setup.py b/api/setup.py index e95d36ece8a..869305ca284 100755 --- a/api/setup.py +++ b/api/setup.py @@ -60,7 +60,6 @@ def get_version(): PACKAGES = find_packages(where="src") INSTALL_REQUIRES = [ f"opentrons-shared-data=={VERSION}", - f"opentrons-hardware=={VERSION}", "aionotify==0.2.0", "anyio==3.3.0", "jsonschema==3.0.2", @@ -72,6 +71,11 @@ def get_version(): 'importlib-metadata >= 1.0 ; python_version < "3.8"', ] +EXTRAS = { + "ot2-hardware": [f"opentrons-hardware=={VERSION}"], + "flex-hardware": [f"opentrons-hardware[FLEX]=={VERSION}"], +} + def read(*parts): """ @@ -99,6 +103,7 @@ def read(*parts): zip_safe=False, classifiers=CLASSIFIERS, install_requires=INSTALL_REQUIRES, + extras_require=EXTRAS, include_package_data=True, package_dir={"": "src"}, package_data={"opentrons": ["py.typed"]}, diff --git a/hardware/setup.py b/hardware/setup.py index 59526d0aee9..c874cd55618 100644 --- a/hardware/setup.py +++ b/hardware/setup.py @@ -52,7 +52,7 @@ def get_version() -> str: ] EXTRAS = { - "CAN": ["python-can==3.3.4"], + "FLEX": ["python-can==3.3.4"], }