@otto-code/server 0.6.1 → 0.6.2
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/server/server/agent/agent-projections.d.ts +7 -2
- package/dist/server/server/agent/agent-projections.js +26 -4
- package/dist/server/services/git-hosting/bitbucket-cloud-service.js +6 -3
- package/dist/server/web-ui/_expo/static/js/web/{desktop-attachment-bridge-e8bd8641668e8856e8910cb809e410d4.js → desktop-attachment-bridge-eb9388cfd25e200e2ba3a134995ce150.js} +1 -1
- package/dist/server/web-ui/_expo/static/js/web/{desktop-attachment-bridge-e8bd8641668e8856e8910cb809e410d4.js.br → desktop-attachment-bridge-eb9388cfd25e200e2ba3a134995ce150.js.br} +0 -0
- package/dist/server/web-ui/_expo/static/js/web/desktop-attachment-bridge-eb9388cfd25e200e2ba3a134995ce150.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{desktop-attachment-store-04b21b31b6d604fb931ad33d5dcebe6e.js → desktop-attachment-store-94b1f23075faf1de78057dc191416efe.js} +1 -1
- package/dist/server/web-ui/_expo/static/js/web/{desktop-attachment-store-04b21b31b6d604fb931ad33d5dcebe6e.js.br → desktop-attachment-store-94b1f23075faf1de78057dc191416efe.js.br} +0 -0
- package/dist/server/web-ui/_expo/static/js/web/desktop-attachment-store-94b1f23075faf1de78057dc191416efe.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{index-afa53b2590ee10a7223d1c7e47952e2f.js → index-3ca23b0cc5eb322c97f72ed0bfff897e.js} +236 -235
- package/dist/server/web-ui/_expo/static/js/web/index-3ca23b0cc5eb322c97f72ed0bfff897e.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/index-3ca23b0cc5eb322c97f72ed0bfff897e.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{indexeddb-attachment-store-bff017e83efa0422cc03347e6f09dde9.js → indexeddb-attachment-store-c54c29dc3949090c6798c8116b94bf41.js} +1 -1
- package/dist/server/web-ui/_expo/static/js/web/{indexeddb-attachment-store-bff017e83efa0422cc03347e6f09dde9.js.br → indexeddb-attachment-store-c54c29dc3949090c6798c8116b94bf41.js.br} +0 -0
- package/dist/server/web-ui/_expo/static/js/web/indexeddb-attachment-store-c54c29dc3949090c6798c8116b94bf41.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{native-file-attachment-store-03883e651ac4ae0476c4bbdd4d1c4228.js → native-file-attachment-store-cdd5645f9e28ba0c50f94683bb39ee60.js} +3 -3
- package/dist/server/web-ui/_expo/static/js/web/native-file-attachment-store-cdd5645f9e28ba0c50f94683bb39ee60.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/native-file-attachment-store-cdd5645f9e28ba0c50f94683bb39ee60.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-48fb770057892d05202bd5a5f7f01ae6.js +1 -0
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-48fb770057892d05202bd5a5f7f01ae6.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-48fb770057892d05202bd5a5f7f01ae6.js.gz +0 -0
- package/dist/server/web-ui/index.html +1 -1
- package/dist/server/web-ui/index.html.br +0 -0
- package/dist/server/web-ui/index.html.gz +0 -0
- package/package.json +5 -5
- package/dist/server/web-ui/_expo/static/js/web/desktop-attachment-bridge-e8bd8641668e8856e8910cb809e410d4.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/desktop-attachment-store-04b21b31b6d604fb931ad33d5dcebe6e.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/index-afa53b2590ee10a7223d1c7e47952e2f.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/index-afa53b2590ee10a7223d1c7e47952e2f.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/indexeddb-attachment-store-bff017e83efa0422cc03347e6f09dde9.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/native-file-attachment-store-03883e651ac4ae0476c4bbdd4d1c4228.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/native-file-attachment-store-03883e651ac4ae0476c4bbdd4d1c4228.js.gz +0 -0
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-52cba06aaca6a8e58803af89002e4230.js +0 -1
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-52cba06aaca6a8e58803af89002e4230.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/visualizer-bundle-52cba06aaca6a8e58803af89002e4230.js.gz +0 -0
|
@@ -22,14 +22,19 @@ export declare function buildStoredAgentPayload(record: StoredAgentRecord, valid
|
|
|
22
22
|
* Derive the frozen row name for an observed subagent. Prefer the stable
|
|
23
23
|
* `subAgentType` (e.g. "code-explorer") over the description — a `task_progress`
|
|
24
24
|
* description is the ever-changing AI summary, which must never become the
|
|
25
|
-
* label.
|
|
25
|
+
* label. Generic catch-all types ("general-purpose") are skipped in favor of
|
|
26
|
+
* the description. Callers freeze the result at the first named update.
|
|
26
27
|
* See docs/agent-lifecycle.md (Item 4).
|
|
27
28
|
*/
|
|
28
29
|
export declare function deriveObservedSubagentTitle(update: {
|
|
29
30
|
subAgentType?: string;
|
|
30
31
|
description?: string;
|
|
31
32
|
}): string;
|
|
32
|
-
/**
|
|
33
|
+
/**
|
|
34
|
+
* True when this update carries a real name source we can freeze the title on.
|
|
35
|
+
* A generic catch-all type alone doesn't count — freezing "general-purpose"
|
|
36
|
+
* would lock out the description a later update may carry.
|
|
37
|
+
*/
|
|
33
38
|
export declare function observedUpdateHasTitleSource(update: {
|
|
34
39
|
subAgentType?: string;
|
|
35
40
|
description?: string;
|
|
@@ -251,15 +251,33 @@ function normalizeObservedTitleSource(value) {
|
|
|
251
251
|
const collapsed = value.replace(/\s+/g, " ").trim();
|
|
252
252
|
return collapsed.length > 0 ? collapsed : null;
|
|
253
253
|
}
|
|
254
|
+
// Catch-all subagent types that make lousy row labels — Claude's default Task
|
|
255
|
+
// runs as "general-purpose". These never become the title; the task description
|
|
256
|
+
// names the row instead (user-locked).
|
|
257
|
+
const GENERIC_OBSERVED_SUBAGENT_TYPES = new Set([
|
|
258
|
+
"general-purpose",
|
|
259
|
+
"general",
|
|
260
|
+
"task",
|
|
261
|
+
"agent",
|
|
262
|
+
"subagent",
|
|
263
|
+
]);
|
|
264
|
+
function normalizeObservedSubagentType(value) {
|
|
265
|
+
const normalized = normalizeObservedTitleSource(value);
|
|
266
|
+
if (normalized === null || GENERIC_OBSERVED_SUBAGENT_TYPES.has(normalized.toLowerCase())) {
|
|
267
|
+
return null;
|
|
268
|
+
}
|
|
269
|
+
return normalized;
|
|
270
|
+
}
|
|
254
271
|
/**
|
|
255
272
|
* Derive the frozen row name for an observed subagent. Prefer the stable
|
|
256
273
|
* `subAgentType` (e.g. "code-explorer") over the description — a `task_progress`
|
|
257
274
|
* description is the ever-changing AI summary, which must never become the
|
|
258
|
-
* label.
|
|
275
|
+
* label. Generic catch-all types ("general-purpose") are skipped in favor of
|
|
276
|
+
* the description. Callers freeze the result at the first named update.
|
|
259
277
|
* See docs/agent-lifecycle.md (Item 4).
|
|
260
278
|
*/
|
|
261
279
|
export function deriveObservedSubagentTitle(update) {
|
|
262
|
-
const base =
|
|
280
|
+
const base = normalizeObservedSubagentType(update.subAgentType) ??
|
|
263
281
|
normalizeObservedTitleSource(update.description) ??
|
|
264
282
|
"Subagent";
|
|
265
283
|
if (base.length <= OBSERVED_SUBAGENT_TITLE_MAX) {
|
|
@@ -267,9 +285,13 @@ export function deriveObservedSubagentTitle(update) {
|
|
|
267
285
|
}
|
|
268
286
|
return `${base.slice(0, OBSERVED_SUBAGENT_TITLE_MAX - 1).trimEnd()}…`;
|
|
269
287
|
}
|
|
270
|
-
/**
|
|
288
|
+
/**
|
|
289
|
+
* True when this update carries a real name source we can freeze the title on.
|
|
290
|
+
* A generic catch-all type alone doesn't count — freezing "general-purpose"
|
|
291
|
+
* would lock out the description a later update may carry.
|
|
292
|
+
*/
|
|
271
293
|
export function observedUpdateHasTitleSource(update) {
|
|
272
|
-
return (
|
|
294
|
+
return (normalizeObservedSubagentType(update.subAgentType) !== null ||
|
|
273
295
|
normalizeObservedTitleSource(update.description) !== null);
|
|
274
296
|
}
|
|
275
297
|
export function toObservedSubagentPayload(input) {
|
|
@@ -151,15 +151,18 @@ const BitbucketCreatedPullRequestSchema = z.object({
|
|
|
151
151
|
.optional()
|
|
152
152
|
.catch(undefined),
|
|
153
153
|
});
|
|
154
|
+
// Lowercase to match the GitHub service's wire shape — the client compares
|
|
155
|
+
// state === "open" exactly, so Bitbucket's uppercase "OPEN" rendered as a red
|
|
156
|
+
// "Closed" badge on open PRs.
|
|
154
157
|
function mapPullRequestState(state) {
|
|
155
158
|
switch (state) {
|
|
156
159
|
case "OPEN":
|
|
157
|
-
return { state: "
|
|
160
|
+
return { state: "open", isMerged: false };
|
|
158
161
|
case "MERGED":
|
|
159
|
-
return { state: "
|
|
162
|
+
return { state: "merged", isMerged: true };
|
|
160
163
|
default:
|
|
161
164
|
// DECLINED / SUPERSEDED
|
|
162
|
-
return { state: "
|
|
165
|
+
return { state: "closed", isMerged: false };
|
|
163
166
|
}
|
|
164
167
|
}
|
|
165
168
|
function mapCommitStatusState(state) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.createDesktopAttachmentBridge=function(){const l=(0,s.createDesktopPreviewUrlResolver)({reader:(0,s.createDesktopFileReader)(),objectUrls:(0,s.createBrowserObjectUrlMinter)()});return{copyFile:t.copyDesktopAttachmentFile,writeBase64:t.writeDesktopAttachmentBase64,writeBytes:t.writeDesktopAttachmentBytes,deleteFile:t.deleteDesktopAttachmentFile,garbageCollect:t.garbageCollectDesktopAttachmentFiles,readFileBase64:s.readDesktopFileBase64,resolvePreviewUrl:t=>l.resolve(t),releasePreviewUrl:t=>l.release(t)}};var t=r(d[0]),s=r(d[1])},
|
|
1
|
+
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.createDesktopAttachmentBridge=function(){const l=(0,s.createDesktopPreviewUrlResolver)({reader:(0,s.createDesktopFileReader)(),objectUrls:(0,s.createBrowserObjectUrlMinter)()});return{copyFile:t.copyDesktopAttachmentFile,writeBase64:t.writeDesktopAttachmentBase64,writeBytes:t.writeDesktopAttachmentBytes,deleteFile:t.deleteDesktopAttachmentFile,garbageCollect:t.garbageCollectDesktopAttachmentFiles,readFileBase64:s.readDesktopFileBase64,resolvePreviewUrl:t=>l.resolve(t),releasePreviewUrl:t=>l.release(t)}};var t=r(d[0]),s=r(d[1])},3015,[2442,2443]);
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.createDesktopAttachmentStore=function(n){return{storageType:"desktop-file",async save(s){const o=s.id??(0,t.generateAttachmentId)(),l=s.fileName??null;if("file_uri"===s.source.kind)return await c(n,{id:o,uri:s.source.uri,mimeType:s.mimeType,fileName:l});if("data_url"===s.source.kind){const c=(0,t.parseDataUrl)(s.source.dataUrl),p=(0,t.normalizeMimeType)(s.mimeType??c.mimeType);return await y(n,{id:o,base64:c.base64,mimeType:p,fileName:l})}if("bytes"===s.source.kind){const c=(0,t.normalizeMimeType)(s.mimeType);return await p(n,{id:o,bytes:s.source.bytes,mimeType:c,fileName:l})}const f=(0,t.normalizeMimeType)(s.mimeType??s.source.blob.type),u=await(0,t.blobToBase64)(s.source.blob);return await y(n,{id:o,base64:u,mimeType:f,fileName:l})},encodeBase64:async({attachment:t})=>(f(t),await n.readFileBase64(t.storageKey)),resolvePreviewUrl:async({attachment:t})=>(f(t),await n.resolvePreviewUrl(t)),async releasePreviewUrl({attachment:t,url:s}){f(t),await n.releasePreviewUrl({url:s})},async delete({attachment:t}){f(t),await n.deleteFile({path:t.storageKey})},async garbageCollect({referencedIds:t}){await n.garbageCollect({referencedIds:Array.from(t)})}}};var t=r(d[0]);const n={"image/png":".png","image/jpeg":".jpg","image/jpg":".jpg","image/gif":".gif","image/webp":".webp","image/avif":".avif","image/heic":".heic","image/heif":".heif","image/tiff":".tiff","image/bmp":".bmp","image/svg+xml":".svg"};function s(t){const n=t.replace(/\\/g,"/").split("/"),s=n[n.length-1];return s&&s.length>0?s:null}function o(s){const o=(0,t.getFileExtensionFromName)(s.fileName);if(o)return o;const l=(0,t.getFileExtensionFromName)(s.sourcePath);return l||(n[s.mimeType]??".img")}function l(t){return{id:t.id,mimeType:t.mimeType,storageType:"desktop-file",storageKey:t.storagePath,fileName:t.fileName??null,byteSize:t.byteSize,createdAt:Date.now()}}async function c(n,c){const y=(0,t.fileUriToPath)(c.uri),p=c.fileName??s(y),f=(0,t.normalizeMimeType)(c.mimeType),u=o({fileName:p,sourcePath:y,mimeType:f}),T=await n.copyFile({attachmentId:c.id,sourcePath:y,extension:u});return l({id:c.id,mimeType:f,storagePath:T.path,byteSize:T.byteSize,fileName:p})}async function y(t,n){const s=o({fileName:n.fileName,mimeType:n.mimeType}),c=await t.writeBase64({attachmentId:n.id,base64:n.base64,extension:s});return l({id:n.id,mimeType:n.mimeType,storagePath:c.path,byteSize:c.byteSize,fileName:n.fileName})}async function p(t,n){const s=o({fileName:n.fileName,mimeType:n.mimeType}),c=await t.writeBytes({attachmentId:n.id,bytes:n.bytes,extension:s});return l({id:n.id,mimeType:n.mimeType,storagePath:c.path,byteSize:c.byteSize,fileName:n.fileName})}function f(t){if("desktop-file"!==t.storageType)throw new Error(`Unsupported desktop attachment storage type '${t.storageType}'.`)}},
|
|
1
|
+
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.createDesktopAttachmentStore=function(n){return{storageType:"desktop-file",async save(s){const o=s.id??(0,t.generateAttachmentId)(),l=s.fileName??null;if("file_uri"===s.source.kind)return await c(n,{id:o,uri:s.source.uri,mimeType:s.mimeType,fileName:l});if("data_url"===s.source.kind){const c=(0,t.parseDataUrl)(s.source.dataUrl),p=(0,t.normalizeMimeType)(s.mimeType??c.mimeType);return await y(n,{id:o,base64:c.base64,mimeType:p,fileName:l})}if("bytes"===s.source.kind){const c=(0,t.normalizeMimeType)(s.mimeType);return await p(n,{id:o,bytes:s.source.bytes,mimeType:c,fileName:l})}const f=(0,t.normalizeMimeType)(s.mimeType??s.source.blob.type),u=await(0,t.blobToBase64)(s.source.blob);return await y(n,{id:o,base64:u,mimeType:f,fileName:l})},encodeBase64:async({attachment:t})=>(f(t),await n.readFileBase64(t.storageKey)),resolvePreviewUrl:async({attachment:t})=>(f(t),await n.resolvePreviewUrl(t)),async releasePreviewUrl({attachment:t,url:s}){f(t),await n.releasePreviewUrl({url:s})},async delete({attachment:t}){f(t),await n.deleteFile({path:t.storageKey})},async garbageCollect({referencedIds:t}){await n.garbageCollect({referencedIds:Array.from(t)})}}};var t=r(d[0]);const n={"image/png":".png","image/jpeg":".jpg","image/jpg":".jpg","image/gif":".gif","image/webp":".webp","image/avif":".avif","image/heic":".heic","image/heif":".heif","image/tiff":".tiff","image/bmp":".bmp","image/svg+xml":".svg"};function s(t){const n=t.replace(/\\/g,"/").split("/"),s=n[n.length-1];return s&&s.length>0?s:null}function o(s){const o=(0,t.getFileExtensionFromName)(s.fileName);if(o)return o;const l=(0,t.getFileExtensionFromName)(s.sourcePath);return l||(n[s.mimeType]??".img")}function l(t){return{id:t.id,mimeType:t.mimeType,storageType:"desktop-file",storageKey:t.storagePath,fileName:t.fileName??null,byteSize:t.byteSize,createdAt:Date.now()}}async function c(n,c){const y=(0,t.fileUriToPath)(c.uri),p=c.fileName??s(y),f=(0,t.normalizeMimeType)(c.mimeType),u=o({fileName:p,sourcePath:y,mimeType:f}),T=await n.copyFile({attachmentId:c.id,sourcePath:y,extension:u});return l({id:c.id,mimeType:f,storagePath:T.path,byteSize:T.byteSize,fileName:p})}async function y(t,n){const s=o({fileName:n.fileName,mimeType:n.mimeType}),c=await t.writeBase64({attachmentId:n.id,base64:n.base64,extension:s});return l({id:n.id,mimeType:n.mimeType,storagePath:c.path,byteSize:c.byteSize,fileName:n.fileName})}async function p(t,n){const s=o({fileName:n.fileName,mimeType:n.mimeType}),c=await t.writeBytes({attachmentId:n.id,bytes:n.bytes,extension:s});return l({id:n.id,mimeType:n.mimeType,storagePath:c.path,byteSize:c.byteSize,fileName:n.fileName})}function f(t){if("desktop-file"!==t.storageType)throw new Error(`Unsupported desktop attachment storage type '${t.storageType}'.`)}},3014,[2444]);
|
|
Binary file
|