Skip to content

Apply pytest to documentation notebooks #665

@genedan

Description

@genedan

Description

It's possible to test whether the docs notebooks can execute without errors or warnings with the nbmake plugin. I believe we currently find docs bugs by reading the docs or waiting for users to report them. But if we can use pytest to check for errors, we can address them preemptively.

Is your feature request aligned with the scope of the package?

  • Yes, absolutely!
  • No, but it's still worth discussing.
  • N/A (this request is not a codebase enhancement).

Describe the solution you'd like, or your current workaround.

After installing, running the command:

pytest --nbmake **/*ipynb

Produces:

Image

I haven't figured out how to get it to work recursively yet.

Do you have any additional supporting notes?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Documentation 📚Changes to docstrings or the documentation site. No codebase changes.Effort > Moderate 🐕Mid-sized tasks estimated to take a few days to a few weeks.Impact > Moderate 🔶User-visible but non-breaking change. Treated like a minor version bump (e.g., 0.6.5 → 0.7.0).python:uvPull requests that update python:uv code

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions