|
|
name: Python |
|
|
|
|
|
on: |
|
|
push: |
|
|
branches: |
|
|
- master |
|
|
paths: |
|
|
- ".github/workflows/build_python.yml" |
|
|
- "**.cpp" |
|
|
- "**.h" |
|
|
- "**.c" |
|
|
- "**.cu" |
|
|
- "**.cmake" |
|
|
- "**CMakeLists.txt" |
|
|
- "**py" |
|
|
pull_request: |
|
|
branches: |
|
|
- master |
|
|
paths: |
|
|
- ".github/workflows/build_python.yml" |
|
|
- "**.cpp" |
|
|
- "**.h" |
|
|
- "**.c" |
|
|
- "**.cu" |
|
|
- "**.cmake" |
|
|
- "**CMakeLists.txt" |
|
|
- "**py" |
|
|
|
|
|
defaults: |
|
|
run: |
|
|
shell: bash |
|
|
|
|
|
jobs: |
|
|
Windows: |
|
|
runs-on: 'windows-latest' |
|
|
steps: |
|
|
- uses: actions/checkout@v3 |
|
|
- uses: actions/setup-python@v4 |
|
|
- name: Install python deps |
|
|
run: | |
|
|
pip install pytest numpy |
|
|
# don't use CMake 3.25.0 https://gitlab.kitware.com/cmake/cmake/-/issues/23975 |
|
|
pip3 install cmake==3.24.0 |
|
|
- name: Build |
|
|
run: | |
|
|
pip3 install cmake==3.24.0 |
|
|
python setup.py build |
|
|
python setup.py install --user |
|
|
- name: Test |
|
|
run: python -m pytest --ignore docs --ignore dlib |
|
|
|
|
|
Ubuntu: |
|
|
runs-on: 'ubuntu-latest' |
|
|
steps: |
|
|
- uses: actions/checkout@v3 |
|
|
- uses: actions/setup-python@v4 |
|
|
- name: Install python deps |
|
|
run: pip install pytest numpy |
|
|
- name: Build |
|
|
run: | |
|
|
python setup.py build |
|
|
python setup.py install --user |
|
|
- name: Test |
|
|
run: python -m pytest --ignore docs --ignore dlib |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|