@omercnet/paseo-omp 1.0.3-next.193.1 → 1.0.3-next.195.1

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.
@@ -52,16 +52,17 @@ export function OmpMemoryPanel({ theme, layout, workspaceId }: PluginWorkspacePa
52
52
  return (
53
53
  <ScrollView contentContainerStyle={styles.root}>
54
54
  <View style={{ gap: 4 }}>
55
- <Text style={styles.title}>OMP Memory</Text>
55
+ <Text style={styles.title}>Local Mnemopi Memory</Text>
56
+ <Text style={styles.subtitle}>Shows local facts only.</Text>
56
57
  <Text style={styles.subtitle}>
57
- {memory.data?.bank ? `Bank: ${memory.data.bank}` : "Retained workspace facts"}
58
+ {memory.data?.bank ? `Local bank: ${memory.data.bank}` : "Local Mnemopi workspace facts"}
58
59
  </Text>
59
60
  </View>
60
61
  <OmpStorePicker theme={theme} store={store} onChange={setStore} />
61
- {memory.isLoading ? <Text style={styles.subtitle}>Loading retained facts…</Text> : null}
62
- {memory.error ? <Text style={styles.error}>Could not read workspace memory.</Text> : null}
62
+ {memory.isLoading ? <Text style={styles.subtitle}>Loading local Mnemopi facts…</Text> : null}
63
+ {memory.error ? <Text style={styles.error}>Could not read local Mnemopi facts.</Text> : null}
63
64
  {!memory.isLoading && !memory.error && (memory.data?.facts.length ?? 0) === 0 ? (
64
- <Text style={styles.subtitle}>No retained facts for this workspace.</Text>
65
+ <Text style={styles.subtitle}>No local Mnemopi facts for this workspace.</Text>
65
66
  ) : null}
66
67
  {memory.data?.facts.map((fact) => (
67
68
  <View key={fact.id} style={styles.card}>
@@ -43,21 +43,23 @@ export function MemoryPopover(props: PluginButtonContentProps) {
43
43
  [layout.compact, theme],
44
44
  );
45
45
 
46
- if (memory.isLoading) return <Text style={styles.muted}>Loading retained facts…</Text>;
47
- if (memory.error) return <Text style={styles.error}>Could not read workspace memory.</Text>;
48
-
49
46
  const facts = memory.data?.facts ?? [];
50
- if (facts.length === 0) {
51
- return <Text style={styles.muted}>No retained facts for this workspace.</Text>;
52
- }
53
47
 
54
48
  return (
55
49
  <View style={styles.root}>
56
50
  <View style={styles.header}>
57
- <Text style={styles.title}>OMP Memory · {storeLabel(store)}</Text>
51
+ <Text style={styles.title}>Local Mnemopi · {storeLabel(store)}</Text>
58
52
  <Text style={styles.muted}>{facts.length} facts</Text>
59
53
  </View>
60
- <Text style={styles.muted}>{memory.data?.bank ?? "Workspace memory"}</Text>
54
+ <Text style={styles.muted}>Shows local facts only.</Text>
55
+ {memory.isLoading ? <Text style={styles.muted}>Loading local Mnemopi facts…</Text> : null}
56
+ {memory.error ? <Text style={styles.error}>Could not read local Mnemopi facts.</Text> : null}
57
+ {!memory.isLoading && !memory.error && facts.length === 0 ? (
58
+ <Text style={styles.muted}>No local Mnemopi facts for this workspace.</Text>
59
+ ) : null}
60
+ {!memory.isLoading && !memory.error && memory.data?.bank ? (
61
+ <Text style={styles.muted}>{memory.data.bank}</Text>
62
+ ) : null}
61
63
  {facts.slice(0, PREVIEW_LIMIT).map((fact) => (
62
64
  <View key={fact.id} style={styles.card}>
63
65
  <Text style={styles.fact}>{`${fact.subject} ${fact.predicate} ${fact.object}`}</Text>
package/index.client.tsx CHANGED
@@ -133,7 +133,7 @@ export default function contribute(client: PluginClientContext) {
133
133
  });
134
134
  const removeOpenMemory = client.addCommandCenterItem({
135
135
  id: "open-memory",
136
- title: "Open OMP Memory",
136
+ title: "Open local memory",
137
137
  icon: "Brain",
138
138
  keywords: ["omp", "memory", "facts", "recall"],
139
139
  context: "workspace",
@@ -245,7 +245,7 @@ export default function contribute(client: PluginClientContext) {
245
245
  workspaceId: entry.workspaceId,
246
246
  agentId: agent.id,
247
247
  button: {
248
- title: "OMP workspace memory",
248
+ title: "Local memory",
249
249
  icon: "Brain",
250
250
  label: "Memory",
251
251
  behavior: { kind: "popover", Content: MemoryPopover },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omercnet/paseo-omp",
3
- "version": "1.0.3-next.193.1",
3
+ "version": "1.0.3-next.195.1",
4
4
  "type": "module",
5
5
  "description": "Paseo integration for OMP, including its direct provider and workspace tooling.",
6
6
  "license": "MIT",
@@ -1,2 +1,2 @@
1
1
  /** Release Please keeps this bundle-safe constant aligned with package.json. */
2
- export const PASEO_OMP_PACKAGE_VERSION = "1.0.3-next.193.1"; // x-release-please-version
2
+ export const PASEO_OMP_PACKAGE_VERSION = "1.0.3-next.195.1"; // x-release-please-version
@@ -12,6 +12,7 @@ import {
12
12
  type ProcessTreeCleanup,
13
13
  stopWindowsTree,
14
14
  terminatePosixProcessTree,
15
+ waitMs,
15
16
  } from "./omp-rpc-process";
16
17
  import {
17
18
  createOptionalMetadataSanitizer,
@@ -56,7 +57,10 @@ import {
56
57
  sanitizeHistoryResponseData,
57
58
  sanitizeLiveDisplayFrame,
58
59
  } from "./omp-rpc-protocol";
59
- import { boundedJsonBytes, OmpPublicError, utf8Bytes } from "./security";
60
+ import { boundedJsonBytes, OmpCleanupFailure, OmpPublicError, utf8Bytes } from "./security";
61
+
62
+ // Unverified close keeps the native session quarantined; these retries let a slow exit clear it.
63
+ const TREE_CLEANUP_RETRY_DELAYS_MS = [500, 1_000, 2_000, 4_000];
60
64
 
61
65
  type TimerHandle = number | NodeJS.Timeout;
62
66
  type SpawnProcess = (request: OmpSpawnRequest) => ChildProcessWithoutNullStreams;
@@ -483,7 +487,12 @@ export class OmpRpcProcess {
483
487
  }
484
488
  }
485
489
  const cleanup = await cleanupPromise;
486
- if (cleanup !== "verified") throw new Error("OMP RPC process tree cleanup failed");
490
+ if (cleanup !== "verified") {
491
+ throw new OmpCleanupFailure(
492
+ "OMP RPC process tree cleanup failed",
493
+ this.reverifyTreeCleanup(),
494
+ );
495
+ }
487
496
  if (process.platform === "win32" && !this.exited) {
488
497
  try {
489
498
  this.child.stdin.end();
@@ -496,8 +505,28 @@ export class OmpRpcProcess {
496
505
  !this.exited &&
497
506
  !(await this.waitForExit(PROCESS_STOP_TIMEOUT_MS))
498
507
  ) {
499
- throw new Error("OMP RPC process did not close after tree cleanup");
508
+ throw new OmpCleanupFailure(
509
+ "OMP RPC process did not close after tree cleanup",
510
+ this.reverifyTreeCleanup(),
511
+ );
512
+ }
513
+ }
514
+
515
+ private async reverifyTreeCleanup(): Promise<void> {
516
+ const pid = this.child.pid;
517
+ if (pid !== undefined) {
518
+ for (const delayMs of TREE_CLEANUP_RETRY_DELAYS_MS) {
519
+ await waitMs(delayMs);
520
+ const outcome = await this.terminateProcessTree(pid).catch(() => "failed");
521
+ if (
522
+ outcome === "verified" &&
523
+ (this.exited || (await this.waitForExit(PROCESS_STOP_TIMEOUT_MS)))
524
+ ) {
525
+ return;
526
+ }
527
+ }
500
528
  }
529
+ throw new Error("OMP RPC process tree cleanup is unverified");
501
530
  }
502
531
 
503
532
  private startTreeCleanup(): Promise<ProcessTreeCleanup> {