From ef66d83ff7549d6de95086312c455b0cddae2351 Mon Sep 17 00:00:00 2001 From: Brian Kroth Date: Wed, 10 Jul 2024 15:07:13 -0500 Subject: [PATCH] CI fixups (#783) 1. Temporarily avoid recent asyncssh version that breaks the tests 2. Workaround pylance issue with pyproject.toml related changes and pip editable modules install format (#768) See Also: - https://github.com/microsoft/pylance-release/issues/3473 May also affect `mypy`: - https://github.com/python/mypy/issues/16988 - https://github.com/python/mypy/issues/12313 --- conda-envs/mlos-3.10.yml | 9 ++++++--- conda-envs/mlos-3.11.yml | 9 ++++++--- conda-envs/mlos-3.8.yml | 9 ++++++--- conda-envs/mlos-3.9.yml | 9 ++++++--- conda-envs/mlos-windows.yml | 9 ++++++--- conda-envs/mlos.yml | 9 ++++++--- mlos_bench/pyproject.toml | 2 +- mlos_bench/setup.py | 2 +- mlos_core/pyproject.toml | 2 +- mlos_viz/pyproject.toml | 2 +- 10 files changed, 40 insertions(+), 22 deletions(-) diff --git a/conda-envs/mlos-3.10.yml b/conda-envs/mlos-3.10.yml index 5a63c126e8..64dca68dda 100644 --- a/conda-envs/mlos-3.10.yml +++ b/conda-envs/mlos-3.10.yml @@ -38,6 +38,9 @@ dependencies: - types-pygments - types-requests - types-setuptools - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/conda-envs/mlos-3.11.yml b/conda-envs/mlos-3.11.yml index 488731fd59..f6add2a586 100644 --- a/conda-envs/mlos-3.11.yml +++ b/conda-envs/mlos-3.11.yml @@ -38,6 +38,9 @@ dependencies: - types-pygments - types-requests - types-setuptools - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/conda-envs/mlos-3.8.yml b/conda-envs/mlos-3.8.yml index 88f43726af..2eb0b25cef 100644 --- a/conda-envs/mlos-3.8.yml +++ b/conda-envs/mlos-3.8.yml @@ -38,6 +38,9 @@ dependencies: - types-pygments - types-requests - types-setuptools - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/conda-envs/mlos-3.9.yml b/conda-envs/mlos-3.9.yml index f1c27b7176..f35aadb5e3 100644 --- a/conda-envs/mlos-3.9.yml +++ b/conda-envs/mlos-3.9.yml @@ -38,6 +38,9 @@ dependencies: - types-pygments - types-requests - types-setuptools - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/conda-envs/mlos-windows.yml b/conda-envs/mlos-windows.yml index d1063b6613..b2c5467458 100644 --- a/conda-envs/mlos-windows.yml +++ b/conda-envs/mlos-windows.yml @@ -42,6 +42,9 @@ dependencies: - types-requests - types-setuptools - pyarrow - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/conda-envs/mlos.yml b/conda-envs/mlos.yml index 0e6e052a51..a257197761 100644 --- a/conda-envs/mlos.yml +++ b/conda-envs/mlos.yml @@ -37,6 +37,9 @@ dependencies: - types-pygments - types-requests - types-setuptools - - "--editable ../mlos_core[full-tests]" - - "--editable ../mlos_bench[full-tests]" - - "--editable ../mlos_viz[full-tests]" + # Workaround a pylance issue in vscode that prevents it finding the latest + # method of pip installing editable modules. + # https://github.com/microsoft/pylance-release/issues/3473 + - "--config-settings editable_mode=compat --editable ../mlos_core[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_bench[full-tests]" + - "--config-settings editable_mode=compat --editable ../mlos_viz[full-tests]" diff --git a/mlos_bench/pyproject.toml b/mlos_bench/pyproject.toml index 321d946f3c..911433da2d 100644 --- a/mlos_bench/pyproject.toml +++ b/mlos_bench/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools", "setuptools-scm>=8.1.0", "wheel"] +requires = ["setuptools>64", "setuptools-scm>=8.1.0", "wheel"] build-backend = "setuptools.build_meta" [project] diff --git a/mlos_bench/setup.py b/mlos_bench/setup.py index be59c22477..2a5a7fe538 100644 --- a/mlos_bench/setup.py +++ b/mlos_bench/setup.py @@ -70,7 +70,7 @@ def _get_long_desc_from_readme(base_url: str) -> dict: extra_requires: Dict[str, List[str]] = { # pylint: disable=consider-using-namedtuple-or-dataclass # Additional tools for extra functionality. 'azure': ['azure-storage-file-share', 'azure-identity', 'azure-keyvault'], - 'ssh': ['asyncssh'], + 'ssh': ['asyncssh<2.15.0'], # FIXME: asyncssh 2.15.0 has a bug that breaks the tests 'storage-sql-duckdb': ['sqlalchemy', 'duckdb_engine'], 'storage-sql-mysql': ['sqlalchemy', 'mysql-connector-python'], 'storage-sql-postgres': ['sqlalchemy', 'psycopg2'], diff --git a/mlos_core/pyproject.toml b/mlos_core/pyproject.toml index 49e7a5ff23..b55955133f 100644 --- a/mlos_core/pyproject.toml +++ b/mlos_core/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools", "setuptools-scm>=8.1.0", "wheel"] +requires = ["setuptools>64", "setuptools-scm>=8.1.0", "wheel"] build-backend = "setuptools.build_meta" [project] diff --git a/mlos_viz/pyproject.toml b/mlos_viz/pyproject.toml index c0101fbbee..b469e60ecc 100644 --- a/mlos_viz/pyproject.toml +++ b/mlos_viz/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools", "setuptools-scm>=8.1.0", "wheel"] +requires = ["setuptools>64", "setuptools-scm>=8.1.0", "wheel"] build-backend = "setuptools.build_meta" [project]