mirror of
https://github.com/nqrduck/LimeDriverBindings.git
synced 2024-11-05 18:20:03 +00:00
Kumi
853457de78
Refactored the CI workflows to include package installation and import testing. Ensured package is importable after installation by creating a new '__main__.py' module to check imports. This adds an extra validation step to the CI process, catching potential import issues early. Import statements in '__init__.py' have also been updated to use 'as' for clarity and namespace control.
43 lines
No EOL
893 B
YAML
43 lines
No EOL
893 B
YAML
name: Python package build on Arch Linux
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
container:
|
|
image: archlinux:latest
|
|
options: --privileged
|
|
|
|
steps:
|
|
- name: Install git
|
|
run: |
|
|
yes | pacman -Sy git
|
|
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
with:
|
|
submodules: 'recursive'
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
yes | pacman -S python python-pip hdf5 limesuite python-build automake gcc pkgconf base-devel
|
|
|
|
- name: Install the package
|
|
run: |
|
|
pip install .
|
|
|
|
- name: Test if the package can be imported
|
|
run: |
|
|
python -m limedriver
|
|
|
|
- name: Build the package
|
|
run: |
|
|
python -m build
|
|
|
|
- name: Upload built packages as artifact
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: built-package
|
|
path: dist/ |