Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 95bd98f

Browse filesBrowse files
committed
Test pairinteraction with dependencies with minimal versions, improve colab compatibility, use dependency groups instead of optional dependencies for development dependencies
1 parent 915c4c0 commit 95bd98f
Copy full SHA for 95bd98f
Expand file treeCollapse file tree

24 files changed

+64
-43
lines changed
Open diff view settings
Collapse file

‎.build_requirements.txt‎

Copy file name to clipboardExpand all lines: .build_requirements.txt
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22
scikit-build-core>=0.9.0
33
nanobind>=1.9.0
44
typing_extensions>=4.7
5-
numpy>=1.24
5+
numpy>=2.0.2
66
tbb-devel==2022.0.0; sys_platform != 'darwin'
77
mkl-devel==2025.0.1; sys_platform != 'darwin'
Collapse file

‎.github/actions/setup-uv-all-deps/action.yml‎

Copy file name to clipboardExpand all lines: .github/actions/setup-uv-all-deps/action.yml
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ runs:
99
using: "composite"
1010
steps:
1111
- name: Install uv
12-
uses: astral-sh/setup-uv@v6
12+
uses: astral-sh/setup-uv@v7
1313
with:
14-
version: "0.7"
14+
version: "0.9"
1515
python-version: ${{ inputs.python-version }}
1616
enable-cache: true
1717
cache-dependency-glob: |
1818
./pyproject.toml
1919
2020
- name: Install all Python dependencies into a virtual environment
2121
shell: bash
22-
run: uv sync --no-install-project --all-extras # always install all dependencies, this simplifies caching
22+
run: uv sync --no-install-project --group dev # always install all development dependencies, this simplifies caching
Collapse file

‎.github/actions/setup-uv-build-venv/action.yml‎

Copy file name to clipboardExpand all lines: .github/actions/setup-uv-build-venv/action.yml
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ runs:
44
using: "composite"
55
steps:
66
- name: Install uv
7-
uses: astral-sh/setup-uv@v6
7+
uses: astral-sh/setup-uv@v7
88
with:
99
version: "0.7"
1010
python-version: 3.12
Collapse file

‎.github/workflows/documentation.yml‎

Copy file name to clipboardExpand all lines: .github/workflows/documentation.yml
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
- name: Setup uv project virtual environment
2828
uses: ./.github/actions/setup-uv-all-deps
2929
- name: Install PairInteraction into virtual environment
30-
run: uv pip install .[docs]
30+
run: uv pip install . --group docs
3131
- name: Build documentation
3232
working-directory: docs/
3333
run: uv run --no-project make html SPHINXOPTS="-W --keep-going" # TODO also use -n in the future
@@ -47,7 +47,7 @@ jobs:
4747
- name: Setup uv project virtual environment
4848
uses: ./.github/actions/setup-uv-all-deps
4949
- name: Install PairInteraction into virtual environment
50-
run: uv pip install .[docs]
50+
run: uv pip install . --group docs
5151
- name: Setup 2nd virtual environment for other PairInteraction versions
5252
run: |
5353
uv venv tmp_venv --python=python3.11
@@ -70,7 +70,7 @@ jobs:
7070
- name: Setup uv project virtual environment
7171
uses: ./.github/actions/setup-uv-all-deps
7272
- name: Install PairInteraction into virtual environment
73-
run: uv pip install -Cbuild-dir=build --config-settings=cmake.define.WITH_COVERAGE=ON .[tests]
73+
run: uv pip install -Cbuild-dir=build --config-settings=cmake.define.WITH_COVERAGE=ON . --group tests
7474
- name: Run pytest
7575
run: uv run --no-project pytest
7676
- name: Generate Code Coverage HTML report
@@ -101,7 +101,7 @@ jobs:
101101
- name: Setup uv project virtual environment
102102
uses: ./.github/actions/setup-uv-all-deps
103103
- name: Install PairInteraction into virtual environment
104-
run: uv pip install -e .[tests] # -e is needed for coverage to work
104+
run: uv pip install -e . --group tests # -e is needed for coverage to work
105105
- name: Run pytest with coverage
106106
run: | # also run with --generate-reference to get 100% tests coverage and test the reference generation
107107
uv run --no-project coverage run --source=src,tests -m pytest
Collapse file

‎.github/workflows/mypy.yml‎

