Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
d214868
Fix docs for ni.grpcdevice.v1.proto package
dixonjoel Aug 21, 2025
fb76417
Fix discovery.v1.proto docs build. Still needs updated stubs after so…
dixonjoel Aug 21, 2025
ebc371c
Fix docs for measurement.v1, measurement.v2, sessionmanagement.v1
dixonjoel Aug 22, 2025
a0e14da
Update to latest commit of ni-apis
dixonjoel Aug 23, 2025
c355580
Update codegen to match latest .proto files
dixonjoel Aug 23, 2025
d1742d4
Merge remote-tracking branch 'origin/main' into users/jdixon/fix-pack…
dixonjoel Aug 23, 2025
57646a2
Update codegen to match latest .proto files
dixonjoel Aug 23, 2025
ababfcf
Update codegen to match latest .proto files
dixonjoel Aug 23, 2025
3248b07
Update codegen to match latest .proto files
dixonjoel Aug 23, 2025
38687b8
Update codegen to match latest .proto files
dixonjoel Aug 23, 2025
22926ef
Fix grpc.device and discovery package docs
dixonjoel Aug 26, 2025
99a31cd
Fix measurement v1 and v2 docs
dixonjoel Aug 26, 2025
b15550c
Fix a couple documentation problems in session_management_service.proto
dixonjoel Aug 26, 2025
555859f
Fix the auto-generation of API Reference with namespaces
dixonjoel Aug 26, 2025
fc93661
Fix the auto-generation of API Reference for ni.grpcdevice.v1.proto
dixonjoel Aug 26, 2025
ffe450a
Fix the auto-generation of API Reference for ni.measurementlink.*.proto
dixonjoel Aug 26, 2025
42075cd
Attempt to fix the build
dixonjoel Aug 26, 2025
6518d1d
Fix the discovery.v1.proto docs
dixonjoel Aug 27, 2025
5b8f161
Fix the measurement.v*.proto docs
dixonjoel Aug 27, 2025
3f92b37
Fix pinmap.v1.proto docs. Won't build until we update to the latest s…
dixonjoel Aug 27, 2025
4bf2cf8
Update for new pin_map_service.proto
dixonjoel Aug 27, 2025
b59a6f7
Update pin_map_service.proto stubs
dixonjoel Aug 27, 2025
39532c0
Fix ni.measurementlink.proto docs
dixonjoel Aug 27, 2025
0664f53
Fix ni.measurementlink.sessionmanagement.v1 docs
dixonjoel Aug 27, 2025
c3717a9
Merge remote-tracking branch 'origin/main' into users/jdixon/fix-pack…
dixonjoel Aug 27, 2025
40c78a6
Few minor conf.py changes
dixonjoel Aug 27, 2025
7e97113
Fix ni.measurementlink.discovery.v1 docs
dixonjoel Aug 27, 2025
ba5a4b2
Fix rest of packages' docs similar to ni.measurementlink.discovery.v1…
dixonjoel Aug 27, 2025
a605d2c
Remove namespace hack from ni.grpcdevice.v1.proto
dixonjoel Aug 28, 2025
1391958
Merge remote-tracking branch 'origin/main' into users/jdixon/fix-pack…
dixonjoel Aug 28, 2025
7dc13b7
Add namespace hack to ni.measurementlink.discovery.v1.client docs
dixonjoel Aug 28, 2025
349447b
Fix a warning about multiple indices for a module
dixonjoel Aug 28, 2025
68314a1
Fix ni.measurementlink.discovery.v1.client docs
dixonjoel Aug 28, 2025
fd3764a
Delete generated doc build files
dixonjoel Aug 28, 2025
ef318f3
Update ignore for docs/_build
dixonjoel Aug 28, 2025
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
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ htmlcov/

# Built artifacts
dist/
docs/_build/
**/docs/**/_build/

# mypy
.mypy_cache/
14 changes: 7 additions & 7 deletions packages/ni.grpcdevice.v1.proto/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
"autoapi.extension",
"m2r2",
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
Expand Down Expand Up @@ -44,18 +45,16 @@
# tell autoapi to doc the public options
autoapi_options = list(autoapi.extension._DEFAULT_OPTIONS)
autoapi_options.remove("private-members") # note: remove this to include "_" members in docs
# Restore this to start building docs for source again
# AB#3233030
# autoapi_dirs = [root_path / "src" / "ni"]
autoapi_dirs = [
root_path / "src" / "session_pb2",
root_path / "src" / "session_pb2_grpc",
]
autoapi_python_use_implicit_namespaces = True
autoapi_template_dir = "templates/autoapi"
autoapi_python_class_content = "both"
autoapi_type = "python"
autodoc_typehints = "description"
autoapi_file_patterns = ["*.pyi", "*.py"]
autoapi_ignore = [
'**/__init__.py',
]


