From da152c51dc9452c178d913aed540d9ac772d4151 Mon Sep 17 00:00:00 2001 From: Harshal Pohekar Date: Mon, 3 Feb 2025 12:39:13 +0530 Subject: [PATCH 1/3] docs: Fix examples gallery [skip tests] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index bd0036ee712..9d304fa095d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ docs = [ "jupyter_sphinx==0.5.3", "numpydoc==1.8.0", "matplotlib==3.10.0", - "ansys-sphinx-theme==1.2.4", + "ansys-sphinx-theme==1.2.6", "pypandoc==1.14", "pytest-sphinx==0.6.3", "sphinx-autobuild==2024.10.3", From 1021218daeb14cb8e37bb316395da3e2b20ec70b Mon Sep 17 00:00:00 2001 From: pyansys-ci-bot <92810346+pyansys-ci-bot@users.noreply.github.com> Date: Mon, 3 Feb 2025 07:10:42 +0000 Subject: [PATCH 2/3] chore: adding changelog file 3699.documentation.md [dependabot-skip] --- doc/changelog.d/3699.documentation.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 doc/changelog.d/3699.documentation.md diff --git a/doc/changelog.d/3699.documentation.md b/doc/changelog.d/3699.documentation.md new file mode 100644 index 00000000000..a32eece830b --- /dev/null +++ b/doc/changelog.d/3699.documentation.md @@ -0,0 +1 @@ +Fix examples gallery [skip tests] \ No newline at end of file From 56301a0ce72143bff47e67097f5cd2a46ade76ca Mon Sep 17 00:00:00 2001 From: Harshal Pohekar Date: Mon, 3 Feb 2025 13:13:53 +0530 Subject: [PATCH 3/3] docs: Fix examples gallery [skip tests] --- .github/workflows/ci.yml | 14 -------------- .github/workflows/doc-build-dev-nightly.yml | 8 ++++++++ doc/source/conf.py | 6 +++--- 3 files changed, 11 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 51f6b7c1621..389d4fb281f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,12 +19,6 @@ concurrency: cancel-in-progress: true env: - # Following env vars when changed will "reset" the mentioned cache, - # by changing the cache file name. It is rendered as ...-v%RESET_XXX%-... - # You should go up in number, if you go down (or repeat a previous value) - # you might end up reusing a previous cache if it haven't been deleted already. - # It applies 7 days retention policy by default. - RESET_EXAMPLES_CACHE: 7 API_CODE_CACHE: 3 DOCUMENTATION_CNAME: 'fluent.docs.pyansys.com' PACKAGE_NAME: 'ansys-fluent-core' @@ -193,14 +187,6 @@ jobs: rm -rf dist make install > /dev/null - - name: Cache examples - uses: actions/cache@v4 - with: - path: doc/source/examples - key: Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ steps.version.outputs.PYFLUENT_VERSION }}-${{ env.DOC_DEPLOYMENT_IMAGE_TAG }}-${{ hashFiles('examples/**', 'doc/source/conf.py') }} - restore-keys: | - Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ steps.version.outputs.PYFLUENT_VERSION }}-${{ env.DOC_DEPLOYMENT_IMAGE_TAG }} - - name: Build Source Documentation run: | pip install -r requirements/requirements_build.txt diff --git a/.github/workflows/doc-build-dev-nightly.yml b/.github/workflows/doc-build-dev-nightly.yml index 47e5f8d8561..23408dd3609 100644 --- a/.github/workflows/doc-build-dev-nightly.yml +++ b/.github/workflows/doc-build-dev-nightly.yml @@ -59,6 +59,14 @@ jobs: rm -rf dist make install > /dev/null + - name: Execute examples + run: | + python examples/00-fluent/exhaust_system_settings_api.py + python examples/00-fluent/external_compressible_flow.py + python examples/00-fluent/mixing_elbow_settings_api.py + python examples/00-fluent/modeling_cavitation.py + python examples/00-fluent/species_transport.py + - name: Build All Documentation run: | pip install -r requirements/requirements_build.txt diff --git a/doc/source/conf.py b/doc/source/conf.py index 0b7fbbdd122..7ad78b8afde 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -149,9 +149,9 @@ def _stop_fluent_container(gallery_conf, fname): # path where to save gallery generated examples "gallery_dirs": ["examples"], # Pattern to search for example files - "filename_pattern": r"exhaust_system_settings_api\.py|external_compressible_flow\.py|mixing_elbow_settings_api\.py|modeling_cavitation\.py|species_transport\.py", - # Disabled example scripts - "ignore_pattern": r"ahmed_body_workflow\.py|brake\.py|DOE_ML\.py|radiation_headlamp\.py|parametric_static_mixer_1\.py|conjugate_heat_transfer\.py|tyler_sofrin_modes\.py|lunar_lander_thermal\.py|modeling_ablation\.py", + "filename_pattern": r"exhaust_system_settings_api\.py|external_compressible_flow\.py|mixing_elbow_settings_api\.py|modeling_cavitation\.py|species_transport\.py|ahmed_body_workflow\.py|brake\.py|DOE_ML\.py|radiation_headlamp\.py|parametric_static_mixer_1\.py|conjugate_heat_transfer\.py|tyler_sofrin_modes\.py|lunar_lander_thermal\.py|modeling_ablation\.py", + # Do not execute examples + "plot_gallery": False, # Remove the "Download all examples" button from the top level gallery "download_all_examples": False, # Sort gallery example by file name instead of number of lines (default)