JSON to YAML configuration migration
PHOS uses YAML as its only supported runtime configuration format. Normal PHOS startup never reads, converts, or overwrites a JSON configuration file.
For an older installation that still has phos.json, stop PHOS and run the
explicit one-time migration from the checkout:
PYTHONPATH=src .venv/bin/python tools/migrate_phos_json_to_yaml.py \
config/phos.json config/phos.yaml
The destination must not already exist. The tool validates the complete source
document through RuntimeConfig, preserves configuration-relative paths at the
new YAML location, writes atomically, and leaves the original JSON source in
place as the backup. Correct any reported validation error before starting
PHOS with the new YAML file:
PYTHONPATH=src .venv/bin/python -m robot.main --config config/phos.yaml
JSON remains in PHOS API, MCP, and phos-hw JSON Lines protocol contracts;
this migration applies only to the runtime configuration file.
run_pi.sh is a site-specific development deployment utility, not the official
end-user installer. It seeds config/phos.yaml only when none of
phos.yaml, phos.yml or phos.json exists at the destination. Therefore a
destination with only phos.yml or phos.json can be left without the
phos.yaml selected by deploy/phos.service; the helper does not migrate or
validate those files. It also does not install dependencies or restart PHOS.
The explicit migration command above is available when the JSON source and PHOS
checkout are together at the command location. No verified remote workaround
for the development helper's JSON-only or YML-only destination case is recorded.