Skip to content
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

DOC - Improvement: Making example code executable #754

Open
ianhi opened this issue Feb 19, 2025 · 1 comment
Open

DOC - Improvement: Making example code executable #754

ianhi opened this issue Feb 19, 2025 · 1 comment
Labels
documentation 📝 Improvements or additions to documentation enhancement ✨ New feature or request

Comments

@ianhi
Copy link
Contributor

ianhi commented Feb 19, 2025

Problem

Code in the docs can have typos, or may work when it was written but becomes out of date with underlying changes. We need a way to regularly run the example code in the docs.

Solutions?

I think there are two approaches to this.

  1. Transform the docs and include them as part of the test suite

Conceptually just extracting the python and running it, but there is some complexity. That can be managed by somethign like: https://github.com/koaning/mktestdocs

However it does not seem like any of the existing solutions will easily allow us to manage the code blocks where the user chooses between local and s3 storage so that's one potential roadblock.

  1. Swap the docs framework to something that natively understands executable documents. e.g. with myst markdown based docs. Then the code can be executed as part of the docs. I personally like this solution as it also lends itself towards allowing a reader to open a jupyterhub with the docs page, but it is python centric and would require redoing the docs configuration.
@ianhi ianhi added documentation 📝 Improvements or additions to documentation enhancement ✨ New feature or request labels Feb 19, 2025
@paraseba
Copy link
Collaborator

@jhamman may have opinions on this. He recently migrated us to readthedocs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation 📝 Improvements or additions to documentation enhancement ✨ New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants