diff --git a/.github/workflows/run-ui-tests.yml b/.github/workflows/run-ui-tests.yml index 412514d8..d0f35be6 100644 --- a/.github/workflows/run-ui-tests.yml +++ b/.github/workflows/run-ui-tests.yml @@ -58,7 +58,7 @@ jobs: - name: Install Xircuits run: | - whl_name=$(echo dist/*whl)[full] + whl_name=$(echo dist/*whl)[learning] pip install $whl_name - name: Setup Playwright diff --git a/MANIFEST.in b/MANIFEST.in index 3b5e0455..fc698114 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -9,6 +9,7 @@ include ts*.json include yarn.lock include requirements.txt include requirements-full.txt +graft xai_components graft xircuits/labextension diff --git a/requirements-full.txt b/requirements-full.txt deleted file mode 100644 index 45c37913..00000000 --- a/requirements-full.txt +++ /dev/null @@ -1,10 +0,0 @@ -tensorflow -numpy -scikit-learn -opencv-python -pillow -tqdm -pandas -py4j -pyspark -matplotlib diff --git a/setup.py b/setup.py index 15129bc3..57b67b26 100644 --- a/setup.py +++ b/setup.py @@ -8,6 +8,7 @@ import setuptools from setuptools import setup, find_packages +import os HERE = Path(__file__).parent.resolve() @@ -48,8 +49,21 @@ with open("requirements.txt", encoding='utf-8-sig') as f: required = f.read().splitlines() -with open("requirements-full.txt", encoding='utf-8-sig') as f: - full_required = f.read().splitlines() +component_library_reqs = {} +full_reqs = [] + +for lib_name in os.listdir("xai_components/"): + + req_path = "xai_components/" + lib_name + "/requirements.txt" + + if os.path.exists(req_path): + with open(req_path, encoding='utf-8-sig') as f: + packages_required = f.read().splitlines() + package_name = "_".join(lib_name.split("_")[1:]) + component_library_reqs.update({package_name : packages_required}) + full_reqs.extend(component_library_reqs) + +component_library_reqs.update({"full": full_reqs}) setup_args = dict( name=name, @@ -64,22 +78,19 @@ long_description_content_type="text/markdown", packages=setuptools.find_packages(), install_requires=required, - extras_require={ - "full": full_required - }, + extras_require=component_library_reqs, zip_safe=False, include_package_data=True, - python_requires=">=3.6", + python_requires=">=3.8", platforms="Linux, Mac OS X, Windows", keywords=["Jupyter", "JupyterLab", "JupyterLab3"], classifiers=[ - "License :: OSI Approved :: BSD License", + "License :: OSI Approved :: Apache-2.0 License", "Programming Language :: Python", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.6", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", + "Programming Language :: Python :: 3.10", "Framework :: Jupyter", "Framework :: Jupyter :: JupyterLab", "Framework :: Jupyter :: JupyterLab :: 3",