You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
openhuman.test_reset (added in tinyhumansai#1859) currently wipes only what cron-jobs-flow.spec.ts needs: auth marker, api_key, chat_onboarding_completed, and cron jobs. Other domains carry over state across the in-place reset, which will silently contaminate later specs in the same Appium session.
Problem
The test_reset RPC is the contract that the single-Appium-session model rests on: every spec calls resetApp(<userId>) which calls this RPC, and downstream tests trust it to produce a pristine workspace. Today it lies about that — only four domain stores get cleared.
Domains known to persist state through test_reset today:
memory — vector store, KV docs, knowledge graph
memory_tree — chunks + summary tree + sync state (already has wipe_all_rpc to reuse)
channels — channel definitions, web channel connections
skills — discovered SKILL.md installs
webview_accounts — provider account markers
threads — conversation thread + message history
notifications — integration notification queue
webhooks — tunnel registrations + capture log
cost — token usage history
referral — apply state
composio — synced connections, triggers
Each batch in tinyhumansai#1860 that touches a new domain will need that domain's wipe wired in.
Solution
Define a WipeHook trait in src/openhuman/test_support/ so each domain owns its own wipe and test_reset_rpc just iterates registered hooks.
Register one hook per domain in the domain's mod.rs (mirrors the controller-registration pattern from AGENTS.md). Reuses existing wipe_all_rpc / clear_all_jobs where they exist.
Each new domain hook returns an entry in the ResetSummary so test logs make it obvious what was actually wiped.
Add a regression test in tests/json_rpc_e2e.rs that seeds each known domain, runs test_reset, and asserts the seeds are gone.
Acceptance criteria
Hook trait + registry — test_support/registry.rs (or similar) defines the trait and the iteration loop.
Summary
openhuman.test_reset(added in tinyhumansai#1859) currently wipes only whatcron-jobs-flow.spec.tsneeds: auth marker,api_key,chat_onboarding_completed, and cron jobs. Other domains carry over state across the in-place reset, which will silently contaminate later specs in the same Appium session.Problem
The
test_resetRPC is the contract that the single-Appium-session model rests on: every spec callsresetApp(<userId>)which calls this RPC, and downstream tests trust it to produce a pristine workspace. Today it lies about that — only four domain stores get cleared.Domains known to persist state through
test_resettoday:memory— vector store, KV docs, knowledge graphmemory_tree— chunks + summary tree + sync state (already haswipe_all_rpcto reuse)channels— channel definitions, web channel connectionsskills— discovered SKILL.md installswebview_accounts— provider account markersthreads— conversation thread + message historynotifications— integration notification queuewebhooks— tunnel registrations + capture logcost— token usage historyreferral— apply statecomposio— synced connections, triggersEach batch in tinyhumansai#1860 that touches a new domain will need that domain's wipe wired in.
Solution
WipeHooktrait insrc/openhuman/test_support/so each domain owns its own wipe andtest_reset_rpcjust iterates registered hooks.mod.rs(mirrors the controller-registration pattern fromAGENTS.md). Reuses existingwipe_all_rpc/clear_all_jobswhere they exist.ResetSummaryso test logs make it obvious what was actually wiped.tests/json_rpc_e2e.rsthat seeds each known domain, runstest_reset, and asserts the seeds are gone.Acceptance criteria
test_support/registry.rs(or similar) defines the trait and the iteration loop.ResetSummaryextended — each hook reports a row count in the returned struct so spec logs are auditable.tests/json_rpc_e2e.rscovers the wipe contract for every registered hook.Related