feat: Pretty materialization - #62
Merged
Merged
Conversation
CasperTeirlinck
marked this pull request as ready for review
August 28, 2026 12:45
jvanbuel
approved these changes
Aug 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We use the console and markdown materializers often to present metrics directly to users (users use the CLI to print the results, and we also post the markdown table on PR's). While it is an easy way to iterate on the metrics like that, the presentation of these materializations can be improved imo.
For example we use a lot of boolean metrics as so called "healthchecks", which now show as
0 / 1 | booleanto the user. I'd like to propose a "pretty" flag to these materializers so they print for presentation to the users instead of the raw metric fields in table format (which remain ideal for machines).The unit of a metric is a free text field on purpose, but the idea is that some well-known units deserve a nice presentation. For example:
"boolean": ✓/✗"percent": %Summary
Changes to the
ConsoleMaterializerandMarkdownMaterializer:UnitStrEnum with some well-know units (bool and percent atm) that are free to use when defining (custom) metrics.prettyflag to the 2 mentioned materializers that toggles special formatting depending on the unit.Some related changes:
Examples
You can put this in the checkup.yaml to set the default:
A basic

checkup runin this repo now gives (see new defaults in the yaml:or as before

checkup run --materializer console:pretty=false:But the effect gives better when you have healthcheck-type metrics that are all boolean:

versus without the pretty flag and column filter: