diff --git a/.github/workflows/publish-sdist-wheels.yml b/.github/workflows/publish-sdist-wheels.yml index de244a375..faac0779d 100644 --- a/.github/workflows/publish-sdist-wheels.yml +++ b/.github/workflows/publish-sdist-wheels.yml @@ -4,9 +4,10 @@ on: [pull_request, push] env: CIBW_BUILD_VERBOSITY: 3 CIBW_BUILD: 'cp*' - CIBW_SKIP: 'cp35-* cp36-* *-manylinux_i686 *-musllinux_* *-win32 cp311-macosx_x86_64' + CIBW_SKIP: 'cp35-* cp36-* cp37-* *-manylinux_i686 *-musllinux_* *-win32 cp311-macosx_x86_64' CIBW_BEFORE_TEST: pip install -r {project}/tests/requirement_tests.txt CIBW_TEST_COMMAND: pytest -s -v {project}/tests + WINDOWS_HDF5: 1.14.2 jobs: build_wheels: @@ -89,6 +90,24 @@ jobs: run: | python -m cibuildwheel --output-dir dist + - name: Cache HDF5 On Windows + if: runner.os == 'Windows' + id: cache-hdf5-windows + uses: actions/cache@v3 + env: + cache-name: cache-hdf5-windows + with: + path: C:\cache\hdf5\${{ env.WINDOWS_HDF5 }} + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ env.WINDOWS_HDF5 }} + + - name: Fill Windows Cache + if: runner.os == 'Windows' && steps.cache-hdf5-windows.outputs.cache-hit != 'true' + continue-on-error: false + shell: cmd + run: | + mkdir C:\cache\hdf5\${{ env.WINDOWS_HDF5 }} + curl -L -o C:\cache\hdf5\${{ env.WINDOWS_HDF5 }}\hdf5.zip https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.14/hdf5-1.14.2/bin/windows/hdf5-1.14.2-Std-win10_64-vs16.zip + - name: Build wheels Windows if: runner.os == 'Windows' shell: cmd @@ -99,13 +118,12 @@ jobs: # this has a partial table: # https://devblogs.microsoft.com/cppblog/side-by-side-minor-version-msvc-toolsets-in-visual-studio-2017/ run: | - curl -O https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.12/hdf5-1.12.0/bin/hdf5-1.12.0-Std-win10_64-vs16.zip - C:\windows\system32\tar.exe xf hdf5-1.12.0-Std-win10_64-vs16.zip - start /wait msiexec /a "%cd%\hdf\HDF5-1.12.0-win64.msi" /qn TARGETDIR="c:\hdf5\" + C:\windows\system32\tar.exe xf C:\cache\hdf5\${{ env.WINDOWS_HDF5 }}\hdf5.zip + start /wait msiexec /a "%cd%\hdf\HDF5-${{ env.WINDOWS_HDF5 }}-win64.msi" /qn TARGETDIR="c:\hdf5\" call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat" -vcvars_ver=14.1 - set HDF5_DIR=C:\hdf5\HDF_Group\HDF5\1.12.0\cmake + set HDF5_DIR=C:\hdf5\HDF_Group\HDF5\${{ env.WINDOWS_HDF5 }}\cmake python -m cibuildwheel --output-dir dist @@ -125,10 +143,10 @@ jobs: with: submodules: 'true' - - name: Set up Python 3.7 + - name: Set up Python 3.8 uses: actions/setup-python@v4 with: - python-version: 3.7 + python-version: 3.8 - name: Build a source tarball run: diff --git a/morphio/__init__.py b/morphio/__init__.py index 35a043cc1..db51f951a 100644 --- a/morphio/__init__.py +++ b/morphio/__init__.py @@ -6,8 +6,8 @@ # there cannot be a mismatch between version, when using windows, # and MorphIO doesn't need to build hdf5 import h5py as _h5py - if (1, 12) != _h5py.version.hdf5_version_tuple[:2]: - raise RuntimeError(f'HDF5 library version mismatch. 1.12.x != {_h5py.version.hdf5_version}') + if (1, 14) != _h5py.version.hdf5_version_tuple[:2]: + raise RuntimeError(f'HDF5 library version mismatch. 1.14.x != {_h5py.version.hdf5_version}') del _h5py diff --git a/setup.py b/setup.py index f73979562..a1b73a165 100644 --- a/setup.py +++ b/setup.py @@ -97,5 +97,5 @@ def build_extension(self, ext): setup_requires=[ 'setuptools_scm', ], - python_requires=">=3.7", + python_requires=">=3.8", )