Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

test(e2e): brain embedding-truthfulness and notifications feed Playwright specs\n\nBoth drive the real app in a browser against a live openhuman-core. Neither\nmocks transport.\n\nbrain-embedding-truthfulness.spec.ts seeds a folder source through the core's\nown RPCs and reads memory_sources_status_list to confirm chunks_pending > 0\nBEFORE asserting on the UI, so a workspace with a healthy embedder skips with a\nreason instead of passing vacuously. Absolute mkdtemp paths throughout: a\nrelative source path resolves against the core's working directory.\n\nFixed against the live core on the first run: memory_sources_sync takes\nsource_id (not id), and memory_sources_add returns { source }.\n\nKNOWN: this spec cannot pass in a sandbox with no GitHub release access. The\nmemory engine is a downloaded cdylib and memory_sources_sync fails with\n"module 'tinymemory' could not be loaded". Reported as undrivable rather than\nre-done in jsdom. See ~/tinyhuman/bugs/W6-ui-bugs.md #5.\n\nnotifications-feed-interaction.spec.ts covers the system-events feed, which no\ncore RPC can reach — those items arrive over socket.io into a redux-persist\nslice. It seeds the slice through the app's own persistence keys, exactly what a\nreturning user's browser holds, and asserts on rendered text, aria-selected on\nthe chip tablist, the unread count, and survival of a reload.\n

M3gA-Mindaa9771b4c7a3
diff --git a/app/test/playwright/specs/brain-embedding-truthfulness.spec.ts b/app/test/playwright/specs/brain-embedding-truthfulness.spec.ts
index f666621394..0a77f8c19e 100644
--- a/app/test/playwright/specs/brain-embedding-truthfulness.spec.ts
+++ b/app/test/playwright/specs/brain-embedding-truthfulness.spec.ts
@@ -79,20 +79,18 @@ function makeCorpus(files: number): string {
async function addAndSync(label: string, files = 3): Promise<{ id: string; root: string }> {
const root = makeCorpus(files);
- const added = await callCoreRpc<{ id?: string } | null>('openhuman.memory_sources_add', {
+ const added = await callCoreRpc<{ source?: { id?: string } }>('openhuman.memory_sources_add', {
kind: 'folder',
label,
enabled: true,
path: root,
glob: '**/*.md',
});
- const list = await callCoreRpc<{ sources: Array<{ id: string; label: string }> }>(
- 'openhuman.memory_sources_list',
- {}
- );
- const id = added?.id ?? list.sources.find(s => s.label === label)?.id;
+ const id = added?.source?.id;
if (!id) throw new Error(`source ${label} was not created`);
- await callCoreRpc('openhuman.memory_sources_sync', { id });
+ // `source_id`, not `id` — the core rejects the latter with
+ // "missing required param 'source_id'". Cost the first run of this spec.
+ await callCoreRpc('openhuman.memory_sources_sync', { source_id: id });
return { id, root };
}