From d11e8cea3bdf16ffcf89d97b7eb653df75542f6d Mon Sep 17 00:00:00 2001 From: dkunhamb Date: Wed, 17 Jun 2026 16:00:05 -0500 Subject: [PATCH 1/8] fix(pyvista): auto-detect Jupyter kernel to avoid blank trame renders --- pyproject.toml | 2 +- .../backends/pyvista/pyvista_interface.py | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d1286da06..03bdbddc6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "flit_core.buildapi" [project] name = "ansys-tools-visualization-interface" -version = "0.8.dev0" +version = "0.13.dev0" description = "A Python visualization interface for PyAnsys libraries" readme = "README.rst" requires-python = ">=3.10,<4" diff --git a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py index 8455b0fee..b207f9c06 100644 --- a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py +++ b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py @@ -465,6 +465,19 @@ def show( # Override Jupyter backend if building docs if viz_interface.USE_HTML_BACKEND: jupyter_backend = "html" + elif jupyter_backend is None: + # Auto-detect a Jupyter kernel and fall back to a safe static backend. + # Without this, PyVista defaults to "trame" (after installing + # pyvista[jupyter]), which spawns a local server and renders blank + # in VS Code / Spyder embedded notebooks. + try: + from IPython import get_ipython + + _ip = get_ipython() + if _ip is not None and "IPKernelApp" in _ip.config: + jupyter_backend = "static" + except Exception: + pass # Enabling anti-aliasing by default on scene self.scene.enable_anti_aliasing("ssaa") From ca49b2dbc765f2a8decef84715e5ca2736e42051 Mon Sep 17 00:00:00 2001 From: pyansys-ci-bot <92810346+pyansys-ci-bot@users.noreply.github.com> Date: Wed, 17 Jun 2026 21:03:25 +0000 Subject: [PATCH 2/8] chore: adding changelog file 548.fixed.md [dependabot-skip] --- doc/changelog.d/548.fixed.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 doc/changelog.d/548.fixed.md diff --git a/doc/changelog.d/548.fixed.md b/doc/changelog.d/548.fixed.md new file mode 100644 index 000000000..5bda95820 --- /dev/null +++ b/doc/changelog.d/548.fixed.md @@ -0,0 +1 @@ +Fix: auto-detect Jupyter kernel to avoid blank trame renders From 0e73a62e6c1ce11bea07e16e0f617840194e6294 Mon Sep 17 00:00:00 2001 From: dkunhamb Date: Wed, 17 Jun 2026 16:03:30 -0500 Subject: [PATCH 3/8] update contributors --- CONTRIBUTORS.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 72e32aa00..2f3f0990e 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -7,6 +7,7 @@ ## Individual Contributors * [Abhishek Chitwar](https://github.com/abhishekchitwar) +* [Dipin](https://github.com/dipinknair) * [German](https://github.com/germa89) * [Jorge Martínez](https://github.com/jorgepiloto) * [Kathy Pippert](https://github.com/PipKat) From c6913a3ea5cbe4907f5f7a48eedda918cb919436 Mon Sep 17 00:00:00 2001 From: Alex Fernandez Date: Fri, 19 Jun 2026 16:22:54 +0200 Subject: [PATCH 4/8] fix: Default to HTML jupyter backend --- .../backends/pyvista/pyvista_interface.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py index b207f9c06..ac589d179 100644 --- a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py +++ b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py @@ -466,7 +466,7 @@ def show( if viz_interface.USE_HTML_BACKEND: jupyter_backend = "html" elif jupyter_backend is None: - # Auto-detect a Jupyter kernel and fall back to a safe static backend. + # Auto-detect a Jupyter kernel and fall back to a safe html backend. # Without this, PyVista defaults to "trame" (after installing # pyvista[jupyter]), which spawns a local server and renders blank # in VS Code / Spyder embedded notebooks. @@ -475,7 +475,7 @@ def show( _ip = get_ipython() if _ip is not None and "IPKernelApp" in _ip.config: - jupyter_backend = "static" + jupyter_backend = "html" except Exception: pass From 7bd6f5965ed14491c73a99001340577a8c198983 Mon Sep 17 00:00:00 2001 From: Alex Fernandez Date: Wed, 1 Jul 2026 12:36:11 +0200 Subject: [PATCH 5/8] fix: Check vulns --- .github/workflows/ci_cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci_cd.yml b/.github/workflows/ci_cd.yml index 1286dbedd..756e98b61 100644 --- a/.github/workflows/ci_cd.yml +++ b/.github/workflows/ci_cd.yml @@ -60,6 +60,8 @@ jobs: python-package-name: ${{ env.PACKAGE_NAME }} token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }} dev-mode: true + upload-reports: true + hide-log: false actions-security: name: Actions Security From 2efdc5137835a30ad4d95946bbea3edf57a93197 Mon Sep 17 00:00:00 2001 From: Alex Fernandez Date: Wed, 1 Jul 2026 12:40:19 +0200 Subject: [PATCH 6/8] fix: Vuln advisory --- .../backends/pyvista/pyvista_interface.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py index d4bb55a3f..3a661faed 100644 --- a/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py +++ b/src/ansys/tools/visualization_interface/backends/pyvista/pyvista_interface.py @@ -477,8 +477,10 @@ def show( _ip = get_ipython() if _ip is not None and "IPKernelApp" in _ip.config: jupyter_backend = "html" - except Exception: - pass + except Exception as exc: + logger.debug( + "Not in a Jupyter environment: %s", exc + ) # Enabling anti-aliasing by default on scene self.scene.enable_anti_aliasing("ssaa") From 91181491827dee69373f55d2a99f0740d9318e01 Mon Sep 17 00:00:00 2001 From: Alex Fernandez Date: Wed, 1 Jul 2026 12:40:49 +0200 Subject: [PATCH 7/8] fix: revert vuln logs --- .github/workflows/ci_cd.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci_cd.yml b/.github/workflows/ci_cd.yml index 756e98b61..c47f647bb 100644 --- a/.github/workflows/ci_cd.yml +++ b/.github/workflows/ci_cd.yml @@ -49,8 +49,7 @@ jobs: python-version: ${{ env.MAIN_PYTHON_VERSION }} python-package-name: ${{ env.PACKAGE_NAME }} token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }} - upload-reports: true - hide-log: false + - name: PyAnsys Vulnerability check (on dev mode) if: github.ref != 'refs/heads/main' @@ -60,8 +59,7 @@ jobs: python-package-name: ${{ env.PACKAGE_NAME }} token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }} dev-mode: true - upload-reports: true - hide-log: false + actions-security: name: Actions Security From 91c3539ad5ecca5c58099dcd09d5cca8c0f87d5c Mon Sep 17 00:00:00 2001 From: Alex Fernandez Date: Wed, 1 Jul 2026 12:59:55 +0200 Subject: [PATCH 8/8] fix: Ignore links --- doc/source/conf.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/source/conf.py b/doc/source/conf.py index 46b538db2..7cabe69f6 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -224,6 +224,8 @@ "https://docs.pyvista.org/api/core/_autosummary/pyvista.MultiBlock.html#pyvista.MultiBlock", "https://docs.pyvista.org/api/core/_autosummary/pyvista.UnstructuredGrid.html#pyvista.UnstructuredGrid", "https://docs.pyvista.org/api/plotting/_autosummary/pyvista.Actor.html#pyvista.Actor", + " https://docs.pyvista.org/api/core/_autosummary/pyvista.StructuredGrid.html#pyvista.StructuredGrid", + "https://docs.pyvista.org/user-guide/jupyter/index.html", ]