diff --git a/.github/workflows/ci_cd.yml b/.github/workflows/ci_cd.yml index 2d148deb6..581e29092 100644 --- a/.github/workflows/ci_cd.yml +++ b/.github/workflows/ci_cd.yml @@ -102,7 +102,7 @@ jobs: env: ANSYSLMD_LICENSE_FILE: 1055@${{ secrets.LICENSE_SERVER }} run: | - docker run --detach --name speos-rpc -p 127.0.0.1:50098:50098 -e SPEOS_LOG_LEVEL=2 -e ANSYSLMD_LICENSE_FILE=${{ env.ANSYSLMD_LICENSE_FILE }} -v "${{ github.workspace }}/tests/assets:/app/assets" --entrypoint /app/SpeosRPC_Server.x ghcr.io/ansys/speos-rpc:dev --transport_insecure --host 0.0.0.0 + docker run --detach --name speos-rpc -p 127.0.0.1:50098:50098 -e SPEOS_LOG_LEVEL=2 -e ANSYSLMD_LICENSE_FILE=${{ env.ANSYSLMD_LICENSE_FILE }} -v "${{ github.workspace }}/tests/assets:/app/assets" --entrypoint /app/SpeosRPC_Server.x ghcr.io/ansys/speos-rpc:dev --transport_insecure -m 25000000 --host 0.0.0.0 - name: "Run Ansys documentation building action" uses: ansys/actions/doc-build@41f86da4c9ead510db9135e428e33df9cc6f92e1 # v10.2.3 with: @@ -127,11 +127,8 @@ jobs: steps: - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - - name: Installing OS packages - shell: bash - run: | - sudo apt-get update - sudo apt install -y libgl1 libglx-mesa0 xvfb libgomp1 + - name: Set up headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 - name: Set up Python uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0 @@ -171,7 +168,7 @@ jobs: shell: bash run: | . .venv/bin/activate - xvfb-run pytest -xs + pytest -xs - name: Upload Coverage Results if: always() diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 30d986b4c..761237d53 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -22,11 +22,8 @@ jobs: steps: - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - - name: Installing OS packages - shell: bash - run: | - sudo apt-get update - sudo apt install -y libgl1 libglx-mesa0 xvfb libgomp1 + - name: Set up headless display + uses: pyvista/setup-headless-display-action@7d84ae825e6d9297a8e99bdbbae20d1b919a0b19 # v4.2 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0 diff --git a/doc/Makefile b/doc/Makefile index c43ba4e1b..c425063e6 100755 --- a/doc/Makefile +++ b/doc/Makefile @@ -14,18 +14,9 @@ help: .PHONY: help Makefile -.install-ci-dep: - @pip freeze | grep -q "vtk-osmesa" && is_vtk_osmesa_installed="yes" || is_vtk_osmesa_installed="no" - @if [ "${ON_CI}" = "true" ] && [ "$$is_vtk_osmesa_installed" != "yes" ]; then \ - @echo "Removing package(s) to avoid conflicts with package(s) needed for CI/CD"; \ - pip uninstall --yes vtk; \ - @echo "Installing CI/CD required package(s)"; \ - pip install --index-url https://wheels.vtk.org vtk-osmesa==9.3.1; \ - fi - # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: .install-ci-dep Makefile +%: @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) @@ -41,5 +32,5 @@ pdf: (test -f $(BUILDDIR)/latex/*.pdf && echo pdf exists) || exit 1 # Build HTML files and generate examples as .py files -html: .install-ci-dep +html: @$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/doc/changelog.d/774.maintenance.md b/doc/changelog.d/774.maintenance.md new file mode 100644 index 000000000..4ef58d81c --- /dev/null +++ b/doc/changelog.d/774.maintenance.md @@ -0,0 +1 @@ +Rework logic around vtk-osmesa diff --git a/doc/source/conf.py b/doc/source/conf.py index dac9a5470..517b829df 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -298,9 +298,11 @@ def copy_assets_to_output_dir(app: sphinx.application.Sphinx, exception: Excepti if app.builder.name == "html": SOURCE_ASSETS = pathlib.Path(app.outdir) / "_static" / "assets" / "download" ASSETS_DIRECTORY = pathlib.Path(app.outdir).parent.parent.parent / "tests" / "assets" - + SOURCE_ASSETS.mkdir(parents=True, exist_ok=True) logger.info("Extracting assets to output directory...") + logger.info(f"Folder created: {str(SOURCE_ASSETS.exists())}") zip_path = pathlib.Path(shutil.make_archive("assets", "zip", ASSETS_DIRECTORY)) + logger.info("ZIP created") zip_path = shutil.move(zip_path, SOURCE_ASSETS / zip_path.name) logger.info(f"Extracted assets to {zip_path}.") else: