Repository navigation
Conversation
A Reports view (gr) shows documents attached to the snapshot: generators diffle runs when a changed file matches their globs, with copies of both sides and the review on stdin, and reports pushed over PUT /api/reports by an agent or `diffle report put`. Blocks are sandboxed markdown or rendered page pairs shown with the image comparison; an anchored block opens the diff at its line and takes a comment there. Pushed reports persist under the git dir and go stale when the diff moves on. Built-in rows for pixi.lock and Typst resolve from PATH; `diffle plugins` lists them, and the config's `plugins` adds or turns one off. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XY9UWfvKQAyZeDnYaZnihy
Contributor
|
This pull request changes committed snapshots. View the snapshot report to compare them side by side. |
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XY9UWfvKQAyZeDnYaZnihy
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XY9UWfvKQAyZeDnYaZnihy
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XY9UWfvKQAyZeDnYaZnihy
This branch has not been deployed
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.
Towards #269.
What
One report format, one Reports view (
gr), two ways for a report to arrive.src/shared/protocol.ts): a title, the snapshot target it was made for (shas plus a digest of the changed blobs, so a worktree side that moved on is told apart), and blocks:markdown, rendered through the existing sandboxed renderer, orpages, old/new image pairs shown with the existing swipe, onion skin and difference comparison. A block may carry an anchor (path:line);Enteropens the diff there andccomments there, so findings become ordinary comments, in the prompt and on GitHub. Anchors the snapshot does not show are dropped with a note in the report's log.crates/diffle/src/reports/): a program diffle runs when a changed file matches its globs. It gets copies of both sides (the matched files, or the whole snapshot forscope: tree) through the session's allowlisted reads, the review as JSON on stdin, andDIFFLE_OLD/DIFFLE_NEW/DIFFLE_OUT/DIFFLE_ROOT(plusDIFFLE_FILEfor a per-file command). It writesreport.jsonand its files intoDIFFLE_OUT, or just prints markdown. Commands run without a shell; a|pipes one program into the next. A newer snapshot kills a run in flight, results cache by input digest, and a result commits only while its snapshot is current. Built-in rows forpixi(pixi-diff | pixi-diff-to-markdown) andtypst(diffle-typst) resolve fromPATHlike language servers;diffle pluginslists them. Commands come from the user config only, never from the reviewed tree, so a pull request cannot bring its own.PUT /api/reports/{id}(files first viaPUT /api/reports/{id}/files/<path>),DELETE,GETlist/one/file/log. Atargetother than the current snapshot's answers 409 with the current one. Pushed reports persist under<git-dir>/diffle/keyed by comment key and go stale, not away, when the diff moves.diffle report put <file>anddiffle report delete <id>talk to the running server, which announces its URL in<git-dir>/diffle/server.jsonwhile it runs.src/client/reports/): the view with a side list,j/kover blocks,J/Kover reports, status (running, failed, stale) and the log under the header.example/plugins/diffle-typst: a reference generator (Python, no deps) that compiles each changed.typon both sides to PNG pages. Manuel's inline-removals render (feat(render): typeset removed words in place ManuelLerchner/diffle#3) would slot in as that program's output.Tests
crates/diffle/tests/reports.rs: push, list, persistence across servers, staleness, uploads and file serving by key, 409 on stale targets, and generators driven bytest/reports/fake-generator.mjs(json and stdout modes, per-file runs, tree scope, failures, a program not on PATH, runs superseded by a refresh).crates/diffle/tests/cli.rs:diffle report putend to end against a served review, and the announcement withdrawn at shutdown.test/client/reports.test.ts: view state and keys.test/e2e/reports.spec.ts: the generator's pages and a pushed report, thenEnterandcinto the diff.Notes for review
test/e2e/__snapshots__/reports.spec.ts/were made with a local Chromium, not the Docker one; and every other spec's screenshots now show a third button in the view switch. Both need theUpdate snapshotsworkflow once CI has run.PATHinstead of shipping rows.Generated by Claude Code