sync rbufrp
This commit is contained in:
parent
32b0e9b8ed
commit
602b0b3964
32
.github/workflows/ci.yml
vendored
32
.github/workflows/ci.yml
vendored
@ -70,10 +70,12 @@ jobs:
|
||||
|
||||
- name: Rust Tests
|
||||
if: matrix.conf.target == 'x86_64' && !startsWith(matrix.python-version, 'pypy') && matrix.python-version == '3.12'
|
||||
working-directory: rbufr
|
||||
run: cargo test
|
||||
|
||||
- name: Build wheel (OSX - Linux)
|
||||
if: runner.os != 'Windows'
|
||||
working-directory: rbufrp
|
||||
uses: PyO3/maturin-action@v1
|
||||
with:
|
||||
target: ${{ matrix.conf.target }}
|
||||
@ -82,6 +84,7 @@ jobs:
|
||||
|
||||
- name: Build wheel (Windows)
|
||||
if: runner.os == 'Windows'
|
||||
working-directory: rbufrp
|
||||
run: |
|
||||
python -m pip install maturin delvewheel
|
||||
maturin build -i python --release --out wheels --target ${{ matrix.conf.target-triple }}
|
||||
@ -91,16 +94,12 @@ jobs:
|
||||
- name: Install built wheel and Test (Native)
|
||||
# TODO: I'm not sure but the actual collection of tests on windows using pypy3.10 takes forever and/or fails
|
||||
if: |
|
||||
!startsWith(matrix.conf.manylinux, 'musl') &&
|
||||
!startsWith(matrix.conf.manylinux, 'musl') &&
|
||||
!( matrix.python-version == 'pypy3.10' && runner.os == 'Windows' ) &&
|
||||
( matrix.conf.target == 'x86_64' || matrix.conf.target == 'universal2' )
|
||||
run: |
|
||||
# Second install guarantees it's going to install from local dir w/ --no-index
|
||||
# use first to get in dev dependencies
|
||||
python -m pip install cramjam[dev] --pre --find-links dist --force-reinstall
|
||||
python -m pip install cramjam --pre --no-index --find-links dist --force-reinstall
|
||||
|
||||
python -m pytest -vs --benchmark-skip -n0 --dist no
|
||||
python -m pip install rbufrp --pre --find-links rbufrp/dist --force-reinstall
|
||||
python -c "import rbufrp; print(rbufrp.__version__)"
|
||||
|
||||
# Could use 'distro: alpine_latest' in 'run-on-arch-action' but seems difficult to install a specific version of python
|
||||
# so we'll just use existing python alpine images to test import and cli use w/o testing archs other than x86_64
|
||||
@ -109,9 +108,9 @@ jobs:
|
||||
if: startsWith(matrix.conf.manylinux, 'musl') && matrix.conf.target == 'x86_64' && !startsWith(matrix.python-version, '3.14')
|
||||
run: |
|
||||
docker run \
|
||||
-v $(pwd)/dist:/wheels \
|
||||
-v $(pwd)/rbufrp/dist:/wheels \
|
||||
--rm python:${{ matrix.python-version }}-alpine sh \
|
||||
-c "pip install cramjam --no-index --find-links /wheels && python -c 'import cramjam'"
|
||||
-c "pip install rbufrp --no-index --find-links /wheels && python -c 'import rbufrp'"
|
||||
|
||||
# xref: https://github.com/milesgranger/cramjam/issues/194
|
||||
# - name: Install built wheel and Test (Cross)
|
||||
@ -140,15 +139,15 @@ jobs:
|
||||
# PYTHON=python${{ matrix.python-version }}
|
||||
# $PYTHON -m venv venv
|
||||
# venv/bin/pip install -U pip
|
||||
# venv/bin/pip install cramjam --pre --no-index --find-links /artifacts --force-reinstall
|
||||
# venv/bin/python -c 'import cramjam'
|
||||
# venv/bin/pip install rbufrp --pre --no-index --find-links /artifacts --force-reinstall
|
||||
# venv/bin/python -c 'import rbufrp'
|
||||
|
||||
- name: Upload wheels
|
||||
uses: actions/upload-artifact@v4
|
||||
if: ${{ ( startsWith(github.ref, 'refs/heads/master') || startsWith(github.ref, 'refs/tags/') ) }}
|
||||
with:
|
||||
name: ${{ matrix.conf.os }}-${{ matrix.python-version }}-${{ matrix.conf.target-triple }}-${{ matrix.conf.target }}
|
||||
path: dist
|
||||
path: rbufrp/dist
|
||||
|
||||
|
||||
build-sdist:
|
||||
@ -159,15 +158,16 @@ jobs:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: 3.12
|
||||
- name: Build sdist cramjam
|
||||
- name: Build sdist rbufrp
|
||||
working-directory: rbufrp
|
||||
run: |
|
||||
python -m pip install build
|
||||
python -m build --sdist -o ./dist
|
||||
python -m pip install maturin
|
||||
maturin sdist --out dist
|
||||
- name: Upload sdists
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: sdist
|
||||
path: dist
|
||||
path: rbufrp/dist
|
||||
|
||||
gh-publish:
|
||||
name: Publish artifacts to GH
|
||||
|
||||
Loading…
Reference in New Issue
Block a user