-
Notifications
You must be signed in to change notification settings - Fork 54
Try to fix errors in sphinx builds #223
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
base: main
Are you sure you want to change the base?
Conversation
|
It seemed to me like we were building the docs both using the web hooks (to build in readthedocs.org) and using CI actions. I just removed the CI actions and left the web hooks, since I think that method was working. We can alternately go for the CI actions approach (which hls4ml uses). I am not sure if the changelog is working. I think it needs to be in the main branch for it to work, but I am not positive. I uploaded a token in readthedocs.org so I think it's setup to work properly. |
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 attempts to fix Sphinx build errors for Read the Docs documentation by updating dependencies, fixing docstring formatting issues, and improving documentation links. The changes include adding cmake as a build dependency, updating package versions, migrating to myst_parser for Markdown support, and reformatting Python docstrings to comply with Sphinx parsing requirements.
Key changes:
- Updated documentation dependencies and added myst_parser support for Markdown files
- Fixed docstring formatting in transformation modules to resolve Sphinx parsing errors
- Added changelog infrastructure and updated GitHub Actions workflow versions
Reviewed changes
Copilot reviewed 15 out of 16 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/conf.py | Added myst_parser and sphinx_github_changelog extensions, configured source suffixes for Markdown support, updated copyright year to 2025 |
| docs/requirements.txt | Updated package versions with more flexible constraints and added new documentation dependencies (myst_parser, sphinx_github_changelog) |
| docs/readme.rst | Changed from including README.rst to README.md with myst_parser |
| docs/changelog.rst | Replaced simple reference with sphinx_github_changelog directive for automated changelog generation |
| docs/index.rst | Updated custom operator links to use .html extensions and added custom-ops overview to toctree |
| docs/license.rst | Changed from include to literalinclude directive |
| docs/tutorials.rst | Simplified list formatting by removing empty bullets |
| .readthedocs.yaml | Added cmake as apt package dependency |
| .github/workflows/test.yml | Updated checkout action from v2 to v4 and setup-python from v2 to v4 |
| .github/workflows/docs.yml | Removed entire workflow file (likely replaced by ReadTheDocs integration) |
| src/qonnx/transformation/quantize_graph.py | Added blank lines and proper indentation for docstring sections to fix Sphinx parsing |
| src/qonnx/transformation/qonnx_to_qcdq.py | Added blank lines in docstring lists to fix Sphinx parsing |
| src/qonnx/transformation/qcdq_to_qonnx.py | Reformatted Returns section and Input/Output sections with proper RST structure |
| src/qonnx/transformation/insert.py | Fixed parameter list indentation in docstring |
| src/qonnx/transformation/fixedpt_quantize.py | Added blank lines before Parameters sections |
| src/qonnx/custom_op/registry.py | Converted example to RST code block with :: directive |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
I believe this is ready. The documentation can be updated some more, but I did make some updates, and I tried to fix broken links. I think the release notes only work in the main branch, so the fact that it's empty is not an issue, I don't think--I am not a sphinx expert. Please let me know if it needs to be fixed some way. |
This is an attempt to fix the builds for read-the-docs. I added cmake, as apparently required in
.readthedocs.yaml. I am not very experienced with this setup so please check that what I am doing is reasonable.I also attempted to fix parsing errors in docstrings, and I tried to fix some broken links. The linking between different
.mdfiles seems to not always work. In some places it seems like the system properly adds an.htmlextension, while other times I have to explicitly put the.htmlin the links to original-.mdfiles. Those that are more experienced, please take a look.I also tried to copy the changelog setup from
hls4mltoqonnx, but we may need to update the project or add an access key for that to work. Alternately, we can remove it.