Skip to content

Commit

Permalink
docs: revert the pyvista plot
Browse files Browse the repository at this point in the history
  • Loading branch information
Revathyvenugopal162 committed Oct 29, 2024
1 parent b8f39d3 commit 487c2f9
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from typing import Dict, List

from github import Github
import plotly.io as pio
import pyvista
import requests
from sphinx.application import Sphinx
Expand All @@ -25,6 +26,8 @@
watermark,
)

pio.renderers.default = "sphinx_gallery"

THIS_PATH = Path(__file__).parent.resolve()
EXAMPLE_PATH = (THIS_PATH / "examples" / "sphinx_examples").resolve()

Expand Down Expand Up @@ -181,7 +184,8 @@ def extract_example_links(
list
List of example links.
"""
g = Github()
token = os.getenv("GITHUB_TOKEN")
g = Github(token)
repo = g.get_repo(repo_fullname)
contents = repo.get_contents(path_relative_to_root)
if not isinstance(contents, list):
Expand Down Expand Up @@ -264,8 +268,11 @@ def download_and_process_files(example_links: List[str]) -> List[str]:
# Modules for which function level galleries are created. In
"image_scrapers": ("pyvista", "matplotlib", plotly_sg_scraper),
"default_thumb_file": "source/_static/pyansys_light_square.png",
"capture_repr": ("_repr_html_", "__repr__"),
}
pyvista.BUILDING_GALLERY = True
pyvista.OFF_SCREEN = True

nbsphinx_prolog = """
Download this example as a :download:`Jupyter notebook </{{ env.docname }}.ipynb>`.
Expand Down

0 comments on commit 487c2f9

Please sign in to comment.