Repository navigation
feat: srcly report --dataflow, data-flow metrics and code-viewer marks - #399
Merged
Merged
Conversation
report --dataflow runs the engine's fileSignals op beside the scan, writes dataflow.md (work packets) and a Data flow section in report.md, and lays six data-flow metrics over the tree. compare --dataflow diffs them. The app colors the treemap and marks the code viewer from the last saved result while the files still match. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 21, 2026
byronwall
marked this pull request as ready for review
November 21, 2026 14:52
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.
srcly report --dataflownow runs the TypeScript data-flow engine beside the scan. It writesdataflow.mdwith ranked work packets, adds a Data flow section with every finding toreport.md, and adds six data-flow metrics per TS/TSX file.srcly compare --dataflowdiffs those metrics, and the app colors the treemap and marks the code viewer from the last run.What you'll see
srcly report --dataflow(needs Node 18+; minutes on a big app, so it is opt-in). New artifactdataflow.md(listed in the manifest, read order 4).report.mdgets## Data flowwith eachimpossible-defenseandrepeated-forkfinding by line, or "Not analyzed: ".srcly compare --dataflowruns the engine on both sides (a commit side in a throwaway checkout) and diffs the metrics. This replaces tsx-data-flow's--baselineand--compare.--dataflowrun on the same files: color the treemap by Impossible Defenses, and the code viewer marks the line of each finding. The app never starts the tier-2 run itself.Proof
The app on
engine/examples/bad-ish-solidaftersrcly report --dataflow, colored by Impossible Defenses:DashboardShell.tsxis red with 12 (the explorer's "Dead?" column), the other files 0.The code viewer's marks for that file (
GET /api/files/markers) return 12dataflow_impossible_defenseslines, one per finding.SRCLY_ENGINE_DEV=1 srcly report --dataflow --profile frontend engine/examples/bad-ish-solid, the newreport.mdsection (trimmed):dataflow.mdfrom the same run (start and end):Its six sections match the archived tsx-data-flow CLI byte for byte (see #398).
srcly compare --dataflowon a copy of the example as a git repo, after removing two dead??from the working tree (trimmed):Tests:
tests/test_dataflow_signals.py(overlay sums and maxes, N/A reasons, marks count equals the metric,report --dataflowwritesdataflow.mdand the plain report never starts the engine).scripts/check.shpasses.Limits
context-relayandbroad-prop-bundleare not finding rules yet; their evidence is indataflow.mdonly.comparehas nonode_modules, so both sides use srcly's bundled TypeScript (like compare's checks).Survey moves: server: traces +4, outcome partial +4, stops +55 (budget-exhausted +1, external-code +43, untraced +11). New Python exports in
server/(dataflow/signals.py) enter the survey's hash sample; no analysis code changed.Stack: data-flow reporting, layer 2 of 3
This slice:
report --dataflow,compare --dataflow, the six metrics, treemap and code-viewer marks.Why it is its own layer: It is the user-visible change and touches the server, catalog and client defaults; the engine op below it stands alone.
Full story: #398
🤖 Generated with Claude Code