Skip to content

ci: bump mordant to 52896c0 - #43817

Merged
alii merged 1 commit into
mainfrom
robobun/5c0dd972/bump-mordant-52896c0
Sep 22, 2026
Merged

alii merged 1 commit into
mainfrom
robobun/5c0dd972/bump-mordant-52896c0

Conversation

@robobun

@robobun robobun commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

  • mordant-baseline.toml holds a count of allowed findings for each lint and file, not which findings. When a file went over its count, mordant hid the first N findings in file order and printed the rest.
  • So the finding it printed could be an old one. On node:fs: call callbacks from the native completion, not a promise reaction #43728 the baseline allowed three generic_body_not_generic findings in node_fs.rs, and the change added a fourth, UVFSRequest::run_from_js_thread. The CI annotation named readdir_with_entries_recursive_async at node_fs.rs:6446, which is not in that diff.

Fix

  • MORDANT_REV moves to 52896c0cc7c1751bbe29672dbc1f007d7d52f3f3 (Show every finding of a lint in a file that is over its baseline scarletindustries/mordant#30). MORDANT_TOOLCHAIN stays nightly-2026-09-01.
  • From this revision a file that goes over prints every finding of that lint, then one line with the number found and the number the baseline allows. A file within its count still prints nothing.
  • target/mordant/over-baseline.txt counts the same as before, so the job fails in the same cases. The workflow notes describe the new output.
  • Verified: a cold run of the job's steps is clean and prints nothing about the baseline. With no baseline, the findings are the same 467 as with 00778d3 (all lints, line by line). A regeneration leaves mordant-baseline.toml unchanged.

Background

  • The baseline counts because line numbers move with every edit. The price is that mordant cannot tell a new finding from an old one in the same file.
  • The job runs bun scripts/rust-mordant.ts over three targets and then tests that target/mordant/over-baseline.txt is empty or absent.
Notes

The new output, with the entry for src/runtime/node/node_fs.rs lowered from 3 to 2 on this branch: the three findings in that file (CpSingleTask::create, mkdir_recursive_os_path_impl, readdir_with_entries_recursive_async), each with the note generic_body_not_generic over the mordant baseline (2 recorded for src/runtime/node/node_fs.rs), and then:

warning: mordant: 3 `generic_body_not_generic` findings in src/runtime/node/node_fs.rs, and the baseline allows 2. The baseline holds a count, not which findings, so all 3 are shown: any of them can be the new one
warning: mordant: 1 finding(s) over the baseline in bun_runtime

A file with a large count prints all of it when one finding is added. The largest entry here is 105 derived_field findings in src/css/properties/margin_padding.rs. GitHub shows a limited number of annotations for a job, so for such a file the job log is the place to read.


no test proof · iteration 0 · build/CI scripts only; test-proof not applicable

The baseline holds a count of findings for each lint and file, not which
findings. When a file went over, mordant hid the first N findings in the
file and printed the rest, so a new finding written above the old ones
was hidden and an old one was printed in its place. On #43728 the
annotation named a function the change did not touch.

From this revision a file that goes over prints every finding of that
lint, then one line with the number found and the number the baseline
allows. A file within its count still prints nothing, and
target/mordant/over-baseline.txt counts the same as before.

Nothing else changes over this workspace: the findings are the same as
with 00778d3, and a regeneration leaves mordant-baseline.toml as it is.
@robobun

robobun commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator Author

Status: merged.

  • Requested in chat by @alii after Show every finding of a lint in a file that is over its baseline scarletindustries/mordant#30 merged.
  • Verified locally at 52896c0cc7c1751bbe29672dbc1f007d7d52f3f3: bun scripts/rust-mordant.ts from an empty target/mordant is clean (three targets) and prints nothing about the baseline.
  • With no baseline, the new revision prints the same 467 unique findings as the previous one over the same tree (all lints, compared line by line).
  • bun run rust:mordant:baseline leaves mordant-baseline.toml unchanged.
  • The new output, checked by lowering the node_fs.rs entry from 3 to 2: all three findings of that file are printed, then 3 ... findings in src/runtime/node/node_fs.rs, and the baseline allows 2, and target/mordant/over-baseline.txt gets bun_runtime 1.
  • CI proof: the mordant check passed on 00e2a01 in 4m04s (job), with the new revision built from source and nothing over the baseline.

@coderabbitai

coderabbitai Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: oven-sh/bun/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Essentials

Run ID: d49d0bea-3130-4f38-85b1-2492092f6030

📥 Commits

Reviewing files that changed from the base of the PR and between 87466cf and 00e2a01.

📒 Files selected for processing (2)
  • .github/workflows/CLAUDE.md
  • .github/workflows/rust-lints.yml

Included review availability: Your plan provides up to 10 included reviews per hour; 4 remain after this review.


Walkthrough

The Mordant workflow now pins revision 52896c0cc7c1751bbe29672dbc1f007d7d52f3f3. Its baseline documentation clarifies how findings are counted and reported when a file exceeds its allowed count.

Changes

Mordant lint baseline

Layer / File(s) Summary
Revision pin and baseline behavior
.github/workflows/rust-lints.yml, .github/workflows/CLAUDE.md
The workflow pins the new Mordant revision. The documentation states that counts apply per lint and file, and that exceeding a count prints all findings for that lint with found and allowed totals.

Suggested reviewers: jarred-sumner, dylan-conway

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to 00e2a

Over-baseline lint output will show all findings while the existing baseline failure check remains in place. No concrete merge-blocking regression is evident.

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely identifies the Mordant revision update, which is the main change.
Description check ✅ Passed The description explains the problem, the fix, and how the change was verified. It does not use the template’s exact headings, but it provides the required information.

Comment @coderabbitai help to get the list of available commands.

@alii
alii merged commit 8a4ae59 into main Sep 22, 2026
10 of 12 checks passed
@alii
alii deleted the robobun/5c0dd972/bump-mordant-52896c0 branch September 22, 2026 22:33

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code review found no issues

No high-confidence issues detected in this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants