[hero_planner_web] Web UI broken after oschema cutover — data RPC calls 404 #18
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lhumina_code/hero_planner#18
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
After the oschema-first migration of
hero_planner_server/_admin/_sdk, the browser web UI (hero_planner_web) was left on the pre-migration RPC scheme, so the live app at/hero_planner/web/is unusable.Observed (screenshot):
workspace.list failed Error: HTTP 404; repeatedrpc/rpc 404; no data renders; shared widget assets 404.Root cause:
main.rsbuildsRPC_URL = {svc_base}/rpc/rpcandOPENRPC_URL = {svc_base}/rpc/openrpc.json(pre-migration paths). The server now serves under/api/{domain}/..., so these 404.index.htmlcalls 31 dotted method names (workspace.list,cost.create,comment.add,currency_rate.upsert, ...) that no longer exist; the migrated server exposes underscore names with_set-upsert semantics.agent-widget.*,voice-widget.*) are served by hero_orchestrator/hero_voice (not running here) — external, noted for completeness.Approach note: per
dioxus_openrpc_client/hero_admin_dioxus, the hand-rolled JS UI is the legacy pattern; intended replacement is a Dioxus/WASM UI using the typed generatedopenrpc_client!. Scope (stopgap vs Dioxus rewrite) TBD.Reconciliation note:
integrationis pre-oschema-migration but is ahead ofdevelopmenton web features — it has commits development lacks, both touching onlyhero_planner_web/src/index.html:ceb9640fix(web): make list search and filter chips actually filter5ced595feat(web): add delete-workspace + currency-rate edit buttonsWhen this migration is done, base it on integration's feature-complete web (re-implement these in the migrated/Dioxus client), not development's stale
index.html.development and integration have forked: dev has the server/admin oschema migration integration lacks; integration has these web features + CI dev lacks — broader reconciliation pending.
Forward-ported integration's web features to
developmentina8e8445(delete-workspace, currency-rate edit, filter-chip fix;index.htmlonly,main.rsuntouched). This migration now starts from a feature-complete web base.The features call dotted RPC names (
workspace.delete,system.counts, …) and will function once this migration remaps the web client to/api/main/rpc+ underscore method names.Chosen path (B -> A):
B - interim remap (first): make the existing feature-complete hand-JS web functional on the new RPC scheme.
main.rs:/rpc/rpc->/rpc/api/main/rpc,/rpc/openrpc.json->/rpc/api/main/openrpc.json.index.html(~25 dotted calls): map to the new oschema surface — underscore names;create/add/new->_set{data};.items->.value; numericid-> composite{workspace_sid}:{id}sid; list ->_list_full; passworkspace_sid.Verify + browser-verify each feature + merge.
A - Dioxus/WASM rewrite (immediate follow-up): rebuild as a Dioxus app using the typed generated
openrpc_client!(perdioxus_openrpc_client/hero_admin_dioxus), modeling on existing Dioxus web apps (hero_biz_app,hero_foundry_web). Starts as soon as B is verified + merged. A planning doc/issue will track A.(Prerequisite — forward-port of integration's web features to development — done in
a8e8445; tracked in #22.)*_list_fullreturns empty for all rootobjects #24B (interim remap) — DONE. Merged to
developmentin7c510a7.The hand-JS web now works against the oschema server via a central translation shim in
rpc()(dotted->underscore, composite{workspace}:{id}sids,_set{data}with per-entity defaults, flattened bare results,list -> _find + _get,workspace_sidscoping).main.rspaths ->/api/main/rpc+/api/main/openrpc.json.Verified via the hero_router tunnel: SWOT + Stories lists, detail (links / comments / costs / revenues),
system_counts, workspace switching/re-scoping, and create+delete via the UI all work; 0 RPC console errors (only external hero_voice/hero_orchestrator widget 404s remain).A (Dioxus/WASM rewrite) — next, per the path above; this issue stays open to track A.
Server-side gaps surfaced during B (filed separately): #24 (
_list_fullempty), #25 (currency_rate delete rowid — data-corruption risk), #26 (system_counts field naming).cargo checkfails: planner_admin askama can't find hero_lib templates #23A (Dioxus rewrite) — planned + de-risked, not yet built.
docs/superpowers/plans/2026-06-14-hero-planner-dioxus-web-rewrite.md(855 lines): two-crate served-SPA mirroringhero_proc_admin_dx(hero_planner_app_dxWASM onhero_admin_lib_dx+ typedopenrpc_client!, served viaserve_admin_dioxus). Not an island.dioxus-cli 0.7.9+wasm32-unknown-unknown, and the referencehero_proc_admin_dx_appbuilds to WASM (dx buildexit 0). So the approach is feasible.a8e8445) must survive the rewrite; the interimlist -> _find + _getshim and the dotted-name translation must be DROPPED (replaced by the typed client) once on Dioxus; currency uses the realCurrencyRate.id(#25, done).