Skip to content

Commit cbca817

Browse files
rimoliclaude
andcommitted
Test an installation without the pins of requirements.txt
Every test job installed requirements.txt before the package, and its pins hid the versions that install_requires resolves to, so CI could not see that pip installed 1.6.0 with numpy 2.5 and MeshPy 2026.1, with which 13 tests fail. One more job, Python 3.12 on Ubuntu, now skips requirements.txt and installs the package alone, as pip install microstructpy does. It does not upload coverage, which the pinned job of the same Python and system already reports. The changelog also corrects its note on Python 3.13 and later: numpy below 2 has no wheels there, but pip builds it from source. On Python 3.14 that takes under a minute, and all the tests pass. Suggested by Kip Hart in the review of PR #120. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 9605f34 commit cbca817

2 files changed

Lines changed: 19 additions & 3 deletions

File tree

‎.github/workflows/python_package.yaml‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,22 @@ on: [push]
44

55
jobs:
66
pytest:
7-
name: pytest for py${{ matrix.python-version }} on ${{ matrix.os }}
7+
name: pytest for py${{ matrix.python-version }} on ${{ matrix.os }}${{ matrix.unpinned && ', unpinned' || '' }}
88

99
runs-on: ${{ matrix.os }}
1010
strategy:
1111
fail-fast: false
1212
matrix:
1313
python-version: [3.9, '3.10', '3.11', '3.12']
1414
os: ['ubuntu-latest', 'macos-latest', 'windows-latest']
15+
unpinned: [false]
16+
include:
17+
# One job installs the package without the pins of
18+
# requirements.txt, as pip install microstructpy does, so that the
19+
# tests see the dependency versions that users get.
20+
- python-version: '3.12'
21+
os: 'ubuntu-latest'
22+
unpinned: true
1523

1624
steps:
1725
- uses: actions/checkout@main
@@ -33,6 +41,7 @@ jobs:
3341
pip install setuptools wheel
3442
pip install flake8 pytest pytest-cov coveralls
3543
- name: Install package requirements
44+
if: ${{ !matrix.unpinned }}
3645
run: pip install -r requirements.txt
3746
- name: Install package
3847
run: pip install -e .
@@ -47,6 +56,7 @@ jobs:
4756
run: pytest --cov=src tests/
4857

4958
- name: Coveralls
59+
if: ${{ !matrix.unpinned }}
5060
env:
5161
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
5262
COVERALLS_FLAG_NAME: py${{ matrix.python-version }} on ${{ matrix.os }}

‎CHANGELOG.rst‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,14 @@ Fixed
1515
the text files of the meshes cannot be read back, since numpy writes
1616
integers as ``np.int64(4)``, and ``tangent_sphere`` fails. With MeshPy
1717
2026, TetGen no longer keeps the elements of 3D meshes under
18-
``max_volume``. numpy below 2 has no releases for Python 3.13 and later,
19-
which MicroStructPy does not support yet.
18+
``max_volume``. numpy below 2 has no wheels for Python 3.13 and later, so
19+
pip builds it from source there, which needs a compiler.
20+
21+
Changed
22+
'''''''
23+
- The continuous integration also runs the tests on an installation without
24+
the pins of ``requirements.txt``, as ``pip install microstructpy`` does, so
25+
that it sees the dependency versions that users get.
2026

2127
`1.6.0`_ - 2026-10-18
2228
--------------------------

0 commit comments

Comments
 (0)