diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml index 64287290558a57..908f06e034a75c 100644 --- a/.github/workflows/docs.yaml +++ b/.github/workflows/docs.yaml @@ -27,6 +27,7 @@ jobs: name: build docs runs-on: ubuntu-latest timeout-minutes: 45 + if: false # TODO: replace this with the new docs steps: - uses: actions/checkout@v4 with: diff --git a/docs/Makefile b/docs/Makefile deleted file mode 100644 index 09103e206ec444..00000000000000 --- a/docs/Makefile +++ /dev/null @@ -1,53 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -OPENPILOT_ROOT = `git rev-parse --show-toplevel` - -# You can set these variables from the command line, and also -# from the environment for the first two. -SPHINXOPTS ?= -SPHINXBUILD ?= sphinx-build -DOCSDIR = "$(OPENPILOT_ROOT)/docs" -SOURCEDIR = "$(OPENPILOT_ROOT)/build/docs" -DOCSBUILDDIR = "$(OPENPILOT_ROOT)/build/docs" -BUILDDIR = "$(OPENPILOT_ROOT)/build" - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(DOCSBUILDDIR)" $(SPHINXOPTS) $(O) - -clean: - @echo "Cleaning build folder..." - rm -rf "$(BUILDDIR)" - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @echo "Cleaning build folder..." - rm -rf "$(BUILDDIR)" - mkdir -p "$(DOCSBUILDDIR)" - - @echo "Copying docs & config to build folder..." - cp -a "$(DOCSDIR)" "$(BUILDDIR)" - cd "$(OPENPILOT_ROOT)" && \ - find . -type f \( -name "*.md" -o -name "*.rst" -o -name "*.png" -o -name "*.jpg" -o -name "*.svg" \) \ - -not -path "*/.*" \ - -not -path "./build/*" \ - -not -path "./docs/*" \ - -not -path "./xx/*" \ - -exec cp --parents "{}" ./build/docs/ \; - - @echo "Building rst files..." - sphinx-apidoc -o "$(DOCSBUILDDIR)" ../ \ - ../xx ../rednose_repo ../notebooks ../panda_jungle \ - ../third_party \ - ../panda/examples \ - ../scripts \ - ../selfdrive/modeld \ - ../selfdrive/debug \ - $(shell find .. -type d -name "*test* -not -path "**.venv**" \") - - @echo "Building html files..." - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(DOCSBUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/docs/_static/favicon.ico b/docs/_static/favicon.ico deleted file mode 100644 index 976929954f3dac..00000000000000 Binary files a/docs/_static/favicon.ico and /dev/null differ diff --git a/docs/_static/logo.png b/docs/_static/logo.png deleted file mode 100644 index 0e7577dae1d4c4..00000000000000 --- a/docs/_static/logo.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:42bc589954cad7f16cef694887dee2c819378f7dacfdddea2ff833ff65a109fd -size 1122 diff --git a/docs/_static/robots.txt b/docs/_static/robots.txt deleted file mode 100644 index 3bcd24fb5d5f9d..00000000000000 --- a/docs/_static/robots.txt +++ /dev/null @@ -1,2 +0,0 @@ -User-agent: * -Sitemap: https://docs.comma.ai/sitemap.xml \ No newline at end of file diff --git a/docs/c_docs.rst b/docs/c_docs.rst deleted file mode 100644 index 0d65423c0854ba..00000000000000 --- a/docs/c_docs.rst +++ /dev/null @@ -1,87 +0,0 @@ -openpilot -========== - - -opendbc ------- -.. autodoxygenindex:: - :project: opendbc_can - - -cereal ------- - -messaging -^^^^^^^^^ -.. autodoxygenindex:: - :project: msgq_repo_msgq - -visionipc -^^^^^^^^^ -.. autodoxygenindex:: - :project: msgq_repo_msgq_visionipc - - -selfdrive ---------- - -camerad -^^^^^^^ -.. autodoxygenindex:: - :project: system_camerad_cameras - -locationd -^^^^^^^^^ -.. autodoxygenindex:: - :project: selfdrive_locationd - -ui -^^ - -.. autodoxygenindex:: - :project: selfdrive_ui - -replay -"""""" -.. autodoxygenindex:: - :project: tools_replay - -qt -"" -.. autodoxygenindex:: - :project: selfdrive_ui_qt_offroad - -proclogd -^^^^^^^^ -.. autodoxygenindex:: - :project: system_proclogd - -modeld -^^^^^^ -.. autodoxygenindex:: - :project: selfdrive_modeld_transforms -.. autodoxygenindex:: - :project: selfdrive_modeld_models -.. autodoxygenindex:: - :project: selfdrive_modeld_runners - -common -^^^^^^ -.. autodoxygenindex:: - :project: common - -sensorsd -^^^^^^^^ -.. autodoxygenindex:: - :project: system_sensord_sensors - -pandad -^^^^^^ -.. autodoxygenindex:: - :project: selfdrive_pandad - - -rednose -------- -.. autodoxygenindex:: - :project: rednose_repo_rednose_helpers diff --git a/docs/conf.py b/docs/conf.py deleted file mode 100644 index 9a8d6466970777..00000000000000 --- a/docs/conf.py +++ /dev/null @@ -1,147 +0,0 @@ -# type: ignore - -# Configuration file for the Sphinx documentation builder. -# -# This file only contains a selection of the most common options. For a full -# list see the documentation: -# https://www.sphinx-doc.org/en/master/usage/configuration.html - -# -- Path setup -------------------------------------------------------------- - -# If extensions (or modules to document with autodoc) are in another directory, -# add these directories to sys.path here. If the directory is relative to the -# documentation root, use os.path.abspath to make it absolute, like shown here. -# -import os -import sys -from os.path import exists - -from openpilot.common.basedir import BASEDIR -from openpilot.system.version import get_version - -sys.path.insert(0, os.path.abspath('.')) -sys.path.insert(0, os.path.abspath('..')) - -VERSION = get_version() - - -# -- Project information ----------------------------------------------------- - -project = 'openpilot docs' -copyright = '2021, comma.ai' # noqa: A001 -author = 'comma.ai' -version = VERSION -release = VERSION -language = 'en' - - -# -- General configuration --------------------------------------------------- - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom -# ones. -extensions = [ - 'sphinx.ext.autodoc', # Auto-generate docs - 'sphinx.ext.viewcode', # Add view code link to modules - 'sphinx_rtd_theme', # Read The Docs theme - 'myst_parser', # Markdown parsing - 'breathe', # Doxygen C/C++ integration - 'sphinx_sitemap', # sitemap generation for SEO -] - -myst_html_meta = { - "description": "openpilot docs", - "keywords": "op, openpilot, docs, documentation", - "robots": "all,follow", - "googlebot": "index,follow,snippet,archive", - "property=og:locale": "en_US", - "property=og:site_name": "docs.comma.ai", - "property=og:url": "https://docs.comma.ai", - "property=og:title": "openpilot Documentation", - "property=og:type": "website", - "property=og:image:type": "image/jpeg", - "property=og:image:width": "400", - "property=og:image": "https://docs.comma.ai/_static/logo.png", - "property=og:image:url": "https://docs.comma.ai/_static/logo.png", - "property=og:image:secure_url": "https://docs.comma.ai/_static/logo.png", - "property=og:description": "openpilot Documentation", - "property=twitter:card": "summary_large_image", - "property=twitter:logo": "https://docs.comma.ai/_static/logo.png", - "property=twitter:title": "openpilot Documentation", - "property=twitter:description": "openpilot Documentation" -} - -html_baseurl = 'https://docs.comma.ai/' -sitemap_filename = "sitemap.xml" - -# Add any paths that contain templates here, relative to this directory. -templates_path = ['_templates'] - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This pattern also affects html_static_path and html_extra_path. -exclude_patterns = [] - - -# -- c docs configuration --------------------------------------------------- - -# Breathe Configuration -# breathe_default_project = "c_docs" -breathe_build_directory = f"{BASEDIR}/build/docs/html/xml" -breathe_separate_member_pages = True -breathe_default_members = ('members', 'private-members', 'undoc-members') -breathe_domain_by_extension = { - "h": "cc", -} -breathe_implementation_filename_extensions = ['.c', '.cc'] -breathe_doxygen_config_options = {} -breathe_projects_source = {} - -# only document files that have accompanying .cc files next to them -print("searching for c_docs...") -for root, _, files in os.walk(BASEDIR): - found = False - breath_src = {} - breathe_srcs_list = [] - - for file in files: - ccFile = os.path.join(root, file)[:-2] + ".cc" - - if file.endswith(".h") and exists(ccFile): - f = os.path.join(root, file) - - parent_dir_abs = os.path.dirname(f) - parent_dir = parent_dir_abs[len(BASEDIR) + 1:] - parent_project = parent_dir.replace('/', '_') - print(f"\tFOUND: {f} in {parent_project}") - - breathe_srcs_list.append(file) - found = True - - if found: - breath_src[parent_project] = (parent_dir_abs, breathe_srcs_list) - breathe_projects_source.update(breath_src) - -print(f"breathe_projects_source: {breathe_projects_source.keys()}") - -# -- Options for HTML output ------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# -html_theme = 'sphinx_rtd_theme' -html_show_copyright = True - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] -html_logo = '_static/logo.png' -html_favicon = '_static/favicon.ico' -html_theme_options = { - 'logo_only': False, - 'display_version': True, - 'vcs_pageview_mode': 'blob', - 'style_nav_header_background': '#000000', -} -html_extra_path = ['_static'] diff --git a/docs/index.md b/docs/index.md deleted file mode 100644 index 0fb2617a5b74ab..00000000000000 --- a/docs/index.md +++ /dev/null @@ -1,42 +0,0 @@ -# openpilot Documentation - -```{include} README.md -``` - -```{toctree} -:caption: 'General' -:maxdepth: 4 - -CARS.md -CONTRIBUTING.md -INTEGRATION.md -LIMITATIONS.md -SAFETY.md -``` - -```{toctree} -:caption: 'Overview' -:maxdepth: 2 - -overview.rst -``` - -## API Documentation - -- {ref}`genindex` -- {ref}`modindex` -- {ref}`search` - -```{toctree} -:caption: 'Python API' -:maxdepth: 2 - -modules.rst -``` - -```{toctree} -:caption: 'C/C++ API' -:maxdepth: 4 - -c_docs.rst -``` \ No newline at end of file diff --git a/docs/overview.rst b/docs/overview.rst deleted file mode 100644 index 8c552077f38fc5..00000000000000 --- a/docs/overview.rst +++ /dev/null @@ -1,72 +0,0 @@ -openpilot -========= - -.. toctree:: - :maxdepth: 4 - - Debugging - system/loggerd/README.md - Driver Monitoring - Process Replay - -cereal -========= - -.. toctree:: - :maxdepth: 4 - - cereal/README.md - cereal/messaging/msgq.md - -models -========= - -.. toctree:: - :maxdepth: 4 - - models/README.md - -opendbc -========= - -.. toctree:: - :maxdepth: 4 - - opendbc/README.md - -panda -========= - -.. toctree:: - :maxdepth: 4 - - panda/README.md - panda/UPDATING.md - panda/board/README.md - panda/drivers/linux/README.md - panda/drivers/windows/README.md - - -rednose -========= -.. toctree:: - :maxdepth: 4 - - rednose_repo/README.md - - -tools -========= -.. toctree:: - :maxdepth: 4 - - tools/CTF.md - tools/joystick/README.md - tools/lib/README.md - tools/plotjuggler/README.md - tools/replay/README.md - tools/serial/README.md - Simulator - tools/ssh/README.md - Webcam - tools/cabana/README.md diff --git a/pyproject.toml b/pyproject.toml index fc2356645bc931..4b20c84e9f8111 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,9 +66,6 @@ dependencies = [ [project.optional-dependencies] docs = [ "Jinja2", - "sphinx", - "sphinx-rtd-theme", - "sphinx-sitemap" ] testing = [ diff --git a/uv.lock b/uv.lock index 6433b535241071..6a9f155df79797 100644 --- a/uv.lock +++ b/uv.lock @@ -2286,9 +2286,6 @@ dev = [ ] docs = [ { name = "jinja2" }, - { name = "sphinx" }, - { name = "sphinx-rtd-theme" }, - { name = "sphinx-sitemap" }, ] testing = [ { name = "coverage" }, @@ -6447,32 +6444,6 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/b4/fa/130c32ed94cf270e3d0b9ded16fb7b2c8fea86fa7263c29a696a30c1dde7/sphinx-7.3.7-py3-none-any.whl", hash = "sha256:413f75440be4cacf328f580b4274ada4565fb2187d696a84970c23f77b64d8c3", size = 3335650 }, ] -[[distribution]] -name = "sphinx-rtd-theme" -version = "2.0.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/fe/33/2a35a9cdbfda9086bda11457bcc872173ab3565b16b6d7f6b3efaa6dc3d6/sphinx_rtd_theme-2.0.0.tar.gz", hash = "sha256:bd5d7b80622406762073a04ef8fadc5f9151261563d47027de09910ce03afe6b", size = 2785005 } -dependencies = [ - { name = "docutils" }, - { name = "sphinx" }, - { name = "sphinxcontrib-jquery" }, -] -wheels = [ - { url = "https://files.pythonhosted.org/packages/ea/46/00fda84467815c29951a9c91e3ae7503c409ddad04373e7cfc78daad4300/sphinx_rtd_theme-2.0.0-py2.py3-none-any.whl", hash = "sha256:ec93d0856dc280cf3aee9a4c9807c60e027c7f7b461b77aeffed682e68f0e586", size = 2824721 }, -] - -[[distribution]] -name = "sphinx-sitemap" -version = "2.6.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/42/ed/96cc112b671e06df01c8306c25ce3331ccfece0d30235e32eb039afc8094/sphinx_sitemap-2.6.0.tar.gz", hash = "sha256:5e0c66b9f2e371ede80c659866a9eaad337d46ab02802f9c7e5f7bc5893c28d2", size = 6042 } -dependencies = [ - { name = "sphinx" }, -] -wheels = [ - { url = "https://files.pythonhosted.org/packages/94/d4/dffb4da380be24fd390d284634735d6fba560980014050e52569c04d215b/sphinx_sitemap-2.6.0-py3-none-any.whl", hash = "sha256:7478e417d141f99c9af27ccd635f44c03a471a08b20e778a0f9daef7ace1d30b", size = 5632 }, -] - [[distribution]] name = "sphinxcontrib-applehelp" version = "1.0.8" @@ -6500,18 +6471,6 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/c2/e9/74c4cda5b409af3222fda38f0774e616011bc935f639dbc0da5ca2d1be7d/sphinxcontrib_htmlhelp-2.0.5-py3-none-any.whl", hash = "sha256:393f04f112b4d2f53d93448d4bce35842f62b307ccdc549ec1585e950bc35e04", size = 99217 }, ] -[[distribution]] -name = "sphinxcontrib-jquery" -version = "4.1" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/de/f3/aa67467e051df70a6330fe7770894b3e4f09436dea6881ae0b4f3d87cad8/sphinxcontrib-jquery-4.1.tar.gz", hash = "sha256:1620739f04e36a2c779f1a131a2dfd49b2fd07351bf1968ced074365933abc7a", size = 122331 } -dependencies = [ - { name = "sphinx" }, -] -wheels = [ - { url = "https://files.pythonhosted.org/packages/76/85/749bd22d1a68db7291c89e2ebca53f4306c3f205853cf31e9de279034c3c/sphinxcontrib_jquery-4.1-py2.py3-none-any.whl", hash = "sha256:f936030d7d0147dd026a4f2b5a57343d233f1fc7b363f68b3d4f1cb0993878ae", size = 121104 }, -] - [[distribution]] name = "sphinxcontrib-jsmath" version = "1.0.1"