Installation#

YMPrint requires Python 3.14 or newer.

With pip#

pip install ymprint

With pip#

pip install ymprint

From source#

git clone https://github.com/StructuralPython/yamlreports.git
cd yamlreports
uv sync
uv run ym --help

What gets installed#

Installing YMPrint pulls in everything needed to render PDFs:

Dependency

Role

reportlab

The PDF layout engine that typesets your document.

pymupdf

Read PDF backgrounds, fill form fields, overlay content.

jinja2

Interpolate _vars into your content.

wenmode

Parses inline markdown (the latest library from lepture!)

pydantic

Validate the document, style, and table configuration.

pygments

Syntax highlighting for _code and _py blocks.

ruamel-yaml

Parse your report YAML.

typer

The ym command-line interface.

A set of fonts is bundled with YMPrint, so documents render consistently on any machine without needing to rely on system fonts (which may or may not load easily into ReportLab). See the Fonts reference.

Tip

matplotlib is not a hard dependency. Install it in the same environment only if you plan to use the _matplotfig block.

Live preview (optional)#

The ym live command opens the rendered PDF in the Okular document viewer which hot-reloads your PDF on every save.

The Okular PDF viewer is available for every desktop platform (Windows, Mac, and many flavours of Linux).

If you want to use live mode, install Okular through your system package manager, for example:

sudo apt install okular      # Debian / Ubuntu

If you are on Windows, you can install Okular with Winget or with the Windows store.