Skip to content
LogoLogo
diffxdiffx

Review Git changes in your browser.

Read diffs, mark files reviewed, comment on lines, and let your agents address the feedback.

Reviews/acme/apiretry-backoff1 of 3
UncommittedAllStagedUnstagedSplitUnified
TSsrc/retry.ts+8−1Reviewed
@@ -5,7 +5,14 @@ const baseDelay = 250;
5export async function retry<T>(task: () => Promise<T>, attempts = 6) {
6 return task();
6 for (let attempt = 0; ; attempt++) {
7 try {
8 return await task();
9 } catch (error) {
10 if (attempt + 1 >= attempts) throw error;
11 await sleep(baseDelay * 2 ** attempt);
12 }
13 }
14}
15
16export function isRetryable(status: number) {
17 return status === 429 || status >= 500;
18}
TSsrc/sleep.ts+7Reviewed
1export function sleep(ms: number) {
2 return new Promise<void>((resolve) => setTimeout(resolve, ms));
3}
4
5export function jitter(ms: number) {
6 return Math.round(ms * (0.5 + Math.random() / 2));
7}
TStest/http.test.ts+9Reviewed
@@ -18,6 +18,14 @@ describe("request", () => {
18 it("returns parsed JSON", async () => {
19 mockFetch(200, { ok: true });
20 expect(await request("/health")).toEqual({ ok: true });
21 });
22
23 it("retries a 503 before it succeeds", async () => {
24 mockFetch(503).then(200, { ok: true });
25 expect(await request("/health")).toEqual({ ok: true });

Every review on one bench

diffx opens on Reviews: each branch and pull request with changes, newest activity first. Needs attention collects what is new or updated since you last looked, including work your agents just pushed. Move with ↑ and ↓, peek with Space, open with Enter.

Reviewing changes

ReviewsHistory
Filter reviews…PeekSpace
ReviewSourceActivity
New and updatedMark all viewed
retry-backoffClaude Code · laptopnow
Add rate limit headersGitHub · @maya12m
Everything else5
Bump eslint to 10GitHub · @ana2h
Pin Node to 26GitHub · @lee1d
docs-refreshCodex · devbox2d
Fix login redirect loopGitHub · @sam3d
release/1.4ci-runner3d

Pull requests arrive on their own

Connect GitHub on a diffx server and follow repositories. Their open pull requests, drafts included, appear on the bench beside your machines' reviews and refresh from GitHub events.

GitHub pull requests

Settings
GitHub
  1. Connect your GitHub account
    Lets diffx check which repositories you can read.
    Connect GitHub
    Connected as @maya. Pull requests of followed repositories update from GitHub events.
  2. Follow repositories
    acme/api
    acme/web
    acme/docs
Needs attention
#482Add retry backoff@maya
#479Cap upload size@lee
#91Fix nav overflow@sam

Comment on the lines that need work

Comment on any line or file. Comments and reviewed marks carry across new snapshots, re-anchor to code that moved, and copy out as agent-ready XML.

Comments and reviewed marks

TSsrc/retry.ts+8−1Reviewed
@@ -5,7 +5,14 @@ const baseDelay = 250;
5export async function retry<T>(task: () => Promise<T>, attempts = 6) {
6 return task();
6 for (let attempt = 0; ; attempt++) {
7 try {
8 return await task();
9 } catch (error) {
10 if (attempt + 1 >= attempts) throw error;
11 await sleep(baseDelay * 2 ** attempt);
New commentsrc/retry.ts:11
Line 11· You
⌘Enter to commentCancelComment
ReplyResolve
12 }
13 }
14}
15
16export function isRetryable(status: number) {
17 return status === 429 || status >= 500;
18}
19
20export function backoff(attempt: number) {
21 return baseDelay * 2 ** attempt;
22}

Let agents address the feedback

Connect Claude Code, Codex, Cursor or OpenCode to diffx over MCP. The agent finds the open threads, fixes each concern, replies with what changed and resolves it. The review shows every reply as it lands.

MCP

claude · ~/acme/api
>
⏺diffx · find_feedback (MCP)⎿1 open thread · src/retry.ts:11
⏺Update(src/retry.ts)⎿+2 −1
⏺diffx · reply_to_review_comment (MCP)
⏺diffx · resolve_review_comment (MCP)⎿Resolved
⏺Capped the delay at 5 seconds and added jitter. The thread is resolved.
src/retry.ts
11 await sleep(baseDelay * 2 ** attempt);
Line 11· YouOpen
Cap this delay at 5 seconds and add jitter.
Claude Code· now
Capped the delay at 5 seconds and added jitter.
Resolved by Claude Code · now

Guides