From 868ac95b516f32c7b4b6932991fe4ab52044079b Mon Sep 17 00:00:00 2001 From: "Eric G. Kratz" Date: Tue, 2 Apr 2024 04:02:44 -0400 Subject: [PATCH] Jax windows restrictions (#3955) * Fix coverage * Remove windows Jax restrictions * style: pre-commit fixes * Update MacOS instructions * Update docs/source/user_guide/installation/install-from-source.rst * Apply suggestions from code review * Apply suggestions from code review * Apply suggestions from code review --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> --- .github/workflows/publish_pypi.yml | 4 +-- .../user_guide/installation/gnu-linux-mac.rst | 2 +- noxfile.py | 33 +++++++------------ 3 files changed, 14 insertions(+), 25 deletions(-) diff --git a/.github/workflows/publish_pypi.yml b/.github/workflows/publish_pypi.yml index bae6ec207c..bd03c58109 100644 --- a/.github/workflows/publish_pypi.yml +++ b/.github/workflows/publish_pypi.yml @@ -113,7 +113,7 @@ jobs: - name: Install SuiteSparse and SUNDIALS on macOS if: matrix.os == 'macos-12' run: | - brew install graphviz openblas libomp + brew install graphviz libomp brew reinstall gcc python -m pip install cmake wget python scripts/install_KLU_Sundials.py @@ -164,7 +164,7 @@ jobs: - name: Install SuiteSparse and SUNDIALS on macOS run: | - brew install graphviz openblas libomp + brew install graphviz libomp brew reinstall gcc python -m pip install cmake pipx python scripts/install_KLU_Sundials.py diff --git a/docs/source/user_guide/installation/gnu-linux-mac.rst b/docs/source/user_guide/installation/gnu-linux-mac.rst index 806576938f..46f3d1281f 100644 --- a/docs/source/user_guide/installation/gnu-linux-mac.rst +++ b/docs/source/user_guide/installation/gnu-linux-mac.rst @@ -30,7 +30,7 @@ To use PyBaMM, you must have Python 3.8, 3.9, 3.10, 3.11, or 3.12 installed. .. code:: bash - brew install python3 + brew install python Install PyBaMM diff --git a/noxfile.py b/noxfile.py index ff262e84a1..95e2e6555f 100644 --- a/noxfile.py +++ b/noxfile.py @@ -130,37 +130,26 @@ def set_dev(session): # https://bitbucket.org/pybtex-devs/pybtex/issues/169/replace-pkg_resources-with # is fixed session.run(python, "-m", "pip", "install", "setuptools", external=True) - if sys.platform == "linux": + if sys.version_info < (3, 9): session.run( python, "-m", "pip", "install", "-e", - ".[all,dev,jax]", + ".[all,dev]", external=True, ) else: - if sys.version_info < (3, 9): - session.run( - python, - "-m", - "pip", - "install", - "-e", - ".[all,dev]", - external=True, - ) - else: - session.run( - python, - "-m", - "pip", - "install", - "-e", - ".[all,dev,jax]", - external=True, - ) + session.run( + python, + "-m", + "pip", + "install", + "-e", + ".[all,dev,jax]", + external=True, + ) @nox.session(name="tests")