From 93fed84a86d265bddd12ebd73507570758db2800 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 3 Oct 2024 04:59:07 +0000 Subject: [PATCH 1/5] Bump ansys-sphinx-theme from 1.0.10 to 1.1.2 in /requirements Bumps [ansys-sphinx-theme](https://github.com/ansys/ansys-sphinx-theme) from 1.0.10 to 1.1.2. - [Release notes](https://github.com/ansys/ansys-sphinx-theme/releases) - [Commits](https://github.com/ansys/ansys-sphinx-theme/compare/v1.0.10...v1.1.2) --- updated-dependencies: - dependency-name: ansys-sphinx-theme dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- requirements/requirements_docs.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements/requirements_docs.txt b/requirements/requirements_docs.txt index 6e960e9bf5b..705c4653975 100644 --- a/requirements/requirements_docs.txt +++ b/requirements/requirements_docs.txt @@ -1,4 +1,4 @@ -ansys_sphinx_theme==1.0.10 +ansys_sphinx_theme==1.1.2 enum-tools[sphinx]==0.12.0 graphviz==0.20.1 imageio==2.35.1 From 41407f28f05eba3db4bab6fb9291cdd2475489da Mon Sep 17 00:00:00 2001 From: Paul Profizi <100710998+PProfizi@users.noreply.github.com> Date: Wed, 9 Oct 2024 17:51:03 +0200 Subject: [PATCH 2/5] Upgrade doc build Python version --- .github/workflows/docs.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 242cfcaadfd..d98f2eac52a 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -7,7 +7,7 @@ on: python_version: required: false type: string - default: "3.9" + default: "3.10" ANSYS_VERSION: required: false type: string @@ -29,7 +29,7 @@ on: description: "Python interpreter" required: true type: string - default: "3.9" + default: "3.10" ANSYS_VERSION: description: "ANSYS version" required: true From 302d745fcc53257c9f797b5ab64ce81fd34ebd8c Mon Sep 17 00:00:00 2001 From: "paul.profizi" Date: Fri, 11 Oct 2024 09:55:50 +0200 Subject: [PATCH 3/5] Move to static search and remove everything related to Meilisearch Signed-off-by: paul.profizi --- .github/workflows/ci.yml | 19 +---------------- .github/workflows/releaser.yml | 38 +--------------------------------- doc/source/conf.py | 20 ++++-------------- 3 files changed, 6 insertions(+), 71 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bc7cb1b2fb5..6000369b3c9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,8 +28,6 @@ concurrency: env: DOCUMENTATION_CNAME: 'dpf.docs.pyansys.com' MAIN_PYTHON_VERSION: '3.9' - MEILISEARCH_API_KEY: ${{ secrets.MEILISEARCH_API_KEY }} - MEILISEARCH_PUBLIC_API_KEY: ${{ secrets.MEILISEARCH_PUBLIC_API_KEY }} jobs: debug: @@ -161,28 +159,13 @@ jobs: needs: [docs] steps: - name: "Upload development documentation" - uses: ansys/actions/doc-deploy-dev@v7 + uses: ansys/actions/doc-deploy-dev@v8 with: cname: ${{ env.DOCUMENTATION_CNAME }} token: ${{ secrets.GITHUB_TOKEN }} doc-artifact-name: HTML-doc-ansys-dpf-core.zip decompress-artifact: true - doc-index-dev: - name: "Deploy dev index docs" - runs-on: ubuntu-latest - needs: upload-development-docs - steps: - - name: "Deploy the latest documentation index" - uses: ansys/actions/doc-deploy-index@v7 - with: - cname: ${{ env.DOCUMENTATION_CNAME }}/version/dev - index-name: pydpf-core-vdev - host-url: ${{ vars.MEILISEARCH_HOST_URL }} - api-key: ${{ env.MEILISEARCH_API_KEY }} - doc-artifact-name: HTML-doc-ansys-dpf-core.zip - decompress-artifact: true - examples: if: startsWith(github.head_ref, 'master') || github.event.action == 'ready_for_review' || !github.event.pull_request.draft uses: ./.github/workflows/examples.yml diff --git a/.github/workflows/releaser.yml b/.github/workflows/releaser.yml index d93b405426d..76d5629e1d7 100644 --- a/.github/workflows/releaser.yml +++ b/.github/workflows/releaser.yml @@ -17,8 +17,6 @@ on: env: DOCUMENTATION_CNAME: 'dpf.docs.pyansys.com' - MEILISEARCH_API_KEY: ${{ secrets.MEILISEARCH_API_KEY }} - MEILISEARCH_PUBLIC_API_KEY: ${{ secrets.MEILISEARCH_PUBLIC_API_KEY }} jobs: @@ -89,47 +87,13 @@ jobs: path: HTML-doc-ansys-dpf-core.zip - name: "Deploy the stable documentation" - uses: ansys/actions/doc-deploy-stable@v7 + uses: ansys/actions/doc-deploy-stable@v8 with: cname: ${{ env.DOCUMENTATION_CNAME }} token: ${{ secrets.GITHUB_TOKEN }} doc-artifact-name: HTML-doc-ansys-dpf-core.zip decompress-artifact: true - doc-index-stable: - name: "Deploy stable docs index" - runs-on: ubuntu-latest - needs: upload_docs_release - steps: - - name: "Install Git and clone project" - uses: actions/checkout@v4 - with: - ref: ${{ github.event.inputs.checkout_ref || '' }} - - - name: "Install the package requirements" - run: | - python3 -m venv .venv - .venv/bin/python -m pip install -e . - - - name: "Get the version to PyMeilisearch" - run: | - VERSION=$(.venv/bin/python -c "from ansys.dpf.core import __version__; print('.'.join(__version__.split('.')[:2]))") - VERSION_MEILI=$(.venv/bin/python -c "from ansys.dpf.core import __version__; print('-'.join(__version__.split('.')[:2]))") - echo "Calculated VERSION: $VERSION" - echo "Calculated VERSION_MEILI: $VERSION_MEILI" - echo "VERSION=$VERSION" >> $GITHUB_ENV - echo "VERSION_MEILI=$VERSION_MEILI" >> $GITHUB_ENV - - - name: "Deploy the latest documentation index" - uses: ansys/actions/doc-deploy-index@v7 - with: - cname: ${{ env.DOCUMENTATION_CNAME }}/version/${{ env.VERSION }} - index-name: pydpf-core-v${{ env.VERSION_MEILI }} - host-url: ${{ vars.MEILISEARCH_HOST_URL }} - api-key: ${{ env.MEILISEARCH_API_KEY }} - doc-artifact-name: HTML-doc-ansys-dpf-core.zip - decompress-artifact: true - update_ansys_lab_examples: uses: ./.github/workflows/ansys_lab.yml needs: get_latest_tag diff --git a/doc/source/conf.py b/doc/source/conf.py index 4042e35481c..03b7853138b 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -206,11 +206,10 @@ def reset_servers(gallery_conf, fname, when): "json_url": f"https://{cname}/versions.json", "version_match": get_version_match(__version__), }, - "use_meilisearch": { - "api_key": os.getenv("MEILISEARCH_PUBLIC_API_KEY", ""), - "index_uids": { - f"pydpf-core-v{get_version_match(__version__).replace('.', '-')}": "PyDPF-Core", - }, + "static_search": { + "threshold": 0.5, + "min_chars_for_search": 2, + "ignoreLocation": True, }, } @@ -318,14 +317,3 @@ def reset_servers(gallery_conf, fname, when): # A list of files that should not be packed into the epub file. epub_exclude_files = ["search.html"] - - -def verify_meilisearch_is_active(app): - MEILISEARCH_PUBLIC_API_KEY = os.getenv("MEILISEARCH_PUBLIC_API_KEY", None) - if not MEILISEARCH_PUBLIC_API_KEY: - sys.stderr.write("Could not find MEILISEARCH_PUBLIC_API_KEY") - # sys.exit(1) - - -def setup(app): - app.connect("builder-inited", verify_meilisearch_is_active) From 67b3a898987d85720b0e4636d68a00f123884110 Mon Sep 17 00:00:00 2001 From: Jorge Martinez Date: Wed, 23 Oct 2024 11:58:12 +0200 Subject: [PATCH 4/5] dbg: point to test branch --- requirements/requirements_docs.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements/requirements_docs.txt b/requirements/requirements_docs.txt index 4ff6e6fb02a..8cb5b238695 100644 --- a/requirements/requirements_docs.txt +++ b/requirements/requirements_docs.txt @@ -1,5 +1,5 @@ -ansys_sphinx_theme==1.1.2 enum-tools[sphinx]==0.12.0 +git+https://github.com/ansys/ansys-sphinx-theme.git@fix/search-index graphviz==0.20.1 imageio==2.35.1 imageio-ffmpeg==0.5.1 From 7b3d3d214b3c195ffc55b08b858d01610c6b1e14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jorge=20Mart=C3=ADnez?= <28702884+jorgepiloto@users.noreply.github.com> Date: Wed, 23 Oct 2024 13:55:37 +0200 Subject: [PATCH 5/5] fix: use new patch version --- requirements/requirements_docs.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements/requirements_docs.txt b/requirements/requirements_docs.txt index ee65d8654d1..a11abcb5d97 100644 --- a/requirements/requirements_docs.txt +++ b/requirements/requirements_docs.txt @@ -1,5 +1,5 @@ +ansys-sphinx-theme==1.1.7 enum-tools[sphinx]==0.12.0 -git+https://github.com/ansys/ansys-sphinx-theme.git@fix/search-index graphviz==0.20.1 imageio==2.36.0 imageio-ffmpeg==0.5.1