Skip to content

docs: enable myst_parser so Markdown docs actually publish#40

Merged
dml-jarvis merged 1 commit into
mainfrom
fix/docs-enable-myst-parser
Jun 3, 2026
Merged

docs: enable myst_parser so Markdown docs actually publish#40
dml-jarvis merged 1 commit into
mainfrom
fix/docs-enable-myst-parser

Conversation

@dml-jarvis

Copy link
Copy Markdown
Collaborator

The docs toctree (index.rst) references several Markdown documents — dsl_tutorial, dsl_reference, material_schema_spec, mesh_validation, etc. — but conf.py only registered source_suffix='.rst' and never loaded a Markdown parser. As a result Sphinx emitted 'toctree contains reference to nonexisting document' for every .md file and those pages did NOT render on the published (Read the Docs) site.

Verified by A/B build:

  • WITHOUT this change: dsl_guide/dsl_tutorial/dsl_reference all fail with 'nonexisting document'; no HTML produced.
  • WITH this change: all three render to HTML; build succeeds.

Fix (minimal, standard):

  • conf.py: append 'myst_parser' to extensions (guarded by a try/import so an RST-only build still works if MyST isn't installed) and set source_suffix to map .rst→restructuredtext, .md→markdown.
  • docs/requirements.txt: add myst-parser so Read the Docs installs it.

This is a pure infrastructure fix — no doc content changes here (the new DSL Language Guide + toctree wiring land in a separate commit).

Co-authored-by: jarvis-rich

The docs toctree (index.rst) references several Markdown documents —
dsl_tutorial, dsl_reference, material_schema_spec, mesh_validation, etc. —
but conf.py only registered source_suffix='.rst' and never loaded a Markdown
parser. As a result Sphinx emitted 'toctree contains reference to nonexisting
document' for every .md file and those pages did NOT render on the published
(Read the Docs) site.

Verified by A/B build:
- WITHOUT this change: dsl_guide/dsl_tutorial/dsl_reference all fail with
  'nonexisting document'; no HTML produced.
- WITH this change: all three render to HTML; build succeeds.

Fix (minimal, standard):
- conf.py: append 'myst_parser' to extensions (guarded by a try/import so an
  RST-only build still works if MyST isn't installed) and set source_suffix
  to map .rst→restructuredtext, .md→markdown.
- docs/requirements.txt: add myst-parser so Read the Docs installs it.

This is a pure infrastructure fix — no doc content changes here (the new DSL
Language Guide + toctree wiring land in a separate commit).

Co-authored-by: jarvis-rich
@dml-jarvis
dml-jarvis merged commit 5a0a78d into main Jun 3, 2026
0 of 3 checks passed
@dml-jarvis
dml-jarvis deleted the fix/docs-enable-myst-parser branch June 3, 2026 22:41
dml-jarvis pushed a commit that referenced this pull request Jun 3, 2026
The yapCAD DSL had a reference (function/type catalog) and a tutorial (one
worked example), but no document teaching the language AS a language — its
mental model, execution semantics, and idioms. Newcomers had no on-ramp and
no 'how to think in this DSL' guide; the why/how lived scattered across
index.rst prose and historical specs.

Adds docs/dsl_guide.md — a DSL Language Guide covering:
- what the DSL is and why it exists (type safety, guaranteed termination,
  provenance, automation/LLM-friendliness)
- the execution model (module -> command -> emit -> CLI)
- UPPERCASE-export vs lowercase-helper command convention
- thinking in static types; the angle-units convention (degrees for
  geometry/transforms, radians for trig); control flow and no-while design
- the build/transform/boolean composition workflow
- idioms & gotchas (over-cut subtractions, 0.0 - x negation, degrees/radians
  mismatch, require contracts, aggregation over chained unions, radial patterns)
- @meta/@ui annotations and the CLI lifecycle

Documents the degrees-vs-radians convention that was previously only implicit
in per-function comments: transform/geometry functions (rotate, rotate_2d,
arc, ellipse) take DEGREES; trig (sin/cos/tan) takes RADIANS. Added prominent
callouts to the Guide (§4 + gotchas), the Reference (Transformation + Math
section headers), and the Tutorial (Tips).

Also wires the three docs into a clear learning path:
- index.rst toctree reordered to Guide -> Tutorial -> Reference
- reciprocal cross-links added to the Tutorial and Reference headers/footers

Depends on the myst_parser fix (PR #40, merged) for the Markdown to render.
Docs build verified clean (no dsl_guide warnings) against main.

Co-authored-by: jarvis-rich
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant