feat: bronkaart die klopt, een taalafspraak, en een ratchet per klasse #557
No reviewers
Labels
No labels
accepted
bug
declined
docs
duplicate
enhancement
good first issue
in-progress
needs-info
privacy
security
triage
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
LibreKAT/Ocideck!557
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/structuurschuld"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
The three parts of #518 that do not move code across many files.
#518stays open for the two that do.1. SOURCE_MAP claimed a line per file and did not deliver
Narrowed and filled: the promise is now a line per Dart library, with three exceptions that follow the grain of the code — a
partinherits its library's line, a conditional-import half (_io/_web/_stub) falls under its façade, and a uniform family is described as a group written as a glob that must still match real files.Not "just complete it", because two thirds of the missing entries were
partfiles and platform halves: a separate line for each says the same thing three times and buys only maintenance. Everything that carries a subject of its own now has one — 43 lines added.Two things surfaced while doing it:
marp_html_service.dartthat was a real decision: one copy carried a correction dated 22-07 00:22 saying the HTML export is not self-contained, while the branch that made it self-contained landed at 09:16 the same morning. The correction was itself out of date.lib/models/for a file that lives inlib/services/.test/source_map_coverage_test.dartguards four rules and was verified negatively with a planted file.2. Comment language — measured, not decided
The rule is Dutch or English, never both inside one comment, because that is what the code already does: of ~3,100 comment blocks of three or more lines in
lib/, 71% are Dutch, 28% English, and 1% mix the two within a block.So the rule records what exists rather than imposing a preference, and it says explicitly: do not rewrite existing comments for language. No behaviour change, thousands of lines of noise, and your name in
git blameunder someone else's reasoning. Not one existing comment was touched.3. A ratchet per class
maxClassLines = 1000, counted per class across allpartfiles of its library, including everyextension … onhanging off it. Same number as the file limit on purpose: the promise was "no unit over a thousand lines", and thepartsplit had quieted the gate while the class kept growing.Fifteen classes sit above it today. The largest is not
TabsNotifier(2,403) but_SettingsDialogStateat 7,295 lines across 22partfiles.Verified both ways: green on current code; red on a planted 1,204-line class split across two 605- and 604-line parts — where the file ratchet stays green. That is exactly the gap the issue describes. Also red on growth of an existing baselined class.
Two real bugs in the counter were caught by its own tests: a multi-line class header was missed entirely (including
_ChartPreviewState, 2,667 lines), and a'''string with a brace at column 0 confused it.The ratchet earned its keep on day one
During the rebase, the freshly landed #548 added 22 lines to
FileServiceand the new ratchet fired immediately on work that was not this branch's. The baseline was re-measured (2882 → 2904) and the commit amended, so the baseline belongs to the tree it lands on.Left deliberately
Git orchestration out of
lib/state/and splittingapp_shell. Both move code across many files while other branches are in flight — four commits landed onmainduring this session alone, one of them insideFileService. Every rebase conflict would look like a semantic conflict while being nothing of the sort.There is now a better reason to wait than timing: the class ratchet makes that debt visible and bounded —
TabsNotifieris pinned at 2,403 and may only shrink — so it can no longer grow quietly while the tree is busy. And the measurement suggests the target is wrong anyway:_SettingsDialogState(7,295) deserves attention beforeapp_shell.Verification
Built by a subagent in an isolated worktree; rebased and
make checkre-run by me: exit 0, 5,536 tests, 86.2% coverage.