feat(typst): summarize the first compiler error #101

Merged
barrettruth merged 1 commit from feat/typst-failure-summary into main 2026-04-26 01:47:07 +00:00
barrettruth commented 2026-04-26 01:45:54 +00:00

Problem

The built-in typst preset already parses short-format diagnostics, but failed compiles still fall back to generic failure notifications even when the first actionable error message is available. The preset also lacked fixture-backed coverage for watch-mode boilerplate, CLI fallback shapes, warning-only output, and other audited typst failure forms.

Solution

Reuse parse_typst for a preset-level failure_summary that returns the first ERROR diagnostic message and falls back for warning-only or non-source-located CLI output. Add fixture-backed preset coverage for the audited typst shapes and a compiler smoke test that routes the real typst preset summary through the notification path.

## Problem The built-in `typst` preset already parses short-format diagnostics, but failed compiles still fall back to generic failure notifications even when the first actionable error message is available. The preset also lacked fixture-backed coverage for watch-mode boilerplate, CLI fallback shapes, warning-only output, and other audited typst failure forms. ## Solution Reuse `parse_typst` for a preset-level `failure_summary` that returns the first `ERROR` diagnostic message and falls back for warning-only or non-source-located CLI output. Add fixture-backed preset coverage for the audited typst shapes and a compiler smoke test that routes the real typst preset summary through the notification path.
Sign in to join this conversation.
No description provided.