baseUrl field is the recovery path when a phone cannot reach the default engine.
Quick Start
1
Open Settings from the top bar
The Settings screen renders one editable row per
value setting. On a fresh phone install, the Engine address field shows the default http://127.0.0.1:8765 β the phone itself, which nothing answers.2
Change the Engine address
Edit Engine address to a reachable host β your dev machine on the LAN, for example:
3
Blur the field or press Enter
The write commits on
change, not per keystroke. On blur or Enter the value is validated, then persisted through facade.set.4
Relaunch
The app boots against the new address. A persisted
baseUrl is read by enginesFor at boot and outranks the compiled-in default.How It Works
Everyvalue row is an editable control wired to the same pure validateInput the store would run.
The four input paths and their outcomes:
Configuration Options
SETTING_DEFS ships exactly two editable settings today (source: app/src/registry.ts).
The storeβs coercion and validation machinery stays intact for any future setting, but only
engineId and baseUrl are read by the shipping app today. See Storage & Secrets β Shipped defaults are valid.Common Patterns
Recover from an unreachable engine on a phone β the golden path this change unblocks.Best Practices
Refuse at the field, not in the store
Refuse at the field, not in the store
validateInput runs before set, so an invalid input is rejected at the input rather than accepted into the UI and dropped by set. The screen never offers a value the store then silently refuses.Persist commits on blur/Enter
Persist commits on blur/Enter
The control listens on
change, not input, so a half-typed address is never stored and set is not hit per keystroke.Reset from the store, not from the last-seen value
Reset from the store, not from the last-seen value
The field resets to
settings.get(key) ?? def.default, so a value that never persisted cannot linger in memory. A rolled-back write leaves the field showing what the next launch will actually read.Never call the settings screen a secrets UI
Never call the settings screen a secrets UI
SettingsFacade has no getSecret; secret rows stay presence-only. Editing a secret from the Settings screen is not possible β rotate secrets through SecretsPort. See Storage & Secrets.Related
Storage & Secrets
The persist-before-mutate contract behind
set.Errors & Recovery
Where an unreachable engine routes the user.
Engines
How
engineId and baseUrl pick and reach an engine.Boot Failures
The warning notice a phone sees before editing the address.