def process_docstring(app, what, name, obj, options, lines):
Expand All @@ -66,7 +65,7 @@ def process_docstring(app, what, name, obj, options, lines):

def setup(sphinx):
"""Sphinx setup callback."""
# sphinx.connect("autodoc-process-docstring", process_docstring)
sphinx.connect("autodoc-process-docstring", process_docstring)


# List of patterns, relative to source directory, that match files and
Expand All @@ -76,6 +75,7 @@ def setup(sphinx):

intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"protobuf": ("https://googleapis.dev/python/protobuf/latest/", None),
}


Expand Down
17 changes: 15 additions & 2 deletions packages/ni.grpcdevice.v1.proto/docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,20 @@
Protobuf Types for NI grpc-device V1 gRPC APIs
##############################################

.. include:: intro.inc

Table of Contents
=================

.. toctree::
:maxdepth: 1
:caption: Contents:
:maxdepth: 4

autoapi/index

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

11 changes: 7 additions & 4 deletions packages/ni.measurementlink.discovery.v1.client/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
"autoapi.extension",
"m2r2",
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
Expand Down Expand Up @@ -51,14 +52,16 @@
autoapi_type = "python"
autodoc_typehints = "description"
autoapi_file_patterns = ["*.py"]
autoapi_ignore = [
'**/__init__.py',
]


def process_docstring(app, what, name, obj, options, lines):
"""Make edits to docstrings as necessary"""
if r"@generated by mypy-protobuf" in lines[0]:
lines.clear()

def setup(sphinx):
"""Sphinx setup callback."""
pass
sphinx.connect("autodoc-process-docstring", process_docstring)

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand Down
17 changes: 15 additions & 2 deletions packages/ni.measurementlink.discovery.v1.client/docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,20 @@
gRPC Client for NI Discovery Service
####################################

.. include:: intro.inc

Table of Contents
=================

.. toctree::
:maxdepth: 1
:caption: Contents:
:maxdepth: 4

autoapi/index

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
API Reference
=============

This page contains auto-generated API reference documentation.

..
Custom index: reference https://github.com/readthedocs/sphinx-autoapi/issues/298
Add the top most levels in "ni.measurementlink.discovery.v1.client" to the index file
This is needed because we don't have __init__.py file in ni
and ni/measurementlink etc. package as we use nested implicit namespace packages.

.. toctree::
:titlesonly:

{% for page in pages | sort %}
{% if (page.top_level_object or page.name.split('.') | length == 5) and page.display %}
{{ page.include_path }}
{% endif %}
{% endfor %}
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
from collections.abc import Sequence

import grpc
from ni.measurementlink.discovery.v1 import discovery_service_pb2, discovery_service_pb2_grpc
import ni.measurementlink.discovery.v1.discovery_service_pb2 as discovery_service_pb2
import ni.measurementlink.discovery.v1.discovery_service_pb2_grpc as discovery_service_pb2_grpc
from ni_grpc_extensions.channelpool import GrpcChannelPool # type: ignore[import-untyped]

from ni.measurementlink.discovery.v1.client._support import (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@
import typing
from typing import Any

from ni.measurementlink.discovery.v1 import (
discovery_service_pb2,
)
import ni.measurementlink.discovery.v1.discovery_service_pb2 as discovery_service_pb2


if sys.platform == "win32":
import msvcrt
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@
import typing
from typing import NamedTuple

from ni.measurementlink.discovery.v1 import (
discovery_service_pb2,
)
import ni.measurementlink.discovery.v1.discovery_service_pb2 as discovery_service_pb2


class ServiceInfo(NamedTuple):
Expand Down
14 changes: 6 additions & 8 deletions packages/ni.measurementlink.discovery.v1.proto/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
"autoapi.extension",
"m2r2",
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
Expand Down Expand Up @@ -44,18 +45,13 @@
# tell autoapi to doc the public options
autoapi_options = list(autoapi.extension._DEFAULT_OPTIONS)
autoapi_options.remove("private-members") # note: remove this to include "_" members in docs
# Restore this to start building docs for source again
# AB#3233030
# autoapi_dirs = [root_path / "src" / "ni"]
autoapi_dirs = [root_path / "src" / "ni"]
autoapi_python_use_implicit_namespaces = True
autoapi_template_dir = "templates/autoapi"
autoapi_python_class_content = "both"
autoapi_type = "python"
autodoc_typehints = "description"
autoapi_file_patterns = ["*.pyi", "*.py"]
autoapi_ignore = [
'**/__init__.py',
]


def process_docstring(app, what, name, obj, options, lines):
Expand All @@ -66,15 +62,17 @@ def process_docstring(app, what, name, obj, options, lines):

def setup(sphinx):
"""Sphinx setup callback."""
pass
sphinx.connect("autodoc-process-docstring", process_docstring)

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This patterns also effect to html_static_path and html_extra_path
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "__init__.py"]
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]

intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"protobuf": ("https://googleapis.dev/python/protobuf/latest/", None),
"grpc": ("https://grpc.github.io/grpc/python/", None),
}

# -- Options for HTML output ----------------------------------------------
Expand Down
16 changes: 14 additions & 2 deletions packages/ni.measurementlink.discovery.v1.proto/docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,19 @@
Protobuf Types for NI Discovery gRPC APIs
#########################################

.. include:: intro.inc

Table of Contents
=================

.. toctree::
:maxdepth: 1
:caption: Contents:
:maxdepth: 4

autoapi/index

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
ni.measurementlink.discovery.v1
===============================

.. py:module:: ni.measurementlink.discovery.v1

.. autoapi-nested-parse::

Package for ni.measurementlink.discovery.v1.



Submodules
----------

.. toctree::
:maxdepth: 1

/autoapi/ni/measurementlink/discovery/v1/discovery_service_pb2/index
/autoapi/ni/measurementlink/discovery/v1/discovery_service_pb2_grpc/index
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
API Reference
=============

This page contains auto-generated API reference documentation.

..
Custom index: reference https://github.com/readthedocs/sphinx-autoapi/issues/298
Add the deepest implicit namespace package to the toctree.

.. toctree::
:titlesonly:

/namespace
14 changes: 6 additions & 8 deletions packages/ni.measurementlink.measurement.v1.proto/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
"autoapi.extension",
"m2r2",
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
Expand Down Expand Up @@ -44,18 +45,13 @@
# tell autoapi to doc the public options
autoapi_options = list(autoapi.extension._DEFAULT_OPTIONS)
autoapi_options.remove("private-members") # note: remove this to include "_" members in docs
# Restore this to start building docs for source again
# AB#3233030
# autoapi_dirs = [root_path / "src" / "ni"]
autoapi_dirs = [root_path / "src" / "ni"]
autoapi_python_use_implicit_namespaces = True
autoapi_template_dir = "templates/autoapi"
autoapi_python_class_content = "both"
autoapi_type = "python"
autodoc_typehints = "description"
autoapi_file_patterns = ["*.pyi", "*.py"]
autoapi_ignore = [
'**/__init__.py',
]


def process_docstring(app, what, name, obj, options, lines):
Expand All @@ -66,16 +62,18 @@ def process_docstring(app, what, name, obj, options, lines):

def setup(sphinx):
"""Sphinx setup callback."""
# sphinx.connect("autodoc-process-docstring", process_docstring)
sphinx.connect("autodoc-process-docstring", process_docstring)


# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This patterns also effect to html_static_path and html_extra_path
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "__init__.py"]
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]

intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"protobuf": ("https://googleapis.dev/python/protobuf/latest/", None),
"grpc": ("https://grpc.github.io/grpc/python/", None),
}


Expand Down
16 changes: 14 additions & 2 deletions packages/ni.measurementlink.measurement.v1.proto/docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,19 @@
Protobuf Types for NI Measurement V1 gRPC APIs
##############################################

.. include:: intro.inc

Table of Contents
=================

.. toctree::
:maxdepth: 1
:caption: Contents:
:maxdepth: 4

autoapi/index

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
ni.measurementlink.measurement.v1
=================================

.. py:module:: ni.measurementlink.measurement.v1

.. autoapi-nested-parse::

Package for ni.measurementlink.measurement.v1.



Submodules
----------

.. toctree::
:maxdepth: 1

/autoapi/ni/measurementlink/measurement/v1/measurement_service_pb2/index
/autoapi/ni/measurementlink/measurement/v1/measurement_service_pb2_grpc/index
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
API Reference
=============

This page contains auto-generated API reference documentation.

..
Custom index: reference https://github.com/readthedocs/sphinx-autoapi/issues/298
Add the deepest implicit namespace package to the toctree.

.. toctree::
:titlesonly:

/namespace
Loading
Loading