Skip to content

update get files for openlab. Files are now sorted #43

update get files for openlab. Files are now sorted

update get files for openlab. Files are now sorted #43

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: write # needed for gh release upload
jobs:
build:
name: Build and Test Package
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ["3.14"]
os: [ubuntu-latest]
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Cache Python Dependencies
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ matrix.python-version }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install Build Tools
run: |
python -m pip install --upgrade pip build
python -m pip install pybind11
- name: Lint Code
uses: wearerequired/lint-action@v2.3.0
with:
linters: |
pylint
- name: Build Wheel
run: |
python -m build --wheel
ls -al dist
- name: Upload Built Wheels (artifact)
uses: actions/upload-artifact@v4
with:
name: binaryparser-wheels
path: dist/*.whl
if-no-files-found: error
- name: Ensure release exists
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release view v1.1.0 >/dev/null 2>&1 || gh release create v1.1.0 -t "v1.1.0" -n ""
- name: Upload Release Asset(s)
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
ls -al dist
gh release upload v1.1.0 dist/*cp314*.whl --clobber
- name: Install Built Package
run: pip install dist/*.whl
- name: Run Tests
# Remove PYTHONPATH so tests import the installed wheel, not files from the repo root
run: |
python -m pip install pytest
pytest tests/
- name: Show Python Environment (Debug)
if: failure()
run: |
python --version
pip list
ls -R