Skip to content

Fix broken equation rendering in user guide #549

Description

@schroedtert

Summary

Fix incorrectly rendered equations in the user guide and add a pre-commit RST lint check for docs/. Equations using :math: and .. math:: directives in Python docstrings are not displaying correctly in the built documentation.

Background / Context

PedPy's method documentation relies heavily on equations to describe the implemented algorithms. Broken rendering degrades usability for the target audience. The existing pre-commit config covers Python linting and notebook stripping but nothing validates RST/math markup, so regressions go undetected until a docs build.

Technical Details

  • Equations live in docstrings throughout pedpy/methods/ — e.g. acceleration_calculator.py, speed_calculator.py, density_calculator.py, profile_calculator.py
  • RST source files are under docs/source/
  • Pre-commit config: .pre-commit-config.yaml
  • Candidate hooks: sphinx-lint or rstcheck — both support pre-commit and catch malformed math directives

Acceptance Criteria

  • All equations render correctly in the ReadTheDocs build
  • A pre-commit RST lint hook is added to .pre-commit-config.yaml covering docs/source/**/*.rst
  • No math-related Sphinx warnings in the ReadTheDocs build log

Metadata

Metadata

Assignees

Labels

documentationImprovements or additions to documentation

Type

Fields

No fields configured for Bug.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions