Skip to content

chore: update CI workflows to ansys/actions v10 #3959

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 22 additions & 21 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ on:
env:
ON_CI: True
PROJECT_NAME: 'PyMAPDL'
MAIN_PYTHON_VERSION: '3.12'
PACKAGE_NAME: 'ansys-mapdl-core'
PACKAGE_NAMESPACE: 'ansys.mapdl.core'
DOCUMENTATION_CNAME: 'mapdl.docs.pyansys.com'
Expand Down Expand Up @@ -52,7 +53,7 @@ jobs:
contents: write
pull-requests: write
steps:
- uses: ansys/actions/doc-deploy-changelog@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
- uses: ansys/actions/doc-deploy-changelog@main
with:
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
Expand All @@ -65,7 +66,7 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: Check pull-request name
uses: ansys/actions/check-pr-title@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/check-pr-title@main
with:
token: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -78,7 +79,7 @@ jobs:
folder: ["doc", "examples"]
steps:
- name: "Ansys documentation style checks"
uses: ansys/actions/doc-style@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/doc-style@main
with:
token: ${{ secrets.GITHUB_TOKEN }}
files: ${{ matrix.folder }}
Expand All @@ -95,7 +96,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ['3.10', '3.11', '3.12', '3.13']
python-version: ['3.10', '3.11', '3.12']
# Only perform wheelhouse builds for macOS when releasing
should-release:
- ${{ github.event_name == 'push' && contains(github.ref, 'refs/tags') }}
Expand All @@ -104,28 +105,32 @@ jobs:
os: macos-latest
steps:
- name: "Build wheelhouse and perform smoke test"
uses: ansys/actions/build-wheelhouse@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
id: build-wheelhouse
uses: ansys/actions/build-wheelhouse@main
with:
library-name: ${{ env.PACKAGE_NAME }}
operating-system: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
check-licenses: true
# whitelist-license-check: "attrs" # This has MIT license but fails the check

- name: "Importing library"
run: python -c "from ansys.mapdl import core as pymapdl; print(pymapdl.Report())"
run: |
${{ steps.build-wheelhouse.outputs.activate-venv }}
python -c "from ansys.mapdl import core as pymapdl; print(pymapdl.Report())"

- name: "Checking plotting support"
run: python -c "from pyvista.plotting import system_supports_plotting; print('System support plotting ' + str(system_supports_plotting()))"
run: |
${{ steps.build-wheelhouse.outputs.activate-venv }}
python -c "from pyvista.plotting import system_supports_plotting; print('System support plotting ' + str(system_supports_plotting()))"


check-vulnerabilities:
name: "Check library vulnerabilities"
runs-on: ubuntu-22.04
steps:
- uses: ansys/actions/check-vulnerabilities@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
- uses: ansys/actions/check-vulnerabilities@main
with:
python-version: '3.13'
python-version: ${{ env.MAIN_PYTHON_VERSION }}
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
python-package-name: ${{ env.PACKAGE_NAME }}
dev-mode: ${{ github.ref != 'refs/heads/main' }}
Expand Down Expand Up @@ -178,7 +183,6 @@ jobs:
with:
mapdl-version: "${{ matrix.mapdl-version }}"
file-name: "${{ matrix.mapdl-version }}-remote"
python-version: '3.13'


build-test-local-matrix:
Expand Down Expand Up @@ -220,7 +224,6 @@ jobs:
file-name: "${{ matrix.mapdl-version }}-local"
tags: "local"
latest-version: "252"
python-version: '3.13'
test_dpf: ${{ contains(matrix.mapdl-version, 'cicd') }}


Expand All @@ -245,7 +248,6 @@ jobs:
file-name: "${{ matrix.mapdl-version }}-minimal"
tags: "local,minimal"
latest-version: "252"
python-version: '3.13'
test_dpf: false


Expand All @@ -269,7 +271,6 @@ jobs:
testing-minimal: false
on-console: true
pytest-arguments: '-k console'
python-version: '3.13'
file-name: "${{ matrix.mapdl-version }}-console"
tags: "local,console"
test_dpf: false
Expand Down Expand Up @@ -298,10 +299,10 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: "Build library source and wheel artifacts"
uses: ansys/actions/build-library@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/build-library@main
with:
library-name: ${{ env.PACKAGE_NAME }}
python-version: '3.13'
python-version: ${{ env.MAIN_PYTHON_VERSION }}


release:
Expand All @@ -316,7 +317,7 @@ jobs:
contents: write
steps:
- name: "Download the library artifacts from build-library step"
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
uses: actions/download-artifact@95815c38cf2ff2164869cbab79da8d1f422bc89e # v4.2.1
with:
name: ${{ env.PACKAGE_NAME }}-artifacts
path: ${{ env.PACKAGE_NAME }}-artifacts
Expand All @@ -333,7 +334,7 @@ jobs:
skip-existing: false

- name: "Release to GitHub"
uses: ansys/actions/release-github@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/release-github@main
with:
library-name: ${{ env.PACKAGE_NAME }}
additional-artifacts: "minimum_requirements.txt"
Expand All @@ -347,7 +348,7 @@ jobs:
needs: [release]
steps:
- name: "Deploy the stable documentation"
uses: ansys/actions/doc-deploy-stable@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/doc-deploy-stable@main
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -363,7 +364,7 @@ jobs:
needs: [docs-build]
steps:
- name: "Deploy the latest documentation"
uses: ansys/actions/doc-deploy-dev@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/doc-deploy-dev@main
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -418,4 +419,4 @@ jobs:
- name: "Run Pytest-summary action"
uses: ./.github/actions/pytest-summary
with:
python-version: '3.13'
python-version: ${{ env.MAIN_PYTHON_VERSION }}
2 changes: 1 addition & 1 deletion .github/workflows/docker_clean_untagged.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
steps:

- name: "Perform versions cleanup - except certain tags"
uses: ansys/actions/hk-package-clean-untagged@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
uses: ansys/actions/hk-package-clean-untagged@main
with:
package-name: 'mapdl'
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: ansys/actions/doc-changelog@5dc39c7838f50142138f7ac518ff3e4dca065d97 # v9.0.12
- uses: ansys/actions/doc-changelog@main
with:
bot-user: ${{ secrets.PYANSYS_CI_BOT_USERNAME }}
bot-email: ${{ secrets.PYANSYS_CI_BOT_EMAIL }}
Expand Down
1 change: 1 addition & 0 deletions doc/changelog.d/3959.maintenance.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Chore: update ci workflows to ansys/actions v10