From 2415dcec5eef925c8ac870322fb44f48f27ec457 Mon Sep 17 00:00:00 2001 From: Callum Forrester Date: Fri, 9 Jun 2023 10:46:22 +0100 Subject: [PATCH 1/3] Split up dependencies into main, ioc and plotting --- .github/workflows/code.yml | 2 +- pyproject.toml | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/code.yml b/.github/workflows/code.yml index 54d35e5..6198ceb 100644 --- a/.github/workflows/code.yml +++ b/.github/workflows/code.yml @@ -147,7 +147,7 @@ jobs: uses: docker/build-push-action@v3 with: build-args: | - PIP_OPTIONS=-r lockfiles/requirements.txt dist/*.whl + PIP_OPTIONS=-r lockfiles/requirements.txt dist/*.whl[plotting] push: ${{ github.event_name != 'pull_request' && endsWith(github.ref, 'main') }} tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} diff --git a/pyproject.toml b/pyproject.toml index 4145734..3824be6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -20,11 +20,7 @@ dependencies = [ "ipython", "pyepics", "click", - "PyQt6", - "PyQt5", "pydantic", - "softioc", - "pandablocks", "scipy", ] dynamic = ["version"] @@ -33,6 +29,8 @@ readme = "README.rst" requires-python = ">=3.9" [project.optional-dependencies] +plotting = ["PyQt6", "PyQt5", "matplotlib"] +ioc = ["softioc", "pandablocks"] dev = [ "black", "mypy", From 984e8bd79e06f4531819284b3ed9fab4cf235d76 Mon Sep 17 00:00:00 2001 From: Callum Forrester Date: Fri, 9 Jun 2023 10:49:01 +0100 Subject: [PATCH 2/3] Update test dependencies --- .github/workflows/code.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/code.yml b/.github/workflows/code.yml index 6198ceb..9b88618 100644 --- a/.github/workflows/code.yml +++ b/.github/workflows/code.yml @@ -38,7 +38,7 @@ jobs: include: - os: "ubuntu-latest" python: "3.9" - install: ".[dev]" + install: ".[dev,ioc,plotting]" runs-on: ${{ matrix.os }} env: @@ -147,7 +147,7 @@ jobs: uses: docker/build-push-action@v3 with: build-args: | - PIP_OPTIONS=-r lockfiles/requirements.txt dist/*.whl[plotting] + PIP_OPTIONS=-r lockfiles/requirements.txt ${ls dist/*.whl}[plotting] push: ${{ github.event_name != 'pull_request' && endsWith(github.ref, 'main') }} tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} From 0502dbcc0aca724dcdbd68a45cb3b4ba11c117d5 Mon Sep 17 00:00:00 2001 From: Callum Forrester Date: Fri, 9 Jun 2023 13:01:34 +0100 Subject: [PATCH 3/3] Fix all dependencies in tests --- .github/workflows/code.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/code.yml b/.github/workflows/code.yml index 9b88618..340cbdc 100644 --- a/.github/workflows/code.yml +++ b/.github/workflows/code.yml @@ -33,7 +33,7 @@ jobs: matrix: os: ["ubuntu-latest"] # can add windows-latest, macos-latest python: ["3.9", "3.10"] - install: ["-e .[dev]"] + install: ["-e .[dev,ioc,plotting]"] # Make one version be non-editable to test both paths of version code include: - os: "ubuntu-latest"