-
Notifications
You must be signed in to change notification settings - Fork 8
Fix mkdocsstrings config #412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the mkdocstrings configuration in generated and template docs by renaming the deprecated import
key to inventories
and relocating the paths
setting to the correct indentation under the python
handler.
- Rename
import:
toinventories:
in all mkdocs.yml files - Move
paths:
out of theoptions:
block directly under thepython:
handler - Add a migration helper in
cookiecutter/migrate.py
and update release notes
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
tests_golden/integration/.../model/frequenz-model-test/mkdocs.yml | Rename import → inventories and adjust paths location |
tests_golden/integration/.../lib/frequenz-test-python/mkdocs.yml | Rename import → inventories and adjust paths location |
tests_golden/integration/.../app/frequenz-app-test/mkdocs.yml | Rename import → inventories and adjust paths location |
tests_golden/integration/.../api/frequenz-api-test/mkdocs.yml | Rename import → inventories and adjust paths location |
tests_golden/integration/.../actor/frequenz-actor-test/mkdocs.yml | Rename import → inventories and adjust paths location |
mkdocs.yml | Rename import → inventories and adjust paths location |
cookiecutter/{{cookiecutter.github_repo_name}}/mkdocs.yml | Rename import → inventories and adjust templated paths |
cookiecutter/migrate.py | Add migrate_mkdocs_yaml to move paths and rename keys |
RELEASE_NOTES.md | Document import →inventories change and fix relocation note |
Comments suppressed due to low confidence (2)
cookiecutter/migrate.py:53
- The docstring claims it removes the old
options:
line, but the code only removes thepaths:
line. Update the docstring (or code) to accurately reflect the actual behavior.
rewrite the file in place to move `paths` directly under `python:` and remove the old `options:` and its `paths:` line.
cookiecutter/migrate.py:71
- [nitpick] This logic relies on hardcoded spaces for indentation, which is brittle. Consider parsing YAML or deriving indentation levels dynamically for more robust migrations.
if line.startswith(" python:"):
2e06695
to
213e42a
Compare
Signed-off-by: Leandro Lucarella <[email protected]>
Signed-off-by: Leandro Lucarella <[email protected]>
import
config key toinventories
paths
key in mkdocs.yml