Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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'
Expand All @@ -61,6 +60,7 @@ jobs:
token: ${{ secrets.PYANSYS_CI_BOT_TOKEN }}
dev-mode: true


actions-security:
name: Actions Security
runs-on: ubuntu-latest
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
1 change: 1 addition & 0 deletions doc/changelog.d/548.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix: auto-detect Jupyter kernel to avoid blank trame renders
2 changes: 2 additions & 0 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -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",
]


Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -466,6 +466,21 @@ 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 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.
try:
from IPython import get_ipython

_ip = get_ipython()
if _ip is not None and "IPKernelApp" in _ip.config:
jupyter_backend = "html"
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")
Expand Down
Loading