这是indexloc提供的服务,不要输入任何密码
Skip to content

[DOC] Update version to 0.3.7 #2566

[DOC] Update version to 0.3.7

[DOC] Update version to 0.3.7 #2566

Workflow file for this run

name: Build
on: [push, pull_request, workflow_dispatch]
jobs:
build_wheels:
name: Build wheel on ${{ matrix.os }} - py ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-20.04, macos-12 ]
python-version: ["3.8", "3.9", "3.10", "3.11"]
include:
- os: ubuntu-20.04
python-version: "3.8"
cibw-build: "cp38-manylinux_x86_64"
- os: ubuntu-20.04
python-version: "3.9"
cibw-build: "cp39-manylinux_x86_64"
- os: ubuntu-20.04
python-version: "3.10"
cibw-build: "cp310-manylinux_x86_64"
- os: ubuntu-20.04
python-version: "3.11"
cibw-build: "cp311-manylinux_x86_64"
- os: macos-12
python-version: "3.8"
cibw-build: "cp38-macosx_x86_64"
- os: macos-12
python-version: "3.9"
cibw-build: "cp39-macosx_x86_64"
- os: macos-12
python-version: "3.10"
cibw-build: "cp310-macosx_x86_64"
- os: macos-12
python-version: "3.11"
cibw-build: "cp311-macosx_x86_64"
steps:
- uses: actions/checkout@v3
- name: Cache brew dependencies
if: runner.os == 'macOS'
uses: actions/cache@v3.3.2
with:
# Paths to cache:
# /usr/local/Homebrew - installation folder of Homebrew
# /usr/local/Cellar - installation folder of Homebrew formulae
# /usr/local/Frameworks, /usr/local/bin, /usr/local/opt - contain (links to) binaries installed by Homebrew formulae
path: |
/usr/local/Homebrew
/usr/local/Cellar
/usr/local/Frameworks
/usr/local/bin
/usr/local/opt
key: macos-12-build-cache-${{ hashFiles('./scripts/macos/brew_dependencies.sh') }}-v2
# need to make this an intermediate step, i.e. build first the different lambda runners on Ubuntu...
- name: Build Lambda runner (Linux only)
if: runner.os != 'macOS'
run: docker pull registry-1.docker.io/tuplex/ci:${{ matrix.python-version }} && export PYTHON3_VERSION=${{ matrix.python-version }}.0 && bash ./scripts/create_lambda_zip.sh && mkdir -p ./tuplex/python/tuplex/other && cp ./build-lambda/tplxlam.zip ./tuplex/python/tuplex/other
shell: bash
- name: Build wheel
#if: runner.os != 'macOS'
uses: pypa/cibuildwheel@fff9ec32ed25a9c576750c91e06b410ed0c15db7 # hash corresponds to v2.16.2
env:
# configure cibuildwheel to build native archs ('auto'), and some
# emulated ones
CIBW_ARCHS_LINUX: native
CIBW_MANYLINUX_X86_64_IMAGE: "registry-1.docker.io/tuplex/ci:${{ matrix.python-version }}"
CIBW_BUILD: ${{ matrix.cibw-build }}
# macOS dependencies separate, for linux use docker tuplex/ci:3.x images.
CIBW_BEFORE_ALL_MACOS: bash ./scripts/macos/install_antlr4_cpp_runtime.sh && bash ./scripts/macos/brew_dependencies.sh && bash ./scripts/macos/install_aws-sdk-cpp.sh && echo 'export PATH="/usr/local/opt/openjdk@11/bin:$PATH"' >> /Users/runner/.bash_profile
# bundle aws runner with linux wheel, remove environment variable TUPLEX_LAMBDA_ZIP to remove runner.
CIBW_ENVIRONMENT_LINUX: "TUPLEX_LAMBDA_ZIP='./tuplex/python/tuplex/other/tplxlam.zip' CMAKE_ARGS='-DBUILD_WITH_AWS=ON -DBUILD_WITH_ORC=ON' LD_LIBRARY_PATH=/usr/local/lib:/opt/lib"
# requires macOS 10.13 at least to build because of C++17 features.
CIBW_ENVIRONMENT_MACOS: "CMAKE_ARGS='-DBUILD_WITH_AWS=ON -DBUILD_WITH_ORC=ON' JAVA_HOME=${JAVA_HOME_11_X64}"
# run all python tests to make sure wheels are not defunct
CIBW_TEST_REQUIRES: "pytest pytest-timeout numpy nbformat jupyter"
# use 3min timeout per test and print top 25 slowest tests
CIBW_TEST_COMMAND: "cd {project} && pytest tuplex/python/tests -v --timeout 600 --durations 25"
- name: reorganize files
run: touch ./scripts/dummy.version && cp ./scripts/*.version ./wheelhouse && cp ./.github/scripts/test_pypi.sh ./wheelhouse
- uses: actions/upload-artifact@v3
with:
path: |
./wheelhouse/*.whl