Skip to content

CI: end-to-end execution of documentation code blocks #638

Description

@planetf1

Add a CI job that extracts Python code blocks from docs and executes them in a sandboxed environment to catch runtime errors (wrong attributes, type mismatches, NotImplementedError, etc.).

Context: PR #601 review found 5 runtime errors (E2, E4, E6, E7, E8) that static checks couldn't detect — wrong method calls, missing attributes, incorrect module paths that only fail at execution time.

Scope:

  • Extract fenced python blocks from docs/docs/**/*.md
  • Run each in a subprocess with timeout (skip blocks marked as fragments)
  • Requires mellea installed + Ollama backend available
  • Non-deterministic LLM output is expected — validate no crashes, not output content
  • Runs on PR and nightly (backend availability may limit PR runs)

Related: #617 (build process), #636 (Document.parts bug found by this kind of testing)

Metadata

Metadata

Assignees

Labels

documentationImprovements or additions to documentationenhancementNew feature or requesttesting

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions