Repository navigation
Move eight orphaned doc blocks back to their members, and pin the class (#1745) - #1751
Merged
Merged
Conversation
An edit that inserts a new member and its <summary> ABOVE an existing summary strands that summary on the wrong member: the new member reads with a description of something else, and the member the block actually described is left undocumented. XML docs take the LAST summary, so tooling renders correctly, the build is clean, nothing warns, and no behavioral test can see it. Eight sites on dev. TWO were introduced by #1739/#1744 -- the PRs that fixed two other instances of this same class -- leaving RunCollectionLoopAsync and EvaluateCompressionJobsAsync undocumented. The other six were pre-existing across four projects. SEVEN of the eight are fixed by MOVING the orphaned block back to the member it describes. Only LocalDataService.QueryStore.cs held a genuine superseded duplicate safe to delete. A blind "remove the extra summary" sweep would have destroyed documentation at seven sites, so the guard's failure message says that outright. The pin walks every .cs outside bin/obj from the repo root and fails on </summary> immediately followed by <summary>. It FAILS rather than skips when it cannot find the tree: a guard that silently skips is a guard that silently stops guarding. Verified both ways -- green on the fixed tree, red naming Lite\Services\RemoteCollectorService.cs:29 when a stacked block is re-introduced, which is a Lite mutation caught by a test in Darling.Tests. Darling 3360, Lite 1575, Dashboard 768, zero failures. Documentation and one test only; no behavior changes. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
erikdarlingdata
enabled auto-merge
July 27, 2026 02:32
# Conflicts: # CHANGELOG.md
…ummaries # Conflicts: # CHANGELOG.md
…into feature/1745-stacked-summaries
# Conflicts: # CHANGELOG.md
This was referenced Jul 27, 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.
Closes #1745. Audited at
f54485ee(dev), fixed and pinned.The inventory was six. It is eight — and two of the new ones were introduced by the PRs that fixed this exact class.
#1745 listed six sites found on dev before #1744 merged. Re-scanning dev at
f54485eefinds eight. The two additions areDarlingWorker.csandDarlingSelfAlertEvaluator.cs— the two files #1739's alert-surfacing fix touched. So the class recurred inside the change that was fixing two other instances of it, and shipped.The defect is worse than duplication: it is displacement
The issue framed this as a member carrying two summaries. That undersells it. The mechanism is an edit inserting a new member and its summary above an existing summary rather than below it. The result is two casualties, not one:
RunCollectionLoopAsyncandEvaluateCompressionJobsAsyncare both currently undocumented on dev for exactly this reason.That inverts the fix. Seven of the eight needed the orphaned block moved back to its real member. Only one was a superseded duplicate safe to delete. The obvious sweep — "remove the extra summary" — would have destroyed real documentation at seven of eight sites. The guard's failure message says so explicitly, so the next person hitting it does not reach for the obvious wrong fix.
Per-site disposition — all eight, including the one that needed nothing moved
f54485ee)DarlingWorker.cs:582RunCollectionLoopAsync:605DarlingSelfAlertEvaluator.cs:1127EvaluateCompressionJobsAsync:1235TimescaleSupport.cs:369CreateQueryStatsDailySql:422MainWindow.xaml.cs:768RefreshVisibleAsync:786ViewerDataService.FinOps.Inventory.cs:130ServerInventorySql:147ThemeParityTests.cs:194FindRepoRoot:198RemoteCollectorService.cs:30class RemoteCollectorService:99LocalDataService.QueryStore.cs:418Site 8 is the only genuine duplicate: both summaries describe
GetQueryStoreHistoryAsync, the doc was rewritten from "a specific query" to "ALL plans of a query", and the new text was added below the old instead of replacing it. I confirmed there is no per-plan sibling method and that the preceding method (GetQueryStoreComparisonAsync) kept its own docs, so nothing was displaced here.Every MOVE was verified the same way before touching it: locate the member the orphaned prose actually describes, confirm that member currently has no doc comment, then move the block to it. No block was deleted on the assumption it was redundant.
The pin
Darling/Darling.Tests/DocCommentHygieneTests.cs— walks every.csoutsidebin/objfrom the repo root and fails on</summary>immediately followed by<summary>.Two design points worth the review:
It fails rather than skips when it cannot find the tree. A
Skiphere would mean the rule silently stops being enforced the day the output layout changes, and nobody would notice — which is the same shape as the defect it guards. If the walk-up breaks, this goes red and gets fixed.Its failure message tells you not to take the obvious fix, because the obvious fix is wrong seven times out of eight.
Verified in both directions, which is the only thing that makes a pin worth having:
That red is a mutation in Lite caught by a test living in Darling.Tests, which is the cross-project reach the rule needs.
Coverage limit, stated rather than assumed. CI path filters are per-project, so this runs on any PR tripping the
darlingorcorefilter and on every nightly and release build — but a change touching only Lite or Installer will not run it, and would be caught on the next nightly instead. It lives inDarling.Testsbecause the repo's other source-parsing pins do (HostHeaderGuardTests,DarlingStoreUpgradeTests), which is where someone looks for this kind of guard. The limitation is documented in the test itself.Testing
dotnet teston all three affected suites: Darling 3360, Lite 1575, Dashboard 768, zero failures.One disclosure so the number is not overstated: the Lite build emits a pre-existing
CS8602inLite/MainWindow.AlertEngine.cs:262. That file is not in this diff and the warning is present on dev independently of this change — I am not claiming a zero-warning build, only that this PR adds none.Net −3 source lines across eight files: seven zero-sum moves plus one deletion. Documentation and one test; no behavior changes anywhere.
🤖 Generated with Claude Code