@dev.fast/whiteboard 0.5.1 → 0.5.2-preview.20261104.147
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/dist/{account-alias-Bw3PT3Qo.js → account-alias-DXpd0Px8.js} +5 -5
- package/dist/{agent-cli-kHRrwO4n.js → agent-cli-COrZtFks.js} +9 -9
- package/dist/agent-cli-x6-Eh1S-.js +2 -0
- package/dist/{agent-client-CMacGbMp.js → agent-client-BFtYm3Ng.js} +4 -4
- package/dist/{authoring-tools-CiLy46kh.js → authoring-tools-D1avYp8-.js} +12 -8
- package/dist/{background-server-eZWXoVcI.js → background-server-BiRSqjxG.js} +4 -4
- package/dist/{background-server-BLNHbksB.js → background-server-HOJozY99.js} +1 -1
- package/dist/build-info.json +1 -1
- package/dist/{cli-Bxmiqutp.js → cli-CSlwGRvH.js} +1 -1
- package/dist/{cli-runner-DQPuu7kJ.js → cli-runner-CuffXA0Q.js} +22 -22
- package/dist/cli.js +2 -2
- package/dist/{fuzzy-match-DZjeOaPY.js → fuzzy-match-DEo941za.js} +3 -3
- package/dist/{headless-host-B4r0s1ks.js → headless-host-BCkXVVpU.js} +1 -1
- package/dist/{headless-host-Dl2KZ9IT.js → headless-host-CIuJJjmM.js} +561 -415
- package/dist/{import-YAIU6rB0.js → import-CjcW7EIQ.js} +235 -63
- package/dist/{local-data-C58vzLZR.js → local-data-B5PBZ0Ge.js} +101 -17
- package/dist/{mcp-COYWiGVn.js → mcp-Ba3WvhUh.js} +9 -6
- package/dist/{package-paths-Cg6fnaGp.js → package-paths-Dk7MOXxN.js} +1 -1
- package/dist/profile-BstQkIY0.js +2 -0
- package/dist/{profile--BYIjPkc.js → profile-CNMhLUhf.js} +2 -2
- package/dist/{remote-attach-C1prLjmj.js → remote-attach-DkZoYBHV.js} +4 -4
- package/dist/{remote-extensions-Bw029iIS.js → remote-extensions-BvV29_gk.js} +1 -1
- package/dist/{remote-extensions-MUUgbLJn.js → remote-extensions-L95HNwIH.js} +2 -2
- package/dist/{remote-language-server-z3rdHcLL.js → remote-language-server-l4ConTfj.js} +4 -4
- package/dist/{remote-uninstall-B3Slwor1.js → remote-uninstall-BAQM7cU8.js} +5 -5
- package/dist/{request-origin-B3_XI2VA.js → request-origin-DZexKlc4.js} +28 -5
- package/dist/{review-app-launcher-BZEbDKuK.js → review-app-launcher-B5F10y_4.js} +2 -2
- package/dist/{review-home-paths-LdGS4SpR.js → review-home-paths-BmZX2qiz.js} +1 -1
- package/dist/{review-telemetry-x8u-9EZb.js → review-telemetry-kQ7esDRE.js} +4 -4
- package/dist/server/desktop-host.js +26 -38
- package/dist/{server-discovery-WmuFl2S3.js → server-discovery-DYY_xeG9.js} +2 -2
- package/dist/sharing/index.d.ts +137 -14
- package/dist/sharing/index.js +1 -1
- package/dist/{src-DLWol7GZ.js → src-B-91Rd2d.js} +17 -1
- package/dist/{src-B2b8cCoI.js → src-DirPN_Qh.js} +82 -6
- package/dist/{stored-document-migration-iwIQ4l5G.js → stored-document-migration-vg0NAzXG.js} +4 -89
- package/dist/{thread-state-B7L1mpN_.js → thread-state-Jxoh1hde.js} +1 -1
- package/dist/{tool-failure-RLR8m9hq.js → tool-failure-BLBwcl3H.js} +319 -55
- package/instructions/animation.md +69 -5
- package/instructions/animations/before-after-structure/README.md +27 -0
- package/instructions/animations/before-after-structure/animation.html +89 -0
- package/instructions/animations/before-after-structure/block.json +10 -0
- package/instructions/animations/before-after-structure/frames.json +313 -0
- package/instructions/animations/cache-fill-evict/README.md +24 -0
- package/instructions/animations/cache-fill-evict/animation.html +81 -0
- package/instructions/animations/cache-fill-evict/block.json +13 -0
- package/instructions/animations/cache-fill-evict/frames.json +79 -0
- package/instructions/animations/cache-fill-evict/scenarios.json +17 -0
- package/instructions/animations/log-replay/README.md +25 -0
- package/instructions/animations/log-replay/animation.html +86 -0
- package/instructions/animations/log-replay/block.json +10 -0
- package/instructions/animations/log-replay/frames.json +143 -0
- package/instructions/animations/log-replay/scenarios.json +18 -0
- package/instructions/animations/queue-workers/README.md +23 -0
- package/instructions/animations/queue-workers/animation.html +107 -0
- package/instructions/animations/queue-workers/block.json +13 -0
- package/instructions/animations/queue-workers/frames.json +119 -0
- package/instructions/animations/queue-workers/scenarios.json +18 -0
- package/instructions/animations/race-two-lanes/README.md +22 -0
- package/instructions/animations/race-two-lanes/animation.html +97 -0
- package/instructions/animations/race-two-lanes/block.json +1 -0
- package/instructions/animations/race-two-lanes/frames.json +234 -0
- package/instructions/animations/race-two-lanes/scenarios.json +19 -0
- package/instructions/animations/request-across-layers/README.md +24 -0
- package/instructions/animations/request-across-layers/animation.html +85 -0
- package/instructions/animations/request-across-layers/block.json +17 -0
- package/instructions/animations/request-across-layers/frames.json +58 -0
- package/instructions/animations/request-across-layers/scenarios.json +12 -0
- package/instructions/animations/request-timing/README.md +22 -0
- package/instructions/animations/request-timing/animation.html +120 -0
- package/instructions/animations/request-timing/block.json +21 -0
- package/instructions/animations/request-timing/markers.json +32 -0
- package/instructions/animations/request-timing/scenarios.json +4 -0
- package/instructions/animations/retry-backoff/README.md +22 -0
- package/instructions/animations/retry-backoff/animation.html +122 -0
- package/instructions/animations/retry-backoff/block.json +10 -0
- package/instructions/animations/retry-backoff/frames.json +65 -0
- package/instructions/animations/retry-backoff/scenarios.json +12 -0
- package/instructions/animations/state-machine/README.md +24 -0
- package/instructions/animations/state-machine/animation.html +95 -0
- package/instructions/animations/state-machine/block.json +9 -0
- package/instructions/animations/state-machine/frames.json +79 -0
- package/instructions/animations/state-machine/scenarios.json +12 -0
- package/instructions/animations/video-platform-architecture/README.md +24 -0
- package/instructions/animations/video-platform-architecture/animation.html +76 -0
- package/instructions/animations/video-platform-architecture/block.json +17 -0
- package/instructions/animations/video-platform-architecture/frames.json +97 -0
- package/instructions/animations/video-platform-architecture/scenarios.json +28 -0
- package/instructions/whiteboard.d.ts +168 -14
- package/package.json +5 -5
- package/src/animation-stage-kit.ts +150 -10
- package/src/cli-runner.ts +4 -1
- package/src/fixtures/blocks/clip.json +19 -0
- package/src/review-api/README.md +1 -0
- package/src/review-api/agent-cli.ts +3 -2
- package/src/review-api/animation-drafts.ts +151 -47
- package/src/review-api/animation-references.ts +92 -0
- package/src/review-api/animation-render.ts +106 -0
- package/src/review-api/authoring-tools.ts +10 -3
- package/src/review-api/comparison-coverage.ts +6 -7
- package/src/review-api/document-text.ts +27 -12
- package/src/review-api/http.ts +52 -6
- package/src/review-api/instructions.ts +1 -1
- package/src/review-api/mcp.ts +10 -5
- package/src/review-api/public-tools.ts +71 -2
- package/src/review-api/review-progress.ts +2 -3
- package/src/review-api/store.ts +89 -12
- package/src/server/desktop-server.ts +17 -5
- package/src/server/headless-host.ts +4 -0
- package/src/server/review-gateway.ts +1 -0
- package/src/server/review-server-core.ts +71 -12
- package/src/sharing/client.ts +129 -32
- package/src/sharing/export.ts +42 -5
- package/src/sharing/file.ts +8 -0
- package/src/sharing/host.ts +202 -73
- package/src/sharing/import.ts +125 -33
- package/src/ui-telemetry-events.ts +26 -1
- package/dist/agent-cli-B8KBHuh_.js +0 -2
- package/dist/profile-BjcXi-oH.js +0 -2
- package/src/review-api/lens-alignment.ts +0 -52
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { S as splitGitPatchFiles, T as runVcsSync, _ as listTrackedFilesAtCommit, a as diff, b as resolveRepoContext, c as diffFileSummariesWorkingTree, d as git, f as gitAt, g as listCommitRange, h as jjRevisionIsConflicted, i as detectLocalVcs, l as diffTrees, m as gitCommonDirSync, n as createBlobBatchReader, p as gitCommonDir, s as diffFileSummariesTrees, t as LocalVcsToolsMissingError, u as diffWorkingTree, v as parseGitRemote, w as runVcs, x as resolveRevision, y as readFileAtCommit } from "./src-Y30gweiK.js";
|
|
2
2
|
import { c as jsonString, m as isStringValue, n as isJsonObject, o as jsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
|
|
3
|
-
import { A as parseMarkdown, B as lensSchema, D as summarizeEdit, E as sourceReferences, G as SourceRangeError, J as requireVisibleSource, K as checkSourcePath, M as checkReferences, O as markdownNodes, P as documentAdvice, R as applyLensEdit, S as respellEditLinks, V as lensSelections, Y as sliceSourceRange, a as boardLinks, at as
|
|
4
|
-
import {
|
|
5
|
-
import { s as safeStorageSegment } from "./review-home-paths-
|
|
6
|
-
import {
|
|
3
|
+
import { A as parseMarkdown, B as lensSchema, D as summarizeEdit, E as sourceReferences, G as SourceRangeError, J as requireVisibleSource, K as checkSourcePath, M as checkReferences, O as markdownNodes, P as documentAdvice, R as applyLensEdit, S as respellEditLinks, V as lensSelections, Y as sliceSourceRange, a as boardLinks, at as sourceAnchors, b as respellCommitLinks, c as documentSchema, ct as activityBeginSchema, d as explicitPins, dt as focusSchema, h as pinsSchema, i as assignMissingIds, k as markdownText, l as editSchema, lt as activityEndSchema, m as pinnedRepositoryIds, n as anchorPins, nt as patchRows, o as boardRepositoryId, ot as unionIntervals, p as pinDocumentReferences, q as fileLineRangeSchema, r as applyEdit, s as commitLinkCommits, st as ReviewInputError, t as adoptFlowUnits, tt as parseAnchor, u as elements, ut as activityUpdateSchema, v as resourceReference, w as reviewTargetSchema, x as respellDocumentLinks, y as resourceReferences, z as lensEditSchema } from "./src-DirPN_Qh.js";
|
|
4
|
+
import { I as applyStructuralUpdate, L as decodeStructuralDiffEvent, R as structuralChangeCounts, c as boardIconKind, l as boardTitle } from "./src-B-91Rd2d.js";
|
|
5
|
+
import { s as safeStorageSegment } from "./review-home-paths-BmZX2qiz.js";
|
|
6
|
+
import { C as emptyCoverage, D as subtractIntervals, O as updateCoverage, _ as fetchPullRequest, a as SoftwareModelValidationError, b as textIncludesQuote, c as traceSchema, d as setPullRequest, f as sourceBranchName, g as defaultPullRequestDeps, h as GitHubRefusedRead, i as readStoredDocument, l as pullRequestKey, m as resolvePullRequest, n as migrateStoredDocument, o as defineSoftwareMap, r as migrateStoredLenses, u as pullRequestUrl, v as remoteUrls, w as intersectIntervals, x as coverageSchema, y as azureRepositoryOf } from "./stored-document-migration-vg0NAzXG.js";
|
|
7
7
|
import { A as processStartIdentity, L as writePrivateJsonAtomic, O as pidReused, j as withFileLock, k as processIsAlive } from "./s3-config-CjcLyFV5.js";
|
|
8
8
|
import { t as errorMessage } from "./error-message-OtiDonty.js";
|
|
9
|
-
import { a as askHistoryEntrySchema, i as askEntrySchema, m as isMissingFileError, o as askOfferSchema, s as askPermissionsSchema } from "./thread-state-
|
|
9
|
+
import { a as askHistoryEntrySchema, i as askEntrySchema, m as isMissingFileError, o as askOfferSchema, s as askPermissionsSchema } from "./thread-state-Jxoh1hde.js";
|
|
10
10
|
import { createRequire } from "node:module";
|
|
11
11
|
import crypto, { createHash, randomUUID } from "node:crypto";
|
|
12
12
|
import { z } from "zod";
|
|
@@ -1007,6 +1007,65 @@ var Comparison = class {
|
|
|
1007
1007
|
}
|
|
1008
1008
|
};
|
|
1009
1009
|
//#endregion
|
|
1010
|
+
//#region src/unified-diff.ts
|
|
1011
|
+
const HUNK_HEADER = /^@@ -(?<oldStart>\d+)(?:,(?<oldLines>\d+))? \+(?<newStart>\d+)(?:,(?<newLines>\d+))? @@/;
|
|
1012
|
+
function parseUnifiedPatch(file, patch) {
|
|
1013
|
+
if (!patch) return [];
|
|
1014
|
+
const hunks = [];
|
|
1015
|
+
let current = null;
|
|
1016
|
+
let oldLine = 0;
|
|
1017
|
+
let newLine = 0;
|
|
1018
|
+
for (const row of patch.split(/\r?\n/)) {
|
|
1019
|
+
const header = HUNK_HEADER.exec(row);
|
|
1020
|
+
if (header?.groups) {
|
|
1021
|
+
current = {
|
|
1022
|
+
file,
|
|
1023
|
+
oldStart: Number(header.groups.oldStart),
|
|
1024
|
+
oldLines: Number(header.groups.oldLines ?? "1"),
|
|
1025
|
+
newStart: Number(header.groups.newStart),
|
|
1026
|
+
newLines: Number(header.groups.newLines ?? "1"),
|
|
1027
|
+
lines: []
|
|
1028
|
+
};
|
|
1029
|
+
oldLine = current.oldStart;
|
|
1030
|
+
newLine = current.newStart;
|
|
1031
|
+
hunks.push(current);
|
|
1032
|
+
continue;
|
|
1033
|
+
}
|
|
1034
|
+
if (!current || row.startsWith("\")) continue;
|
|
1035
|
+
const marker = row[0];
|
|
1036
|
+
const text = row.slice(1);
|
|
1037
|
+
let line = null;
|
|
1038
|
+
if (marker === " ") {
|
|
1039
|
+
line = {
|
|
1040
|
+
kind: "context",
|
|
1041
|
+
oldLine,
|
|
1042
|
+
newLine,
|
|
1043
|
+
text
|
|
1044
|
+
};
|
|
1045
|
+
oldLine += 1;
|
|
1046
|
+
newLine += 1;
|
|
1047
|
+
} else if (marker === "+") {
|
|
1048
|
+
line = {
|
|
1049
|
+
kind: "add",
|
|
1050
|
+
oldLine: null,
|
|
1051
|
+
newLine,
|
|
1052
|
+
text
|
|
1053
|
+
};
|
|
1054
|
+
newLine += 1;
|
|
1055
|
+
} else if (marker === "-") {
|
|
1056
|
+
line = {
|
|
1057
|
+
kind: "remove",
|
|
1058
|
+
oldLine,
|
|
1059
|
+
newLine: null,
|
|
1060
|
+
text
|
|
1061
|
+
};
|
|
1062
|
+
oldLine += 1;
|
|
1063
|
+
}
|
|
1064
|
+
if (line) current.lines.push(line);
|
|
1065
|
+
}
|
|
1066
|
+
return hunks;
|
|
1067
|
+
}
|
|
1068
|
+
//#endregion
|
|
1010
1069
|
//#region src/software-map-diff-counts.ts
|
|
1011
1070
|
async function resolveSoftwareMapDiffCounts(input) {
|
|
1012
1071
|
const baseRef = input.baseRef?.trim();
|
|
@@ -1299,7 +1358,7 @@ async function comparisonCoverage(data, reviewId, pins, signal, publish) {
|
|
|
1299
1358
|
changed.base = unionIntervals(changed.base);
|
|
1300
1359
|
changed.head = unionIntervals(changed.head);
|
|
1301
1360
|
const [base, head] = await Promise.all([file.status === "added" ? null : data.file(pins, "base", file.previousPath ?? file.path).then((value) => value.text).catch(() => null), file.status === "deleted" ? null : data.file(pins, "head", file.path).then((value) => value.text).catch(() => null)]);
|
|
1302
|
-
alignments.set(file.path,
|
|
1361
|
+
alignments.set(file.path, patchRows(patch, base === null ? 0 : base.split("\n").length, head === null ? 0 : head.split("\n").length));
|
|
1303
1362
|
const readable = (file.status === "added" || base !== null) && (file.status === "deleted" || head !== null);
|
|
1304
1363
|
const fingerprint = hash([
|
|
1305
1364
|
pins.repositoryId,
|
|
@@ -3095,11 +3154,16 @@ var ReviewStore = class {
|
|
|
3095
3154
|
this.pending = run.catch(() => {});
|
|
3096
3155
|
return run;
|
|
3097
3156
|
}
|
|
3098
|
-
/** The
|
|
3099
|
-
|
|
3100
|
-
|
|
3101
|
-
|
|
3102
|
-
|
|
3157
|
+
/** The boards copied from a share link, newest first, until each is deleted. */
|
|
3158
|
+
copiesOf(key) {
|
|
3159
|
+
return this.db.prepare(`SELECT reviews.id, reviews.version, json_extract(versions.snapshot,'$.shared') AS shared
|
|
3160
|
+
FROM reviews JOIN versions ON versions.review_id=reviews.id AND versions.version=reviews.version
|
|
3161
|
+
WHERE CASE WHEN json_valid(versions.snapshot) THEN json_extract(versions.snapshot,'$.shared.key') END=?
|
|
3162
|
+
ORDER BY reviews.rowid DESC`).all(key).map((row) => ({
|
|
3163
|
+
reviewId: String(row.id),
|
|
3164
|
+
version: Number(row.version),
|
|
3165
|
+
shared: JSON.parse(String(row.shared))
|
|
3166
|
+
}));
|
|
3103
3167
|
}
|
|
3104
3168
|
/** Checkouts whose remote is cloneUrl, most recently used first. */
|
|
3105
3169
|
checkoutsOf(cloneUrl) {
|
|
@@ -3361,6 +3425,21 @@ var ReviewStore = class {
|
|
|
3361
3425
|
pullRequest?.catch(() => {});
|
|
3362
3426
|
const pullRequestTitle = pullRequest ? pullRequest.then(({ title }) => title || void 0, () => void 0) : this.startPullRequestTitle(command);
|
|
3363
3427
|
const prepared = this.prepareCommand(command, pullRequest, pullRequestTitle, author).then((source) => this.applyPreparedCommand(source, initial, author));
|
|
3428
|
+
return this.track(prepared);
|
|
3429
|
+
}
|
|
3430
|
+
/** Replaces a share copy's content under the same board id; 409 once it moved past `baseVersion`. */
|
|
3431
|
+
refreshCopy(reviewId, baseVersion, create, seed) {
|
|
3432
|
+
if (this.closing) return Promise.reject(/* @__PURE__ */ new Error("Review store is closing."));
|
|
3433
|
+
const command = commandSchema.parse(create);
|
|
3434
|
+
const op = command.operation;
|
|
3435
|
+
if (op.type !== "create" || op.pullRequestUrl || op.parentId || op.dependsOn || op.projectId) throw new ReviewInputError("A refresh takes a create command with a title and target alone.");
|
|
3436
|
+
const person = { kind: "person" };
|
|
3437
|
+
return this.track(this.prepareCommand(command, void 0, Promise.resolve(void 0), person).then((source) => this.applyPreparedCommand(source, seed, person, {
|
|
3438
|
+
reviewId,
|
|
3439
|
+
baseVersion
|
|
3440
|
+
})));
|
|
3441
|
+
}
|
|
3442
|
+
track(prepared) {
|
|
3364
3443
|
this.preparing.add(prepared);
|
|
3365
3444
|
prepared.finally(() => this.preparing.delete(prepared)).catch(() => {});
|
|
3366
3445
|
return prepared;
|
|
@@ -3389,10 +3468,10 @@ var ReviewStore = class {
|
|
|
3389
3468
|
resolvedTitle: await pullRequestTitle
|
|
3390
3469
|
};
|
|
3391
3470
|
}
|
|
3392
|
-
applyPreparedCommand(prepared, initial, author) {
|
|
3471
|
+
applyPreparedCommand(prepared, initial, author, into) {
|
|
3393
3472
|
const { op, requestedTarget, fromPullRequest, resolvedTarget, resolvedBranch, discoveredPullRequest, resolvedTitle } = prepared;
|
|
3394
3473
|
return this.enqueue(async () => {
|
|
3395
|
-
if (op.type === "create" && (op.pullRequestUrl ? op.reuseExisting !== false : op.reuseExisting && resolvedTarget?.pins)) {
|
|
3474
|
+
if (!into && op.type === "create" && (op.pullRequestUrl ? op.reuseExisting !== false : op.reuseExisting && resolvedTarget?.pins)) {
|
|
3396
3475
|
const known = op.pullRequestUrl ? this.reviewsForPullRequest(op.pullRequestUrl) : [];
|
|
3397
3476
|
const branch = fromPullRequest?.branch ?? resolvedBranch;
|
|
3398
3477
|
const repository = resolvedTarget?.target.repositoryId;
|
|
@@ -3410,8 +3489,9 @@ var ReviewStore = class {
|
|
|
3410
3489
|
if (op.type === "lifecycle") return this.commitBoardFacts(op.reviewId, author, { state: op.state });
|
|
3411
3490
|
if (op.type === "attention") return this.commitBoardFacts(op.reviewId, author, { viewed: true });
|
|
3412
3491
|
if (op.type === "delete") return this.deleteBoard(this.read(op.reviewId), author, { fromTrash: true });
|
|
3413
|
-
const id = op.type === "create" ? randomUUID() : op.reviewId;
|
|
3414
|
-
const previous = op.type === "create" ? void 0 : this.read(id);
|
|
3492
|
+
const id = into?.reviewId ?? (op.type === "create" ? randomUUID() : op.reviewId);
|
|
3493
|
+
const previous = op.type === "create" && !into ? void 0 : this.read(id);
|
|
3494
|
+
if (into && (!previous?.shared?.key || previous.shared.key !== initial?.shared?.key)) throw new ReviewInputError("Only a copy of the same share link refreshes in place.");
|
|
3415
3495
|
let snapshot = op.type === "create" ? createdSnapshot(id, op, resolvedTarget, fromPullRequest && (fromPullRequest.title || `PR #${op.pullRequestUrl.split("/").at(-1)}`), author.kind === "person") : structuredClone(previous);
|
|
3416
3496
|
delete snapshot.trashedAt;
|
|
3417
3497
|
delete snapshot.sourceUnavailable;
|
|
@@ -3520,9 +3600,11 @@ var ReviewStore = class {
|
|
|
3520
3600
|
restore: op.type === "restore",
|
|
3521
3601
|
repin: op.type === "set_target",
|
|
3522
3602
|
copied: initial !== void 0,
|
|
3603
|
+
inPlace: into !== void 0,
|
|
3604
|
+
baseVersion: into?.baseVersion,
|
|
3523
3605
|
projectLive: op.type !== "restore" && !resolvedTarget,
|
|
3524
3606
|
result: {
|
|
3525
|
-
...op.type === "create" && { created: true },
|
|
3607
|
+
...op.type === "create" && !into && { created: true },
|
|
3526
3608
|
targetId: applied?.targetId ?? lensTarget?.targetId,
|
|
3527
3609
|
...applied && { type: applied.type },
|
|
3528
3610
|
...lensTarget && { type: lensTarget.type },
|
|
@@ -3590,6 +3672,7 @@ var ReviewStore = class {
|
|
|
3590
3672
|
person: author.kind === "person"
|
|
3591
3673
|
}));
|
|
3592
3674
|
warnings = [...change.warnings ?? [], ...warnings];
|
|
3675
|
+
if (change.copied && snapshot.shared) snapshot.shared.importedVersion = snapshot.version;
|
|
3593
3676
|
const result = {
|
|
3594
3677
|
...change.result,
|
|
3595
3678
|
reviewId: id,
|
|
@@ -3611,7 +3694,8 @@ var ReviewStore = class {
|
|
|
3611
3694
|
if (change.relations?.dependsOn) this.setDependencies(id, change.relations.dependsOn);
|
|
3612
3695
|
if (previous && projectId !== previousProject && this.dropRelationsOutside(id, projectId)) result.warnings = [...result.warnings ?? [], "Its parent, children and dependencies were in its old project, so they were dropped: whiteboards relate only within a project."];
|
|
3613
3696
|
}, previous ? () => {
|
|
3614
|
-
this.
|
|
3697
|
+
if (change.inPlace) this.assertExists(id);
|
|
3698
|
+
else this.assertWritable(id);
|
|
3615
3699
|
if (change.baseVersion !== void 0) assertBaseVersion(change.baseVersion, this.currentVersion(id));
|
|
3616
3700
|
else this.assertMutation(id, previous.version);
|
|
3617
3701
|
holds();
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./src-X9phtB2j.js";
|
|
2
|
-
import {
|
|
3
|
-
import { a as toolResultText, s as ReviewApiError, t as ToolText } from "./agent-client-
|
|
4
|
-
import { n as REVIEW_STATUS_TOOL, t as authoringTools } from "./authoring-tools-
|
|
5
|
-
import { i as publicTool, n as RECOVERY, r as callPublicTool, t as toolFailure } from "./tool-failure-
|
|
2
|
+
import { st as ReviewInputError } from "./src-DirPN_Qh.js";
|
|
3
|
+
import { a as toolResultText, s as ReviewApiError, t as ToolText } from "./agent-client-BFtYm3Ng.js";
|
|
4
|
+
import { n as REVIEW_STATUS_TOOL, t as authoringTools } from "./authoring-tools-D1avYp8-.js";
|
|
5
|
+
import { a as renderedImage, i as publicTool, n as RECOVERY, r as callPublicTool, t as toolFailure } from "./tool-failure-BLBwcl3H.js";
|
|
6
6
|
import { Server } from "@modelcontextprotocol/server";
|
|
7
7
|
import { StdioServerTransport } from "@modelcontextprotocol/server/stdio";
|
|
8
8
|
//#region src/review-api/mcp-client-agent.ts
|
|
@@ -118,10 +118,13 @@ async function serveReviewMcp(connect, stdin, stdout, stderr = process.stderr, t
|
|
|
118
118
|
phase = "call";
|
|
119
119
|
tool = tools.find((tool) => tool.name === request.params.name);
|
|
120
120
|
if (!tool) throw new ReviewInputError(`Unknown Whiteboard tool: ${request.params.name}`);
|
|
121
|
-
const result = await callPublicTool(client, tool, request.params.arguments ?? {}, ctx.mcpReq.signal);
|
|
121
|
+
const { image, result } = renderedImage(tool, await callPublicTool(client, tool, request.params.arguments ?? {}, ctx.mcpReq.signal));
|
|
122
122
|
const text = toolResultText(tool, result);
|
|
123
123
|
report();
|
|
124
|
-
const response = { content: [{
|
|
124
|
+
const response = { content: [...image ? [{
|
|
125
|
+
type: "image",
|
|
126
|
+
...image
|
|
127
|
+
}] : [], {
|
|
125
128
|
type: "text",
|
|
126
129
|
text: listedWhileDown && tool.name === instructionsTool.name ? `${RELOAD_TOOLS}\n\n${text}` : text
|
|
127
130
|
}] };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { c as jsonString, o as jsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
|
|
2
|
-
import "./review-home-paths-
|
|
2
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
3
3
|
import { readFileSync } from "node:fs";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import { fileURLToPath } from "node:url";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a as projectOfCheckout, f as CheckoutGroups, o as groupCheckoutsAhead, s as initializeReviewStoreSchema, t as openLocalReviewStore } from "./local-data-
|
|
2
|
-
import "./review-home-paths-
|
|
1
|
+
import { a as projectOfCheckout, f as CheckoutGroups, o as groupCheckoutsAhead, s as initializeReviewStoreSchema, t as openLocalReviewStore } from "./local-data-B5PBZ0Ge.js";
|
|
2
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
3
3
|
import { j as withFileLock } from "./s3-config-CjcLyFV5.js";
|
|
4
4
|
import { access, mkdir } from "node:fs/promises";
|
|
5
5
|
import path from "node:path";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { i as readReviewPackageVersion } from "./package-paths-
|
|
2
|
-
import { a as readReviewServerHealth, l as serverNotReady } from "./server-discovery-
|
|
3
|
-
import { c as stopBackgroundServer, o as recordedBackgroundServer, r as ensureBackgroundServer } from "./background-server-
|
|
4
|
-
import { t as ensureRemoteLanguageServer } from "./remote-language-server-
|
|
1
|
+
import { i as readReviewPackageVersion } from "./package-paths-Dk7MOXxN.js";
|
|
2
|
+
import { a as readReviewServerHealth, l as serverNotReady } from "./server-discovery-DYY_xeG9.js";
|
|
3
|
+
import { c as stopBackgroundServer, o as recordedBackgroundServer, r as ensureBackgroundServer } from "./background-server-BiRSqjxG.js";
|
|
4
|
+
import { t as ensureRemoteLanguageServer } from "./remote-language-server-l4ConTfj.js";
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
import { spawn } from "node:child_process";
|
|
7
7
|
import { gt, valid } from "semver";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as ensureRemoteExtensions } from "./remote-extensions-
|
|
1
|
+
import { t as ensureRemoteExtensions } from "./remote-extensions-L95HNwIH.js";
|
|
2
2
|
export { ensureRemoteExtensions };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { u as parseJsonText } from "./src-X9phtB2j.js";
|
|
2
|
-
import "./review-home-paths-
|
|
2
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
3
3
|
import { N as devReviewHome } from "./s3-config-CjcLyFV5.js";
|
|
4
|
-
import { t as findReviewPackageRoot } from "./package-paths-
|
|
4
|
+
import { t as findReviewPackageRoot } from "./package-paths-Dk7MOXxN.js";
|
|
5
5
|
import { createHash } from "node:crypto";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
import { createReadStream, createWriteStream } from "node:fs";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "./review-home-paths-
|
|
1
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
2
2
|
import { A as processStartIdentity, j as withFileLock } from "./s3-config-CjcLyFV5.js";
|
|
3
|
-
import { t as findReviewPackageRoot } from "./package-paths-
|
|
4
|
-
import { n as cliSpawn, s as spawnDetached } from "./background-server-
|
|
5
|
-
import { r as remoteServerPaths, t as ensureRemoteExtensions } from "./remote-extensions-
|
|
3
|
+
import { t as findReviewPackageRoot } from "./package-paths-Dk7MOXxN.js";
|
|
4
|
+
import { n as cliSpawn, s as spawnDetached } from "./background-server-BiRSqjxG.js";
|
|
5
|
+
import { r as remoteServerPaths, t as ensureRemoteExtensions } from "./remote-extensions-L95HNwIH.js";
|
|
6
6
|
import { randomBytes } from "node:crypto";
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import { mkdir, readFile, rename, stat, writeFile } from "node:fs/promises";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "./review-home-paths-
|
|
1
|
+
import { T as REVIEW_REMOTE_WRAPPER_MARK, w as REVIEW_REMOTE_INSTALL_LOCK } from "./src-B-91Rd2d.js";
|
|
2
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
3
3
|
import { M as DEV_REVIEW_HOME_ENV } from "./s3-config-CjcLyFV5.js";
|
|
4
|
-
import { c as stopBackgroundServer, o as recordedBackgroundServer } from "./background-server-
|
|
5
|
-
import { i as whiteboardRemoteHome } from "./remote-extensions-
|
|
6
|
-
import { n as remoteLanguageServerGroups, r as stopProcessGroup } from "./remote-language-server-
|
|
4
|
+
import { c as stopBackgroundServer, o as recordedBackgroundServer } from "./background-server-BiRSqjxG.js";
|
|
5
|
+
import { i as whiteboardRemoteHome } from "./remote-extensions-L95HNwIH.js";
|
|
6
|
+
import { n as remoteLanguageServerGroups, r as stopProcessGroup } from "./remote-language-server-l4ConTfj.js";
|
|
7
7
|
import { existsSync } from "node:fs";
|
|
8
8
|
import { lstat, mkdir, readFile, readdir, rm, stat } from "node:fs/promises";
|
|
9
9
|
import path from "node:path";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { a as jsonNumber, c as jsonString, i as jsonBoolean, n as isJsonObject } from "./src-X9phtB2j.js";
|
|
2
|
-
import { X as SELECTION_UNAVAILABLE_REASONS } from "./src-
|
|
3
|
-
import { _ as REVIEW_DIFF_LAYOUTS, g as REVIEW_COLOR_THEME_KINDS, v as REVIEW_DIFF_LAYOUT_SCOPES } from "./src-
|
|
4
|
-
import { n as askAgentIds } from "./thread-state-
|
|
2
|
+
import { X as SELECTION_UNAVAILABLE_REASONS } from "./src-DirPN_Qh.js";
|
|
3
|
+
import { _ as REVIEW_DIFF_LAYOUTS, b as REVIEW_OPEN_FILES_IN_CHOICES, g as REVIEW_COLOR_THEME_KINDS, v as REVIEW_DIFF_LAYOUT_SCOPES } from "./src-B-91Rd2d.js";
|
|
4
|
+
import { n as askAgentIds } from "./thread-state-Jxoh1hde.js";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
//#region src/telemetry-clean-text.ts
|
|
7
7
|
const USER_DATA_REGEXES = [
|
|
@@ -178,7 +178,8 @@ const LSP_VIA = ["command", "mouse"];
|
|
|
178
178
|
const LSP_EDITOR_KIND = [
|
|
179
179
|
"files_tab",
|
|
180
180
|
"inline_peek",
|
|
181
|
-
"diff"
|
|
181
|
+
"diff",
|
|
182
|
+
"definition_peek"
|
|
182
183
|
];
|
|
183
184
|
const LSP_LANGUAGE = [
|
|
184
185
|
"typescript",
|
|
@@ -297,6 +298,20 @@ const MAP_LEVEL = [
|
|
|
297
298
|
"code"
|
|
298
299
|
];
|
|
299
300
|
const SOURCE_TREE_OPENED_VIA = ["topbar", "home"];
|
|
301
|
+
const SOURCE_OPENED_DESTINATION = [
|
|
302
|
+
"source_window",
|
|
303
|
+
"vscode",
|
|
304
|
+
"cursor",
|
|
305
|
+
"zed",
|
|
306
|
+
"intellij",
|
|
307
|
+
"application"
|
|
308
|
+
];
|
|
309
|
+
const SOURCE_OPENED_KIND = [
|
|
310
|
+
"file",
|
|
311
|
+
"diff",
|
|
312
|
+
"references",
|
|
313
|
+
"tree"
|
|
314
|
+
];
|
|
300
315
|
/** Tab names the dwell beacon reports. Shared with its request parser. */
|
|
301
316
|
const REVIEW_TELEMETRY_TABS = [
|
|
302
317
|
"review",
|
|
@@ -500,6 +515,13 @@ const UI_TELEMETRY_EVENTS = {
|
|
|
500
515
|
event: "review_source_tree_opened",
|
|
501
516
|
properties: { via: SOURCE_TREE_OPENED_VIA }
|
|
502
517
|
},
|
|
518
|
+
source_opened: {
|
|
519
|
+
event: "review_source_opened",
|
|
520
|
+
properties: {
|
|
521
|
+
destination: SOURCE_OPENED_DESTINATION,
|
|
522
|
+
kind: SOURCE_OPENED_KIND
|
|
523
|
+
}
|
|
524
|
+
},
|
|
503
525
|
whiteboard_file_exported: {
|
|
504
526
|
event: "review_whiteboard_file_exported",
|
|
505
527
|
properties: {}
|
|
@@ -644,7 +666,8 @@ const UI_TELEMETRY_EVENTS = {
|
|
|
644
666
|
properties: {
|
|
645
667
|
setting: SETTING_NAME,
|
|
646
668
|
enabled: "boolean",
|
|
647
|
-
value: REVIEW_COLOR_THEME_KINDS
|
|
669
|
+
value: REVIEW_COLOR_THEME_KINDS,
|
|
670
|
+
choice: REVIEW_OPEN_FILES_IN_CHOICES
|
|
648
671
|
}
|
|
649
672
|
},
|
|
650
673
|
review_opened: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { o as parseReviewVerbResponse } from "./src-
|
|
2
|
-
import { b as selectReviewInstance, m as healthyReviewInstance, v as reviewInstanceStartHint, y as reviewInstanceUnavailable } from "./server-discovery-
|
|
1
|
+
import { o as parseReviewVerbResponse } from "./src-B-91Rd2d.js";
|
|
2
|
+
import { b as selectReviewInstance, m as healthyReviewInstance, v as reviewInstanceStartHint, y as reviewInstanceUnavailable } from "./server-discovery-DYY_xeG9.js";
|
|
3
3
|
import { closeSync, existsSync, fstatSync, mkdtempSync, openSync, readSync } from "node:fs";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import { homedir, tmpdir } from "node:os";
|
|
@@ -379,7 +379,7 @@ async function runStoreLogin(input) {
|
|
|
379
379
|
};
|
|
380
380
|
let origin;
|
|
381
381
|
try {
|
|
382
|
-
origin = normalizeStoreOrigin(input.origin ?? DEFAULT_STORE_ORIGIN);
|
|
382
|
+
origin = normalizeStoreOrigin(input.origin || (input.env ?? process.env).DEV_REVIEW_SERVICE_ORIGIN || DEFAULT_STORE_ORIGIN);
|
|
383
383
|
} catch (error) {
|
|
384
384
|
return failWithJsonError(output, "login", errorMessage(error));
|
|
385
385
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { c as jsonString, l as jsonValueSchema, o as jsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
|
|
2
|
-
import "./src-
|
|
3
|
-
import "./review-home-paths-
|
|
2
|
+
import "./src-B-91Rd2d.js";
|
|
3
|
+
import "./review-home-paths-BmZX2qiz.js";
|
|
4
4
|
import { F as writeFileAtomic, N as devReviewHome, j as withFileLock, k as processIsAlive } from "./s3-config-CjcLyFV5.js";
|
|
5
|
-
import { i as readReviewPackageVersion, t as findReviewPackageRoot } from "./package-paths-
|
|
6
|
-
import "./request-origin-
|
|
5
|
+
import { i as readReviewPackageVersion, t as findReviewPackageRoot } from "./package-paths-Dk7MOXxN.js";
|
|
6
|
+
import "./request-origin-DZexKlc4.js";
|
|
7
7
|
import { createHmac, randomUUID } from "node:crypto";
|
|
8
8
|
import { z } from "zod";
|
|
9
9
|
import { existsSync, readFileSync, rmSync } from "node:fs";
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { S as splitGitPatchFiles, a as diff, o as diffFileSummaries } from "../src-Y30gweiK.js";
|
|
3
3
|
import { c as jsonString, i as jsonBoolean, n as isJsonObject, p as isObjectValue, s as jsonProperty, u as parseJsonText } from "../src-X9phtB2j.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { i as reviewInstanceDiscoveryPath, o as reviewLegacyDiscoveryPath } from "../review-home-paths-
|
|
8
|
-
import { p as pullRequestProvider } from "../stored-document-migration-
|
|
4
|
+
import { C as StreamLimitError, v as legacyModeSchema, w as readBoundedStream } from "../import-CjcW7EIQ.js";
|
|
5
|
+
import { st as ReviewInputError, y as resourceReferences } from "../src-DirPN_Qh.js";
|
|
6
|
+
import { F as reviewDiffrSummarizerInputSchema, O as ReviewConnectRequestSchema, d as ReviewBugReportRequestSchema, f as parseReviewBugReportResponse, j as ReviewGatewayHostSchema, m as REVIEW_CLIENT_REMOTE, p as REVIEW_CLIENT_HEADER, r as parseReviewDesktopVerbFrame, s as parseZod, t as parseReviewCliInstallApplyRequest, u as ReviewBugReportMetaV2Schema, y as REVIEW_HOST_HEADER } from "../src-B-91Rd2d.js";
|
|
7
|
+
import { i as reviewInstanceDiscoveryPath, o as reviewLegacyDiscoveryPath } from "../review-home-paths-BmZX2qiz.js";
|
|
8
|
+
import { p as pullRequestProvider } from "../stored-document-migration-vg0NAzXG.js";
|
|
9
9
|
import { L as writePrivateJsonAtomic, N as devReviewHome } from "../s3-config-CjcLyFV5.js";
|
|
10
10
|
import { t as errorMessage } from "../error-message-OtiDonty.js";
|
|
11
|
-
import { i as readReviewPackageVersion, t as findReviewPackageRoot } from "../package-paths-
|
|
12
|
-
import { _ as reviewInstanceIdentity, u as REVIEW_INSTANCE_ENV } from "../server-discovery-
|
|
13
|
-
import { t as openReviewProfile } from "../profile
|
|
14
|
-
import { r as reviewTelemetryChannel, t as ReviewTelemetry } from "../review-telemetry-
|
|
15
|
-
import { l as REVIEW_TELEMETRY_TABS } from "../request-origin-
|
|
16
|
-
import { c as removeLegacyReviewSkills, d as skipCliInstall, h as detectConnectAgents, i as finishCliInstallUpdate, l as resetCliInstall, m as connectAgent, n as applyCliInstall, o as pathShimPath, r as declineCliInstall, s as removeCliInstall, t as aliasInstallationToAccount, u as resolveCliInstallStatus } from "../account-alias-
|
|
17
|
-
import { C as
|
|
18
|
-
import { s as readQuerySchemas } from "../authoring-tools-
|
|
11
|
+
import { i as readReviewPackageVersion, t as findReviewPackageRoot } from "../package-paths-Dk7MOXxN.js";
|
|
12
|
+
import { _ as reviewInstanceIdentity, u as REVIEW_INSTANCE_ENV } from "../server-discovery-DYY_xeG9.js";
|
|
13
|
+
import { t as openReviewProfile } from "../profile-CNMhLUhf.js";
|
|
14
|
+
import { r as reviewTelemetryChannel, t as ReviewTelemetry } from "../review-telemetry-kQ7esDRE.js";
|
|
15
|
+
import { l as REVIEW_TELEMETRY_TABS } from "../request-origin-DZexKlc4.js";
|
|
16
|
+
import { c as removeLegacyReviewSkills, d as skipCliInstall, h as detectConnectAgents, i as finishCliInstallUpdate, l as resetCliInstall, m as connectAgent, n as applyCliInstall, o as pathShimPath, r as declineCliInstall, s as removeCliInstall, t as aliasInstallationToAccount, u as resolveCliInstallStatus } from "../account-alias-DXpd0Px8.js";
|
|
17
|
+
import { C as DEFAULT_MAX_REQUEST_BYTES, D as writeAnimationsEnabled, E as readAnimationsEnabled, O as cliAskTools, S as readBoundedRequestJson, T as ReviewServerError, _ as saveDiffrSummarizer, a as drainServerCrashReport, b as remoteShare, c as answerErrorsAsJson, d as captureSanitizedUiTelemetry, f as clientErrorsForSession, g as readDiffrConfig, h as migrateDiffrConfig, l as createWhiteboardCore, m as GlobalReviewDesktopVerbRelay, o as installProcessErrorTelemetry, p as recordClientError, r as takeOverServerHome, s as serverCrashReportPath, u as serverJson, v as setDiffrConfigValue, w as HttpJsonError, x as createNodeRequestListener, y as testDiffrSummarizer } from "../headless-host-CIuJJjmM.js";
|
|
18
|
+
import { s as readQuerySchemas } from "../authoring-tools-D1avYp8-.js";
|
|
19
19
|
import crypto, { createHash, randomBytes } from "node:crypto";
|
|
20
20
|
import { z } from "zod";
|
|
21
21
|
import { Agent, request } from "undici";
|
|
@@ -264,30 +264,6 @@ function listenForDesktopHostShutdown(hostProcess, onShutdown, onTelemetrySettin
|
|
|
264
264
|
return () => hostProcess.off("message", handleMessage);
|
|
265
265
|
}
|
|
266
266
|
//#endregion
|
|
267
|
-
//#region src/review-preferences.ts
|
|
268
|
-
/**
|
|
269
|
-
* Machine-wide Review preferences the server itself needs. Workbench settings
|
|
270
|
-
* do not work here: the review server never reads the workbench
|
|
271
|
-
* configuration.
|
|
272
|
-
*/
|
|
273
|
-
function reviewPreferencesPath(devHome = devReviewHome()) {
|
|
274
|
-
return path.join(devHome, "preferences.json");
|
|
275
|
-
}
|
|
276
|
-
/** Whether agents are offered animation authoring; existing animations
|
|
277
|
-
* always render. A missing or unreadable file means off; it never throws. */
|
|
278
|
-
async function readAnimationsEnabled(devHome) {
|
|
279
|
-
try {
|
|
280
|
-
const raw = parseJsonText(await readFile(reviewPreferencesPath(devHome), "utf8"));
|
|
281
|
-
return isJsonObject(raw) && raw.animationsEnabled === true;
|
|
282
|
-
} catch {
|
|
283
|
-
return false;
|
|
284
|
-
}
|
|
285
|
-
}
|
|
286
|
-
async function writeAnimationsEnabled(enabled, devHome) {
|
|
287
|
-
await writePrivateJsonAtomic(reviewPreferencesPath(devHome), { animationsEnabled: enabled });
|
|
288
|
-
return enabled;
|
|
289
|
-
}
|
|
290
|
-
//#endregion
|
|
291
267
|
//#region src/server/crash-report.ts
|
|
292
268
|
const CRASH_REPORT_URL = "https://bug.dev.fast/api/v2/crashes";
|
|
293
269
|
const gzipAsync = promisify(gzip);
|
|
@@ -1730,6 +1706,11 @@ const REMOTE_ROUTES = [
|
|
|
1730
1706
|
method: "POST",
|
|
1731
1707
|
path: "copy-context"
|
|
1732
1708
|
},
|
|
1709
|
+
{
|
|
1710
|
+
method: "POST",
|
|
1711
|
+
path: "share-bundle",
|
|
1712
|
+
slow: true
|
|
1713
|
+
},
|
|
1733
1714
|
{
|
|
1734
1715
|
method: "GET",
|
|
1735
1716
|
path: "language-context",
|
|
@@ -2130,6 +2111,7 @@ function createGlobalReviewServer(input) {
|
|
|
2130
2111
|
discovery.cliVersion = readReviewPackageVersion(pathToFileURL(cliPath).href);
|
|
2131
2112
|
if (input.cliRuntimePath && existsSync(input.cliRuntimePath)) discovery.cliRuntimePath = input.cliRuntimePath;
|
|
2132
2113
|
}
|
|
2114
|
+
const hooks = reviewLifecycleTelemetry(telemetry, (reviewId) => reviewStore.summary(reviewId)?.firstCreatedAt, () => aliasInstallationToAccount(telemetry));
|
|
2133
2115
|
const core = createWhiteboardCore({
|
|
2134
2116
|
profile: {
|
|
2135
2117
|
store: reviewStore,
|
|
@@ -2153,7 +2135,13 @@ function createGlobalReviewServer(input) {
|
|
|
2153
2135
|
home: devReviewHome()
|
|
2154
2136
|
};
|
|
2155
2137
|
},
|
|
2156
|
-
hooks:
|
|
2138
|
+
hooks: {
|
|
2139
|
+
...hooks,
|
|
2140
|
+
sharing: {
|
|
2141
|
+
...hooks.sharing,
|
|
2142
|
+
remoteShare: remoteShare((reviewId) => gateway.isRemote(reviewId), (request) => gateway.fetch(request))
|
|
2143
|
+
}
|
|
2144
|
+
},
|
|
2157
2145
|
ask: { tools: askTools }
|
|
2158
2146
|
});
|
|
2159
2147
|
const { app } = core;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as jsonNumber, n as isJsonObject, s as jsonProperty, u as parseJsonText } from "./src-X9phtB2j.js";
|
|
2
|
-
import { n as parseReviewDesktopDiscovery } from "./src-
|
|
3
|
-
import { a as reviewInstancesDir, o as reviewLegacyDiscoveryPath, r as reviewDevInstanceKey, t as reviewDefaultInstancePath } from "./review-home-paths-
|
|
2
|
+
import { n as parseReviewDesktopDiscovery } from "./src-B-91Rd2d.js";
|
|
3
|
+
import { a as reviewInstancesDir, o as reviewLegacyDiscoveryPath, r as reviewDevInstanceKey, t as reviewDefaultInstancePath } from "./review-home-paths-BmZX2qiz.js";
|
|
4
4
|
import { M as DEV_REVIEW_HOME_ENV, N as devReviewHome, k as processIsAlive } from "./s3-config-CjcLyFV5.js";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
import { mkdir, readFile, readdir, rm, writeFile } from "node:fs/promises";
|