Bump wheel from 0.37.1 to 0.38.1 in /requirements #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub Actions | |
on: | |
pull_request: | |
branches-ignore: | |
- "*no-ci" | |
push: | |
tags: | |
- "v*" | |
branches: | |
- master | |
- "release*" | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
env: | |
PACKAGE_NAME: ansys-dpf-post | |
MODULE: post | |
ANSYS_VERSION: 222 | |
jobs: | |
style: | |
name: Style Check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Python | |
uses: actions/setup-python@v4.2.0 | |
with: | |
python-version: 3.9 | |
- name: Install pre-commit | |
run: pip install pre-commit | |
- name: Run pre-commit | |
run: pre-commit run --all-files || ( git status --short ; git diff ; exit 1 ) | |
build_test: | |
name: Build and Test | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.7", "3.8", "3.9", "3.10"] | |
os: ["windows-latest", "ubuntu-latest"] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: "Build Package" | |
uses: pyansys/pydpf-actions/build_package@feat/use_build | |
with: | |
python-version: ${{ matrix.python-version }} | |
ANSYS_VERSION: ${{env.ANSYS_VERSION}} | |
PACKAGE_NAME: ${{env.PACKAGE_NAME}} | |
MODULE: ${{env.MODULE}} | |
dpf-standalone-TOKEN: ${{secrets.DPF_PIPELINE}} | |
install_extras: plotting | |
wheelhouse: true | |
- name: "Prepare Testing Environment" | |
uses: pyansys/pydpf-actions/prepare_tests@feat/use_build | |
with: | |
DEBUG: true | |
- name: "Test Docstrings" | |
uses: pyansys/pydpf-actions/test_docstrings@feat/use_build | |
with: | |
MODULE: ${{env.MODULE}} | |
PACKAGE_NAME: ${{env.PACKAGE_NAME}} | |
- name: "Test API" | |
shell: bash | |
working-directory: tests | |
run: | | |
pytest $DEBUG --cov=ansys.dpf.${{env.MODULE}} --cov-report=xml --cov-report=html --cov-append --log-level=ERROR --junitxml=junit/test-results.xml --reruns 2 . | |
- name: "Kill all servers" | |
uses: pyansys/pydpf-actions/kill-dpf-servers@feat/use_build | |
if: always() | |
- name: "Upload Test Results" | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ env.PACKAGE_NAME }}_${{ matrix.python-version }}_${{ matrix.os }}_pytest_${{ env.ANSYS_VERSION }} | |
path: tests/junit/test-results.xml | |
- name: "Upload coverage to Codecov" | |
uses: codecov/codecov-action@v3 | |
docs: | |
name: Documentation | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: "Build Documentation" | |
uses: pyansys/pydpf-actions/build_doc@feat/use_build | |
with: | |
python-version: "3.8" | |
ANSYS_VERSION: ${{env.ANSYS_VERSION}} | |
PACKAGE_NAME: ${{env.PACKAGE_NAME}} | |
MODULE: ${{env.MODULE}} | |
dpf-standalone-TOKEN: ${{secrets.DPF_PIPELINE}} | |
install_extras: plotting | |
debug: true | |
timeout-minutes: 30 | |
draft_release: | |
name: "Draft release" | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') | |
needs: [style, build_test, docs] | |
runs-on: ubuntu-latest | |
steps: | |
- name: "Set up Python" | |
uses: actions/setup-python@v4.1.0 | |
with: | |
python-version: 3.9 | |
- name: "Download artifacts" | |
uses: actions/download-artifact@v3 | |
- name: "Display downloaded files" | |
run: ls -R | |
- name: "Create draft release" | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
./**/*.whl | |
./**/*.tar.gz | |
./**/*.zip | |
draft: true | |
generate_release_notes: true | |
# - name: "Deploy to Test PyPi" | |
# run: | | |
# pip install twine | |
# twine upload --repository testpypi --skip-existing ./**/*.whl | |
# twine upload --repository testpypi --skip-existing ./**/*.tar.gz | |
# env: | |
# TWINE_USERNAME: __token__ | |
# TWINE_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }} |