Skip to content
Merged
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
12 changes: 8 additions & 4 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
from inspect import cleandoc
from pathlib import Path

import git
import nbformat
import nbsphinx
from git import Repo
from packaging.version import parse

sys.path.insert(0, os.path.abspath("../"))
Expand Down Expand Up @@ -181,10 +181,14 @@
example_notebooks_path = Path("ExampleNotebooks")
try:
if example_notebooks_path.exists():
repo = Repo(example_notebooks_path)
repo.remote("origin").pull()
repo = git.Repo(example_notebooks_path)
try:
repo.remote("origin").pull()
except git.exc.GitCommandError:
# cannot pull if on a tag
pass
else:
repo = Repo.clone_from(
repo = git.Repo.clone_from(
"https://github.com/OpenFreeEnergy/ExampleNotebooks.git",
branch="2025.10.2",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

idea for the future: this should point to the stable release branch so we don't have to remember to update this for each release

to_path=example_notebooks_path,
Expand Down