feat(inspector): list the statements behind each Analysis finding - #933
Merged
lcottercertinia merged 4 commits intoAug 14, 2026
Merged
Conversation
Whole-log governor readouts read a metric's peak across the metric-strip series, not its final level. No metric is monotonic — heap falls on a deallocation and a log's cumulative report can fall too — and a governor charges the transaction at its highest point. limitTotals() is the one shared source, memoised per series, so the overview gauges, the trend charts and the Database overview agree. The Database overview also hides a limit the log never reported, instead of showing the platform default as if the log had said it.
A finding lists up to five of the statements it grouped, most repeated first, each with how many times it ran, headed by how many there are in all. A query renders through the SOQL formatter, fitted to the pane, so its FROM and WHERE stay readable. Clicking one reveals its row in the grid. Adds a row-at-a-time finding: one query built per record, spreading one call site over as many texts as there were records. Repetition findings name the enclosing frame, since a line number alone reads the same for every class that queries at that line.
…fication # Conflicts: # lana-docs/docs/docs/features/inspector.md
One line over the print width, from the peak-figure change.
lcottercertinia
approved these changes
Aug 14, 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.
What
Two changes to the whole-log Analysis findings, plus a correction to every governor readout.
Findings list the statements behind them
A finding now lists up to five of the statements it grouped, most repeated first, each with how
many times it ran, headed by how many there are in all. A query renders through the SOQL
formatter, fitted to the pane's measured width, so its
FROMandWHEREstay readable howeverlong the field list is. Clicking a statement reveals its row in the Analysis grid.
A row-at-a-time finding
One query built per record and run a row at a time spreads a single call site over as many
statement texts as there were records, so repetition rules never see it. The new rule groups by
call site instead of by text and names it.
Repetition findings now name the enclosing frame rather than the line alone: a line number reads
the same for every class that happens to query at that line, so several loops in different
classes were indistinguishable.
Governor figures at their peak
Every whole-log readout — the overview gauges, the governor trends, the Database overview and the
findings — reported the metric's final level, which under-reports any metric that falls back
before the log ends. They now all read the peak, the level the governor charges the
transaction at, from one shared memoised total. The timeline governor strip still plots the log as
recorded.
Testing
pnpm test— 128 suites, 1712 tests passpnpm lint— clean