Copy file name to clipboardExpand all lines: .github/workflows/mypy.yml
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
- name: Setup uv project virtual environment
2727
uses: ./.github/actions/setup-uv-all-deps
2828
- name: Install PairInteraction into virtual environment
29-
run: uv pip install .[mypy]
29+
run: uv pip install . --group mypy
3030
- name: Install the benchmarking tool
3131
run: uv pip install tools/benchmarking[mypy]
3232
- name: Install the dbmanager tool
Collapse file

‎.github/workflows/python-wheel.yml‎

Copy file name to clipboardExpand all lines: .github/workflows/python-wheel.yml
+21-2Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,10 @@ jobs:
6767
- name: Install uv
6868
uses: astral-sh/setup-uv@v7
6969
with:
70-
version: "0.7"
70+
version: "0.9"
7171
enable-cache: true
7272
cache-dependency-glob: |
7373
./pyproject.toml
74-
./.build_requirements.txt
7574
7675
- uses: pypa/cibuildwheel@v3.3
7776
env:
@@ -85,6 +84,26 @@ jobs:
8584
name: dist-wheel-${{ matrix.os }}
8685
path: wheelhouse/*.whl
8786

87+
test-min-deps:
88+
name: Test with minimum dependency versions
89+
runs-on: ubuntu-latest
90+
container:
91+
image: ghcr.io/pairinteraction/pairinteraction-manylinux:docker
92+
steps:
93+
- uses: actions/checkout@v6
94+
95+
- name: Install uv
96+
uses: astral-sh/setup-uv@v7
97+
with:
98+
version: "0.9"
99+
python-version: "3.12"
100+
enable-cache: true
101+
cache-dependency-glob: |
102+
./pyproject.toml
103+
104+
- run: uv sync --group tests --resolution lowest-direct
105+
- run: uv run --no-sync pytest
106+
88107
test-install-from-sdist:
89108
strategy:
90109
fail-fast: false
Collapse file

‎.pre-commit-config.yaml‎

Copy file name to clipboardExpand all lines: .pre-commit-config.yaml
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ repos:
5252
rev: v1.15.0
5353
hooks:
5454
- id: mypy
55-
additional_dependencies: ["numpy >= 1.24", "typing_extensions >= 4.7", "pyside6 >= 6.8.2", "pyside6-stubs >= 6.7.3.0", "pint < 0.25.1", "attrs >= 24.0"] # FIXME: unpin pint when https://github.com/hgrecco/pint/issues/2245 is resolved (see also pyproject.toml)
55+
additional_dependencies: ["numpy >= 1.24", "typing_extensions >= 4.7", "pyside6 >= 6.8.2", "pyside6-stubs >= 6.7.3.0", "pint >= 0.24.4, < 0.25.1", "attrs >= 24.0"] # FIXME: unpin pint when https://github.com/hgrecco/pint/issues/2245 is resolved (see also pyproject.toml)
5656
args: ["--ignore-missing-imports"]
5757

5858
- repo: https://github.com/fsfe/reuse-tool
Collapse file

‎CMakeLists.txt‎

Copy file name to clipboardExpand all lines: CMakeLists.txt
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ not produce the desired result. If you are a user trying to install \
1515
this package, consider using the following install command inside \
1616
the root directory of the repository:
1717
=====================================================================
18-
$ pip install .[tests,docs]
18+
$ pip install . --group tests --group docs
1919
=====================================================================
2020
Where the arguments 'tests' (installs dependencies for running tests) \
2121
and 'docs' (installs dependencies for building the documentation) \
Collapse file

‎docs/contribute/getting_started.rst‎

Copy file name to clipboardExpand all lines: docs/contribute/getting_started.rst
+1-1Lines changed: 1 addition & 1 deletion
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ necessary steps:
9797

9898
.. code-block:: bash
9999
100-
pip install -e .[tests,docs]
100+
pip install -e . --group tests --group docs
101101
102102
Or, you can build solely the C++ backend using ``cmake``. This manual approach is recommended if you are planning to
103103
contribute to the C++ backend because it allows for a faster build and more fine-grained control.
Collapse file

‎docs/installation/advanced/documentation.rst‎

Copy file name to clipboardExpand all lines: docs/installation/advanced/documentation.rst
+1-1Lines changed: 1 addition & 1 deletion
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ In order to install all dependencies to smoothly run Sphinx_, you should first r
1111

1212
.. code-block:: bash
1313
14-
pip install .[docs]
14+
pip install . --group docs
1515
1616
In order to build the documentation once, you can run
1717

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.