From ed64970a9d1a38afd618a593120809c0e311d943 Mon Sep 17 00:00:00 2001 From: qianduoduo0904 <109654808+qianduoduo0904@users.noreply.github.com> Date: Thu, 9 Mar 2023 15:57:15 +0800 Subject: [PATCH] Fix build wheel (#8) Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- .github/workflows/build-wheel.yaml | 17 ++--------------- CI/requirements-wheel.txt | 2 +- python/pyproject.toml | 2 +- python/setup.cfg | 3 ++- 4 files changed, 6 insertions(+), 18 deletions(-) diff --git a/.github/workflows/build-wheel.yaml b/.github/workflows/build-wheel.yaml index 4f014632..c85e10ae 100644 --- a/.github/workflows/build-wheel.yaml +++ b/.github/workflows/build-wheel.yaml @@ -54,21 +54,13 @@ jobs: with: platforms: all - - name: Build web - if: ${{ matrix.os == 'ubuntu-latest' }} - run: | - pip install -r CI/requirements-wheel.txt - cd python && python setup.py build_web - - name: Build wheels uses: pypa/cibuildwheel@v2.11.3 env: - CIBW_ENVIRONMENT_LINUX: NO_WEB_UI=1 - CIBW_ENVIRONMENT_PASS_LINUX: NO_WEB_UI CIBW_ARCHS: ${{ matrix.arch }} CIBW_PROJECT_REQUIRES_PYTHON: ${{ matrix.requires-python }} - CIBW_BEFORE_BUILD_MACOS: pip install -r CI/requirements-wheel.txt && cd python && python setup.py build_web - CIBW_BEFORE_BUILD_WINDOWS: pip install -r CI/requirements-wheel.txt && cd python && python setup.py build_web + CIBW_BEFORE_BUILD_MACOS: pip install -r CI/requirements-wheel.txt + CIBW_BEFORE_BUILD_WINDOWS: pip install -r CI/requirements-wheel.txt CIBW_TEST_COMMAND: pytest {project}/CI/test_functionality.py CIBW_TEST_REQUIRES: pytest requests CIBW_BUILD_VERBOSITY: 1 @@ -88,11 +80,6 @@ jobs: fetch-depth: 0 submodules: recursive - - name: Build web - run: | - pip install -r CI/requirements-wheel.txt - cd python && python setup.py build_web - - name: Build sdist run: cd python && pipx run build --sdist diff --git a/CI/requirements-wheel.txt b/CI/requirements-wheel.txt index 77bec8dc..ab14a7bc 100644 --- a/CI/requirements-wheel.txt +++ b/CI/requirements-wheel.txt @@ -3,7 +3,7 @@ oldest-supported-numpy pandas==1.0.4; python_version<'3.9' and platform_machine!='aarch64' pandas==1.1.3; python_version<'3.9' and platform_machine=='aarch64' pandas==1.2.2; python_version>='3.9' and python_version<'3.10' -pandas==1.3.4; python_version>='3.10' and python_version<'3.11'" +pandas==1.3.4; python_version>='3.10' and python_version<'3.11' pandas==1.5.0; python_version>='3.11' scipy==1.4.1; python_version<'3.9' and platform_machine!='aarch64' diff --git a/python/pyproject.toml b/python/pyproject.toml index ff5043e9..c8e4f00f 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -33,5 +33,5 @@ markers = [ [tool.cibuildwheel] build = ["cp38-*", "cp39-*", "cp310-*", "cp311-*"] -skip = "pp* *musllinux* *i686 cp36* cp310-win32" +skip = "pp* *musllinux* *i686 cp36* cp310-win32 cp311-win32" manylinux-x86_64-image = "manylinux2014" diff --git a/python/setup.cfg b/python/setup.cfg index 9ee4c58b..64bfc701 100644 --- a/python/setup.cfg +++ b/python/setup.cfg @@ -26,7 +26,8 @@ packages = find: install_requires = numpy>=1.14.0 pandas>=1.0.0 - scipy>=1.0.0 + scipy>=1.0.0; sys_platform!="win32" or python_version>="3.10" + scipy>=1.0.0,<=1.9.1; sys_platform=="win32" and python_version<"3.10" cloudpickle>=1.5.0 psutil>=5.9.0 tblib>=1.7.0