From 490a26ebeb8d3e9cfe07461c45fd7d77d1e0e318 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 10:06:11 -0800 Subject: [PATCH 01/10] add check_packaging to ci --- .github/workflows/ci.yaml | 39 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 27b3cfe..0a57729 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -33,7 +33,7 @@ jobs: - "3.12" include: - os: 'macos' - python-version: "3.11" + python-version: "3.11" steps: - uses: actions/checkout@v4 @@ -63,7 +63,7 @@ jobs: - name: "Environment Information" run: | - micromamba info + micromamba info micromamba list - name: "Run tests" @@ -88,3 +88,38 @@ jobs: env_vars: OS,PYTHON fail_ci_if_error: True verbose: True + + check_packaging: + runs-on: ubuntu-latest + timeout-minutes: 30 + + steps: + - uses: actions/checkout@v4 + + - uses: mamba-org/setup-micromamba@v1 + with: + python-version: 3.11 + + - name: install_deps + run: python -m pip install -U pip pipx wheel build + + - name: build_package_sdist + run: pipx run build --sdist + + - name: check_package_build + run: | + DISTRIBUTION=$(ls -t1 dist/kartograf-*.tar.gz | head -n1) + test -n "${DISTRIBUTION}" || { echo "no distribution dist/kartograf-*.tar.gz found"; exit 1; } + + - name: install sdist + working-directory: ./dist + run: | + ls -a . + python -m pip install kartograf-*.tar.gz + + - name: check install + run: pip list + + - name: run tests + working-directory: ./dist + run: python -m pytest --timeout=200 -n logical --pyargs kartograf \ No newline at end of file From 96af290a009b1cdf266564b9f3a7d43c0552fba2 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 10:17:12 -0800 Subject: [PATCH 02/10] fix indent --- .github/workflows/ci.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0a57729..44091cf 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -97,7 +97,7 @@ jobs: - uses: actions/checkout@v4 - uses: mamba-org/setup-micromamba@v1 - with: + with: python-version: 3.11 - name: install_deps @@ -122,4 +122,4 @@ jobs: - name: run tests working-directory: ./dist - run: python -m pytest --timeout=200 -n logical --pyargs kartograf \ No newline at end of file + run: python -m pytest --timeout=200 -n logical --pyargs kartograf From 583b0b23a5b9afd3ff8359d1a0f87c4822be0f21 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 10:31:39 -0800 Subject: [PATCH 03/10] add pytest to deps --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 44091cf..3cd49f3 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -101,7 +101,7 @@ jobs: python-version: 3.11 - name: install_deps - run: python -m pip install -U pip pipx wheel build + run: python -m pip install -U pip pipx wheel build pytest - name: build_package_sdist run: pipx run build --sdist From 8611efea691e096e11ab567ab4d34b406e3de46b Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 10:45:32 -0800 Subject: [PATCH 04/10] add pytest-xdist --- .github/workflows/ci.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3cd49f3..43845c4 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -101,7 +101,7 @@ jobs: python-version: 3.11 - name: install_deps - run: python -m pip install -U pip pipx wheel build pytest + run: python -m pip install -U pip pipx wheel build pytest pytest-xdist - name: build_package_sdist run: pipx run build --sdist @@ -122,4 +122,4 @@ jobs: - name: run tests working-directory: ./dist - run: python -m pytest --timeout=200 -n logical --pyargs kartograf + run: python -m pytest -n logical --pyargs kartograf From e44b81b0b2228d6e5d85f45256b71c2f28724130 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 12:05:01 -0800 Subject: [PATCH 05/10] install gufe w mamba instead of pip --- .github/workflows/ci.yaml | 5 ++++- pyproject.toml | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 43845c4..6ebc7b8 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -101,7 +101,9 @@ jobs: python-version: 3.11 - name: install_deps - run: python -m pip install -U pip pipx wheel build pytest pytest-xdist + run: | + python -m pip install -U pip pipx wheel build pytest pytest-xdist + mamba install gufe - name: build_package_sdist run: pipx run build --sdist @@ -116,6 +118,7 @@ jobs: run: | ls -a . python -m pip install kartograf-*.tar.gz + du -sh kartograf-*.tar.gz - name: check install run: pip list diff --git a/pyproject.toml b/pyproject.toml index 53dcfb6..7493b89 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,7 +14,6 @@ dependencies = [ 'scipy', 'numpy', 'dill', - 'gufe', ] description="Kartograf is a package for geometrically mapping atoms of two molecules." readme="README.md" @@ -55,4 +54,5 @@ license-files = ["LICENSE"] where = ['src'] [tool.setuptools.package-data] -kartograf = ["tests/data/*.pdb", "tests/data/*.sdf"] \ No newline at end of file +kartograf = ["tests/data/*.pdb", "tests/data/*.sdf"] + From aad934a01b3073dcbc7bc09af94465a5d6551492 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 13:51:22 -0800 Subject: [PATCH 06/10] micromamba call --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 6ebc7b8..6b9c629 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -103,7 +103,7 @@ jobs: - name: install_deps run: | python -m pip install -U pip pipx wheel build pytest pytest-xdist - mamba install gufe + micromamba install gufe - name: build_package_sdist run: pipx run build --sdist From 3fd57cbe4a41c992521c31c6b34734019861813d Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 14:01:12 -0800 Subject: [PATCH 07/10] create env from yml --- .github/workflows/ci.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 6b9c629..2f1adc7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -98,7 +98,8 @@ jobs: - uses: mamba-org/setup-micromamba@v1 with: - python-version: 3.11 + environment-file: environment.yml + environment-name: kartograf - name: install_deps run: | From 5e72753e57a45c8fd7b39992edceaeb0866a94e8 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Wed, 8 Jan 2025 14:10:51 -0800 Subject: [PATCH 08/10] removing redundant installs --- .github/workflows/ci.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 2f1adc7..c611d97 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -103,8 +103,7 @@ jobs: - name: install_deps run: | - python -m pip install -U pip pipx wheel build pytest pytest-xdist - micromamba install gufe + python -m pip install -U pip pipx wheel build - name: build_package_sdist run: pipx run build --sdist From 3cc14a6fef61f982c0b8a5f5e95ee230d5e6cfe5 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Fri, 10 Jan 2025 08:42:01 -0800 Subject: [PATCH 09/10] remove dist dir --- .github/workflows/ci.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c611d97..60f0763 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -114,7 +114,6 @@ jobs: test -n "${DISTRIBUTION}" || { echo "no distribution dist/kartograf-*.tar.gz found"; exit 1; } - name: install sdist - working-directory: ./dist run: | ls -a . python -m pip install kartograf-*.tar.gz From 61ee3adff6e5585f1d870017e5404f7176c4a051 Mon Sep 17 00:00:00 2001 From: Alyssa Travitz Date: Fri, 10 Jan 2025 08:47:40 -0800 Subject: [PATCH 10/10] Revert "remove dist dir" This reverts commit 3cc14a6fef61f982c0b8a5f5e95ee230d5e6cfe5. --- .github/workflows/ci.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 60f0763..c611d97 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -114,6 +114,7 @@ jobs: test -n "${DISTRIBUTION}" || { echo "no distribution dist/kartograf-*.tar.gz found"; exit 1; } - name: install sdist + working-directory: ./dist run: | ls -a . python -m pip install kartograf-*.tar.gz