prreviewbuddy 0.45.0 → 0.46.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +41 -0
- package/dist/{delete_review-BWMmO81Q.js → delete_review-lmVdoybL.js} +25 -1
- package/dist/main.js +1 -1
- package/dist/server.js +744 -31
- package/package.json +1 -1
- package/static/shell.css +344 -5
- package/static/workspace.js +77 -36
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,46 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.46.0
|
|
4
|
+
|
|
5
|
+
**The change map: see what a change is about, and how its parts affect each other.** The Diagrams
|
|
6
|
+
page now opens on a **Change map**, drawn from the review's own themes. It reads from the goal of
|
|
7
|
+
the change, through what it does and the state it shares, to the rules it must keep, the risks, and
|
|
8
|
+
what the person using it gets. Every arrow says what it means, such as *adds another writer* or
|
|
9
|
+
*protects every change*, rather than just joining two boxes. Each idea says why it matters, names the
|
|
10
|
+
code to search for, and links to its theme in the review path. The ideas that matter most have a
|
|
11
|
+
heavier frame and are marked **Core idea**. Click an idea to highlight what it connects to, or open
|
|
12
|
+
**Read as a list** to read every relationship as a sentence.
|
|
13
|
+
|
|
14
|
+
**Simple or Technical.** A switch on the map changes its wording between everyday language and the
|
|
15
|
+
precise terms, without changing what is connected to what, and without asking Buddy AI again. Your
|
|
16
|
+
choice is remembered. If you have already asked Buddy AI to **Explain in simple terms**, the map's
|
|
17
|
+
Simple wording keeps the same analogy.
|
|
18
|
+
|
|
19
|
+
**Change map and Implementation, side by side.** The Diagrams page has two tabs. **Change map**
|
|
20
|
+
explains the change. **Implementation** is the diagram of how the code does it, which works as it
|
|
21
|
+
did before. A small check on each tab shows whether it has already been generated. Diagrams is now
|
|
22
|
+
always in the review's sidebar, and the Overview has a **Diagrams** button beside **Explain in simple
|
|
23
|
+
terms**.
|
|
24
|
+
|
|
25
|
+
**Nothing is generated until you ask.** Opening Diagrams, or either tab, never starts Buddy AI. Only a
|
|
26
|
+
button that says **Generate** or **Regenerate** does, and while one is running you see its progress
|
|
27
|
+
and **Stop**. Reviews made before this version open on a short description of the map and a
|
|
28
|
+
**Generate change map** button.
|
|
29
|
+
|
|
30
|
+
**A change map always matches the review beside it.** Running the analysis again, or updating the
|
|
31
|
+
review to newer commits, removes the map, because it was built from the analysis that was replaced.
|
|
32
|
+
Generate a new one to map the review as it is now. Implementation diagrams are kept as before and say
|
|
33
|
+
when they were drawn from an earlier commit.
|
|
34
|
+
|
|
35
|
+
**Every page of a review can be expanded.** The expand button now also appears on the Overview,
|
|
36
|
+
Diagrams, PR context, both KISS review pages and the progress page shown while a review is running,
|
|
37
|
+
as well as Buddy AI, Issues, Questions, Files and the review path. Diagrams and Files get much more
|
|
38
|
+
of the window, and an expanded change map shows its stages side by side; the others stay at a
|
|
39
|
+
comfortable reading width.
|
|
40
|
+
|
|
41
|
+
**Folding Your prompts now hides them.** Clicking **Your prompts** turned its arrow and saved your
|
|
42
|
+
choice, but the prompts stayed on screen. They now fold away as intended.
|
|
43
|
+
|
|
3
44
|
## 0.45.0
|
|
4
45
|
|
|
5
46
|
**Expand a pane to fill the review page.** Buddy AI, Issues, Questions, Files and the review path
|
|
@@ -4644,6 +4644,28 @@ function reviewedCommit(workspace) {
|
|
|
4644
4644
|
return workspace.session.metadata?.commitSha || workspace.changeSet.data.pullRequest.head.sha || null;
|
|
4645
4645
|
}
|
|
4646
4646
|
/**
|
|
4647
|
+
* Forget what was built from the analysis, because the analysis is being replaced.
|
|
4648
|
+
*
|
|
4649
|
+
* Only the change map. It is made from the review's own themes, so one kept beside a different set
|
|
4650
|
+
* of themes would contradict the guide it sits next to. Diagrams describe code and carry their
|
|
4651
|
+
* commit, so they stay and say they are dated; see `diagrams`.
|
|
4652
|
+
*/
|
|
4653
|
+
function dropDerivedFromAnalysis(workspace) {
|
|
4654
|
+
delete workspace.changeMap;
|
|
4655
|
+
}
|
|
4656
|
+
/**
|
|
4657
|
+
* The same, for a review that has just moved to a different commit.
|
|
4658
|
+
*
|
|
4659
|
+
* Said by commit rather than by "an update happened", so an update that found nothing new keeps
|
|
4660
|
+
* the map, and a map drawn from the old analysis while the update was running goes with the rest.
|
|
4661
|
+
*/
|
|
4662
|
+
function dropStaleChangeMap(workspace) {
|
|
4663
|
+
const drawnFrom = workspace.changeMap?.commitSha;
|
|
4664
|
+
if (!drawnFrom) return;
|
|
4665
|
+
const reviewed = reviewedCommit(workspace);
|
|
4666
|
+
if (reviewed && drawnFrom !== reviewed) dropDerivedFromAnalysis(workspace);
|
|
4667
|
+
}
|
|
4668
|
+
/**
|
|
4647
4669
|
* The KISS run the page presents, or null when nobody has run one.
|
|
4648
4670
|
*
|
|
4649
4671
|
* Reads the recorded pointer rather than the end of the list, so a failed rerun does not become
|
|
@@ -10547,6 +10569,7 @@ async function reanalyseReview(workspaceId, agentId, onStarted, requestedModel)
|
|
|
10547
10569
|
saveJob(job);
|
|
10548
10570
|
workspace.jobId = job.id;
|
|
10549
10571
|
workspace.session = beginReviewSession(sha, agent, void 0, model ?? void 0);
|
|
10572
|
+
dropDerivedFromAnalysis(workspace);
|
|
10550
10573
|
saveWorkspace(workspace);
|
|
10551
10574
|
return job;
|
|
10552
10575
|
});
|
|
@@ -12199,6 +12222,7 @@ function mergeUpdateInto(fresh, updated) {
|
|
|
12199
12222
|
for (const field of REVIEWER_SESSION_FIELDS) if (field in fresh.session) session[field] = current[field];
|
|
12200
12223
|
else delete session[field];
|
|
12201
12224
|
merged.session = session;
|
|
12225
|
+
dropStaleChangeMap(merged);
|
|
12202
12226
|
return merged;
|
|
12203
12227
|
}
|
|
12204
12228
|
/**
|
|
@@ -12627,4 +12651,4 @@ function lineageIds(id) {
|
|
|
12627
12651
|
return [.../* @__PURE__ */ new Set([id, ...lineage.map((review) => review.id)])];
|
|
12628
12652
|
}
|
|
12629
12653
|
//#endregion
|
|
12630
|
-
export {
|
|
12654
|
+
export { queueForReview as $, positionInLineage as $t, createPrState as A, writeAgentPreference as An, allJobs as At, toneOf as B, purposeOf as Bt, readEvents as C, displayRef as Cn, forgeFor as Ct, announceJob as D, resolveModel as Dn, checkReview as Dt, telemetryUploadConsent as E, resolveAgent as En, checkCodeFreshness as Et, markAllRead as F, agentById as Fn, saveJob as Ft, extractJsonText as G, groupByLineage as Gt, withUsageRecorded as H, driverGone as Ht, markRead as I, agentFor as In, PHASES as It, readMarker as J, lineageKeyFor as Jt, ReviewBeingDeletedError as K, indexReviewGroups as Kt, pruneNotifications as L, detectAgents as Ln, isLiveJob as Lt, eventName as M, STORE_ROOT as Mn, fail as Mt, headline as N, AGENT_IDS as Nn, isTerminal as Nt, branchOf as O, clearAgentPreference as On, followedBranch as Ot, listNotifications as P, DEFAULT_AGENT_ID as Pn, loadJob as Pt, compactQueue as Q, mutateWorkspace as Qt, readNotification as R, AgentCancelledError as Rn, phasesFor as Rt, startJob as S, resolveTarget as Sn, forgeResolver as St, recordTelemetryUploadConsent as T, git as Tn, fillFileUrlTemplate as Tt, EXPLAIN_SIMPLY_PROMPT as U, isClaimed as Ut, unreadCount as V, clearClaim as Vt, asString as W, followedRefName as Wt, modelHelpLines as X, loadWorkspace as Xt, removeWorktree as Y, lineagePosition as Yt, relativeTime as Z, matchingWorkspaceIds as Zt, agentEnvOf as _, issuesOutstanding as _n, parseWorkspacePort as _t, wasBlocked as a, touchWorkspace as an, reviewsUrl as at, reanalyseReview as b, processDiscussion as bn, writePortPreference as bt, RefreshUnavailableError as c, dequeueOnComplete as cn, stopServer as ct, refreshPrContext as d, queueRemove as dn, BUILD_VERSION as dt, previousKissResult as en, readIndexToken as et, isUnchanged as f, queueStamp as fn, PACKAGE_NAME as ft, runningJobs as g, isQuestionOutstanding as gn, MIN_WORKSPACE_PORT as gt, liveUpdateFor as h, isIssueOutstanding as hn, MAX_WORKSPACE_PORT as ht, liveJobsFor as i, summarise as in, readServerRecord as it, createPrUpdate as j, CONFIG_PATH as jn, endedAt as jt, subjectOf as k, readAgentPreference as kn, reviewedShaOf as kt, mergeUpdateInto as l, queueAdd as ln, workspaceUrl as lt, UpdateAlreadyRunningError as m, doneVerb as mn, DEFAULT_WORKSPACE_PORT as mt, deleteReview as n, reviewedCommit as nn, clearServerRecord as nt, discardJob as o, workspaceRevision as on, serverEntryExists as ot, askCheckout as p, readQueue as pn, feedbackUrl as pt, MANAGED_ROOT as q, latestKissRun as qt, lineageIds as r, reviewedRepositories as rn, ensureServer as rt, FETCH_TIMEOUT_MS as s, workspaceStamps as sn, spawnServer as st, deleteLineage as t, recentWorkspaces as tn, bootstrapUrl as tt, updateReview as u, queueAddMany as un, writeServerRecord as ut, recordKissRun as v, questionsOutstanding as vn, resolveWorkspacePort as vt, record as w, isCommitReview as wn, remoteHost as wt, runJob as x, describeAuthorship as xn, claimRequestUrl as xt, startKissJob as y, reviewerDispositions as yn, statedWorkspacePort as yt, removeNotification as z, AgentUnavailableError as zn, progressSteps as zt };
|
package/dist/main.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as queueForReview, $t as positionInLineage, An as writeAgentPreference, At as allJobs, Bt as purposeOf, Cn as displayRef, Dn as resolveModel, Dt as checkReview, E as telemetryUploadConsent, En as resolveAgent, Fn as agentById, Gt as groupByLineage, Ht as driverGone, It as PHASES, J as readMarker, Jt as lineageKeyFor, Ln as detectAgents, Mn as STORE_ROOT, Nn as AGENT_IDS, Nt as isTerminal, Pn as DEFAULT_AGENT_ID, Pt as loadJob, Qt as mutateWorkspace, S as startJob, Sn as resolveTarget, St as forgeResolver, T as recordTelemetryUploadConsent, Tn as git, Ut as isClaimed, Vt as clearClaim, Wt as followedRefName, X as modelHelpLines, Xt as loadWorkspace, Y as removeWorktree, Z as relativeTime, Zt as matchingWorkspaceIds, _t as parseWorkspacePort, a as wasBlocked, at as reviewsUrl, b as reanalyseReview, bt as writePortPreference, ct as stopServer, dt as BUILD_VERSION, et as readIndexToken, ft as PACKAGE_NAME, g as runningJobs, gt as MIN_WORKSPACE_PORT, h as liveUpdateFor, ht as MAX_WORKSPACE_PORT, i as liveJobsFor, in as summarise, jn as CONFIG_PATH, kn as readAgentPreference, l as mergeUpdateInto, lt as workspaceUrl, m as UpdateAlreadyRunningError, mt as DEFAULT_WORKSPACE_PORT, n as deleteReview$1, q as MANAGED_ROOT, rn as reviewedRepositories, rt as ensureServer, tn as recentWorkspaces, tt as bootstrapUrl, u as updateReview, v as recordKissRun, w as record$1, x as runJob, yt as statedWorkspacePort, zt as progressSteps } from "./delete_review-lmVdoybL.js";
|
|
3
3
|
import { basename, dirname, join, resolve } from "node:path";
|
|
4
4
|
import { spawn } from "node:child_process";
|
|
5
5
|
import { existsSync, mkdirSync, readdirSync, realpathSync, rmSync, statSync, writeFileSync } from "node:fs";
|