[nu-demo] service_install_all ends with no running services — registers action defs but doesn't call service.set, so hero_proc service start returns 'service not found' #167
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?
Symptom
After a successful
service_install_all --updaterun (20/20 services "succeeded"), binaries are installed under~/hero/bin/, action definitions are registered in hero_proc viaaction.setRPC, but no services exist in the hero_proc service table:Individual actions ARE there:
Root cause
hero_proc has a two-layer model:
action.set) — individual process specs (env, script, health_check).service.set) — groups of actions that get started/stopped together.The nu-shell modules
service_<name>.nucallproc action setto register action specs. They SHOULD also callproc service setwith a ServiceConfig record{context_name: "core", service: {name, actions: [...], class, description}}to group those actions under a named service.Looking at e.g.
service_osis.nu:The
svc_service_configcall IS there inservice_osis.nu. But on a fresh herodemo VM runningpackages.nu::service_install_all, the services table stays empty — meaning theservice.setcall is either silently failing, or the per-module install closure isn't reaching that line, or the install helpers on this branch skip it.Needs source audit per-service module.
Demo workaround (applied on herodemo 2026-04-24)
Wrote
/data/home/driver/herodemo_set_services.pythat iterates all action prefixes (hero_agent → [hero_agent_server, hero_agent_ui], hero_embedder → [hero_embedderd, hero_embedder_server, hero_embedder_ui], etc.) and POSTsservice.setRPC for each with the correct class (user for hero_agent/books/embedder, system for the rest).Result: 24 services created, all start cleanly via
hero_proc service start <name>.Proposed fix
service_<name>.numodule to ensure it callsproc service setwith a proper ServiceConfig afterproc action set.service_install_allon a fresh VM,hero_proc service listreturns ≥20 services, andhero_proc service start hero_routersucceeds.lib.nu::svx_standard_install_flowso every service module gets it for free without per-module boilerplate.Related
make demoone-shot target (blocks on this)Signed-off-by: mik-tf
Resolved by
lhumina_code/hero_skills@7c823d1(PR lhumina_code/hero_skills#126).Part of Phase 2 tracker #185.