Skip to content

Commit 3004218

Browse files
authored
chore(deps): update documentation dependencies to latest versions and add pydantic to enable builds to pass (#545)
* chore(deps): update documentation dependencies to latest versions and add pydantic to enable builds to pass * chore: remove post_install job from Read the Docs configuration
1 parent 916139d commit 3004218

File tree

8 files changed

+28
-210
lines changed

8 files changed

+28
-210
lines changed

.readthedocs.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ build:
55
tools:
66
python: '3.11' # This needs to stay in sync with the tox config in pyproject.toml and any CI scripts
77
nodejs: '22' # This needs to stay in sync with any CI scripts
8-
jobs:
9-
post_install: [python scripts/install_insiders_packages.py]
108
python:
119
install:
1210
- requirements: docs/requirements.txt

docs/_templates/mkdocstrings/python/readthedocs/class.html.jinja

Lines changed: 0 additions & 49 deletions
This file was deleted.

docs/basic_usage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ Create and read from a dynamic buffer.
192192
Sometimes using the [`DeviceManager`][tm_devices.DeviceManager] class as a context manager is not feasible.
193193
In those instances there is an alternative way to enforce the device manager to
194194
close when the Python script execution is finished without needing to explicitly
195-
call the [`.close()`][tm_devices.DeviceManager.close] method.
195+
call the [`.close()`][tm_devices.device_manager.DeviceManager.close] method.
196196

197197
```python
198198
# fmt: off

docs/requirements.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
annotated-types==0.7.0 ; python_version >= "3.10" and python_version < "3.15"
12
beautifulsoup4==4.14.3 ; python_version >= "3.10" and python_version < "3.15"
23
black==26.1.0 ; python_version >= "3.10" and python_version < "3.15"
34
bracex==2.6 ; python_version >= "3.10" and python_version < "3.15"
@@ -29,14 +30,16 @@ mkdocs-macros-plugin==1.5.0 ; python_version >= "3.10" and python_version < "3.1
2930
mkdocs-mermaid2-plugin==1.2.3 ; python_version >= "3.10" and python_version < "3.15"
3031
mkdocs-section-index==0.3.10 ; python_version >= "3.10" and python_version < "3.15"
3132
mkdocs-spellcheck==1.2.0 ; python_version >= "3.10" and python_version < "3.15"
32-
mkdocstrings==0.30.1 ; python_version >= "3.10" and python_version < "3.15"
33-
mkdocstrings-python==1.19.0 ; python_version >= "3.10" and python_version < "3.15"
33+
mkdocstrings==1.0.2 ; python_version >= "3.10" and python_version < "3.15"
34+
mkdocstrings-python==2.0.1 ; python_version >= "3.10" and python_version < "3.15"
3435
more-itertools==10.8.0 ; python_version >= "3.10" and python_version < "3.15"
3536
mypy-extensions==1.1.0 ; python_version >= "3.10" and python_version < "3.15"
3637
nodeenv==1.10.0 ; python_version >= "3.10" and python_version < "3.15"
3738
packaging==26.0 ; python_version >= "3.10" and python_version < "3.15"
3839
pathspec==1.0.4 ; python_version >= "3.10" and python_version < "3.15"
3940
platformdirs==4.5.1 ; python_version >= "3.10" and python_version < "3.15"
41+
pydantic==2.12.5 ; python_version >= "3.10" and python_version < "3.15"
42+
pydantic-core==2.41.5 ; python_version >= "3.10" and python_version < "3.15"
4043
pygments==2.19.2 ; python_version >= "3.10" and python_version < "3.15"
4144
pymdown-extensions==10.20.1 ; python_version >= "3.10" and python_version < "3.15"
4245
python-dateutil==2.9.0.post0 ; python_version >= "3.10" and python_version < "3.15"
@@ -53,6 +56,7 @@ termcolor==3.3.0 ; python_version >= "3.10" and python_version < "3.15"
5356
tomli==2.4.0 ; python_version >= "3.10" and python_version < "3.15"
5457
typeguard==4.4.4 ; python_version >= "3.10" and python_version < "3.15"
5558
typing-extensions==4.15.0 ; python_version >= "3.10" and python_version < "3.15"
59+
typing-inspection==0.4.2 ; python_version >= "3.10" and python_version < "3.15"
5660
urllib3==2.6.3 ; python_version >= "3.10" and python_version < "3.15"
5761
watchdog==6.0.0 ; python_version >= "3.10" and python_version < "3.15"
5862
wcmatch==10.1 ; python_version >= "3.10" and python_version < "3.15"

mkdocs.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ plugins:
103103
options:
104104
# General options
105105
extensions: [docs/griffe_custom_decorator_labels.py]
106-
show_inheritance_diagram: true # INSIDERS FEATURE
106+
inheritance_diagram_direction: LR
107+
show_inheritance_diagram: true
107108
show_source: false # a link is included at the top of each page
108109
# Headings options
109110
heading_level: 1
@@ -124,16 +125,16 @@ plugins:
124125
trim_doctest_flags: true
125126
docstring_section_style: list
126127
merge_init_into_class: true
127-
relative_crossrefs: true # INSIDERS FEATURE
128-
scoped_crossrefs: true # INSIDERS FEATURE
128+
relative_crossrefs: true
129+
scoped_crossrefs: true
129130
# Signature options
130131
line_length: 100
131-
modernize_annotations: false # INSIDERS FEATURE (if the source code annotations format changes, update this to true)
132+
modernize_annotations: true
132133
show_signature_annotations: true
133134
signature_crossrefs: true
134135
separate_signature: true
135136
unwrap_annotated: true
136-
import:
137+
inventories:
137138
- url: https://docs.python.org/3/objects.inv
138139
domains: [std, py]
139140
- url: https://typing-extensions.readthedocs.io/en/stable/objects.inv

pyproject.toml

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -128,20 +128,21 @@ wheel = "^0.46.2"
128128
[tool.poetry.group.docs.dependencies]
129129
black = "^26.1.0"
130130
codespell = "^2.2.6"
131-
griffe = "^1.1.0"
132-
mkdocs = "^1.6.0"
133-
mkdocs-ezglossary-plugin = "^2.0.0"
131+
griffe = "^1.15.0"
132+
mkdocs = "^1.6.1"
133+
mkdocs-ezglossary-plugin = "^2.1.0"
134134
mkdocs-gen-files = "^0.6.0"
135-
mkdocs-include-markdown-plugin = "^7.1.5"
136-
mkdocs-literate-nav = "^0.6.1"
137-
mkdocs-macros-plugin = "^1.0.5"
138-
mkdocs-mermaid2-plugin = "^1.1.1"
139-
mkdocs-section-index = "^0.3.9"
140-
mkdocs-spellcheck = "^1.1.0"
141-
mkdocstrings = "^0.30.0"
142-
mkdocstrings-python = "^1.10.2"
135+
mkdocs-include-markdown-plugin = "^7.2.1"
136+
mkdocs-literate-nav = "^0.6.2"
137+
mkdocs-macros-plugin = "^1.5.0"
138+
mkdocs-mermaid2-plugin = "^1.2.3"
139+
mkdocs-section-index = "^0.3.10"
140+
mkdocs-spellcheck = "^1.2.0"
141+
mkdocstrings = "^1.0.2"
142+
mkdocstrings-python = "^2.0.1"
143143
nodeenv = "^1.9.1"
144144
packaging = ">=24.0"
145+
pydantic = "^2.12.5"
145146
pygments = "^2.17.2"
146147
pymdown-extensions = "^10.8.1"
147148
requests = "^2.31.0"
@@ -472,27 +473,21 @@ commands_pre =
472473
473474
[testenv:docs]
474475
basepython = {env:DOC_PYTHON_VERSION}
475-
passenv =
476-
GITHUB_PAT
477476
deps =
478477
-rdocs/requirements.txt
479478
commands_pre =
480479
nodeenv --python-virtualenv --clean-src
481-
python scripts/install_insiders_packages.py
482480
commands =
483481
python -c "import shutil; shutil.rmtree('.results_{envname}', ignore_errors=True)"
484482
mkdocs --verbose build --site-dir .results_{envname}
485483
486484
[testenv:doctests]
487485
basepython = {env:DOC_PYTHON_VERSION}
488-
passenv =
489-
GITHUB_PAT
490486
deps =
491487
-rdocs/requirements.txt
492488
-rtests/requirements.txt
493489
commands_pre =
494490
nodeenv --python-virtualenv --clean-src
495-
python scripts/install_insiders_packages.py
496491
commands =
497492
pytest -v -k "test_docs" --showlocals --junitxml={tox_root}/.results_{envname}/results.xml --self-contained-html --html={tox_root}/.results_{envname}/results.html
498493

scripts/install_insiders_packages.py

Lines changed: 0 additions & 131 deletions
This file was deleted.

src/tm_devices/components/dm_config_parser.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,9 +118,9 @@ def defined_config_file_path(self) -> str:
118118
"""Filepath of the config file.
119119
120120
Prioritizes the path contained in the environment variable defined by
121-
[`DMConfigParser.CONFIG_FILE_PATH_ENV_VARIABLE`][tm_devices.components.DMConfigParser.CONFIG_FILE_PATH_ENV_VARIABLE]
121+
[`DMConfigParser.CONFIG_FILE_PATH_ENV_VARIABLE`][tm_devices.components.dm_config_parser.DMConfigParser.CONFIG_FILE_PATH_ENV_VARIABLE]
122122
with a fallback to the default path defined by
123-
[`DMConfigParser.DEFAULT_CONFIG_FILE_PATH`][tm_devices.components.DMConfigParser.DEFAULT_CONFIG_FILE_PATH].
123+
[`DMConfigParser.DEFAULT_CONFIG_FILE_PATH`][tm_devices.components.dm_config_parser.DMConfigParser.DEFAULT_CONFIG_FILE_PATH].
124124
"""
125125
return os.getenv(
126126
self.CONFIG_FILE_PATH_ENV_VARIABLE,
@@ -304,7 +304,7 @@ def write_config_to_file(self, config_file_path: str | os.PathLike[str] | None =
304304
305305
This method will overwrite any existing config file with the current devices and options. If
306306
no custom path is provided, it will write to the file defined by
307-
[`DMConfigParser.defined_config_file_path`][tm_devices.components.DMConfigParser.defined_config_file_path].
307+
[`DMConfigParser.defined_config_file_path`][tm_devices.components.dm_config_parser.DMConfigParser.defined_config_file_path].
308308
309309
Args:
310310
config_file_path: The path to the config file. If ends in ".toml" will create toml file.

0 commit comments

Comments
 (0)