Skip to content

fix(reporter): stop test-origin bullets gluing onto the cost line#176

Merged
veksen merged 1 commit into
mainfrom
fix-test-origin-bullet-glue
Jul 14, 2026
Merged

fix(reporter): stop test-origin bullets gluing onto the cost line#176
veksen merged 1 commit into
mainfrom
fix-test-origin-bullet-glue

Conversation

@veksen

@veksen veksen commented Jul 14, 2026

Copy link
Copy Markdown
Member

What

In the CI PR comment, the test-origin queries excluded from the gate list rendered the second query on the same line as the first query's cost label:

SELECT "id", ... FROM "sessions" LIMIT 50;
cost 1- SELECT "id", ... FROM "item_watches" LIMIT 50;
cost 1

Why

The template engine is configured with trimBlocks: true (github.ts), which strips the newline immediately after a block tag. The test-origin row ended with a trailing {% endif %}, so that newline got eaten and the next - bullet glued onto the previous item's cost line. Every other row in this template already guards against this by appending {{""}} after the trailing {% endif %} — this section was the only one missing it.

Fix

Append the same {{""}} guard so the block tag is no longer the last token on the line and the newline survives.

Test

Added a regression test that renders two excluded queries and asserts each starts its own bullet. Verified it fails without the fix (reproduces cost 1- <code>…) and passes with it.

The test-origin-excluded row ended with a trailing `{% endif %}`. With
nunjucks `trimBlocks: true`, the newline after that tag is stripped, so
each query's `cost N` line ran straight into the next bullet
("cost 1- SELECT ..."). Append the same `{{""}}` guard the other rows
already use so the newline survives.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Query Doctor Analysis

3 queries analyzed

0 regressed · 0 improved · 0 new · 0 removed

2 pre-existing issues

Using assumed statistics (10000000 rows/table). For better results, sync production stats.

More detail → get_ci_run({ runId: "019f5e83-4b0f-79bc-9314-bbed5f800ade" }) · view run · docs

@veksen veksen merged commit 7d63559 into main Jul 14, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant