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
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
pedpy/methods/— e.g.acceleration_calculator.py,speed_calculator.py,density_calculator.py,profile_calculator.pydocs/source/.pre-commit-config.yamlsphinx-lintorrstcheck— both support pre-commit and catch malformed math directivesAcceptance Criteria
.pre-commit-config.yamlcoveringdocs/source/**/*.rst