diff --git a/.readthedocs.yml b/.readthedocs.yml index 50b0395fa..427711e05 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -4,17 +4,31 @@ build: os: "ubuntu-22.04" tools: python: "3.10" + commands: + # from https://docs.readthedocs.com/platform/stable/build-customization.html#support-git-lfs-large-file-storage + # Download and uncompress the binary + # https://git-lfs.github.com/ + - wget https://github.com/git-lfs/git-lfs/releases/download/v3.1.4/git-lfs-linux-amd64-v3.1.4.tar.gz + - tar xvfz git-lfs-linux-amd64-v3.1.4.tar.gz git-lfs + # Modify LFS config paths to point where git-lfs binary was downloaded + - git config filter.lfs.process "`pwd`/git-lfs filter-process" + - git config filter.lfs.smudge "`pwd`/git-lfs smudge -- %f" + - git config filter.lfs.clean "`pwd`/git-lfs clean -- %f" + # Make LFS available in current repository + - ./git-lfs install + # Download content from remote + - ./git-lfs fetch + # Make local files to have the real content on them + - ./git-lfs checkout + - asdf plugin add pixi + - asdf install pixi latest + - asdf global pixi latest + - pixi run -e docs build-docs + - mkdir -p $READTHEDOCS_OUTPUT/html/ + - cp -r docs/_build/html/** $READTHEDOCS_OUTPUT/html/ sphinx: configuration: docs/conf.py formats: - pdf - -python: - install: - - requirements: docs/requirements.txt - - method: pip - path: . - extra_requirements: - - docs diff --git a/docs/conf.py b/docs/conf.py index 0b7e2b3dd..a35ff5fdf 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -101,6 +101,7 @@ class AxParameterWarning(Warning): # Ensure it's a real warning subclass "sphinxcontrib.autodoc_pydantic", "sphinx_design", "sphinx_copybutton", + "sphinx_lfs_content", ] spelling_word_list_filename = "spelling_wordlist.txt" diff --git a/docs/requirements.txt b/docs/requirements.txt deleted file mode 100644 index 7c68cd9a4..000000000 --- a/docs/requirements.txt +++ /dev/null @@ -1,8 +0,0 @@ -sphinx<10 -sphinxcontrib-bibtex -sphinxcontrib-spelling -autodoc_pydantic -sphinx-design -numpy -sphinx_rtd_theme>1 -sphinx-copybutton diff --git a/pixi.lock b/pixi.lock index d019ac56e..d7326a9bf 100644 --- a/pixi.lock +++ b/pixi.lock @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a758e95c16d5e476bec89fd4351a7dc614057b22b7bd2c65cf982604ab45d4c5 -size 1087911 +oid sha256:b8d212e3316a9728e1c47bb23c7f1732d7ee17c14b82ed8d5ec41c5dd5674dab +size 1095692 diff --git a/pyproject.toml b/pyproject.toml index 4549355b6..852acde14 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -136,6 +136,9 @@ mypy = ">=1.19.1,<2" types-psutil = ">=6.1.0.20241221,<7" types-pyyaml = ">=6.0.12.20250915,<7" +[tool.pixi.tasks.build-docs] +cmd = "cd docs && make html" + # Linux dependencies, only for extra tests [tool.pixi.feature.extra.target.linux-64.dependencies] scikit-build = "*" @@ -208,11 +211,12 @@ extra = [ "redis>=7.1.0,<8", ] dev = ["wat>=0.7.0,<0.8"] +docs = ["pyenchant", "enchant>=0.0.1,<0.0.2", "sphinx-lfs-content>=1.1.10,<2"] # Various config from here onward [tool.black] line-length = 120 -target-version = ['py310', 'py311', 'py312', 'py313', 'py314'] +target-version = ['py310', 'py311', 'py312', 'py313'] force-exclude = ''' ( /(