-
Stefy Lanza (nextime / spora ) authored
Two distinct "config goes back to what it was after restart" bugs: 1) save_config dropped broker websocket_path + websocket_ping_interval (and the new offload gpu_split/tensor_split). The settings UI set them in memory, but save_config never serialized them, so the next load() fell back to dataclass defaults — the broker protocol/websocket settings reverted every boot even with a fully persistent config dir. Now serialized. 2) Per-model fields (e.g. n_ctx) reverted via a multi-process models.json write race: every engine loads models.json at its own boot, so a SECONDARY engine's in-memory models_data is stale w.r.t. a later UI edit on the primary. When that secondary engine auto-persisted measured_vram_gb it called save_models(), which dumps its whole stale state and clobbered the edit. Added ConfigManager.persist_model_field(): a single-field, atomic read-modify-write that re-reads models.json from disk, updates only the one field, and refreshes the in-memory copy. record_vram_delta now uses it, so VRAM measurement can never revert user model config. Co-Authored-By:Claude Opus 4.8 <noreply@anthropic.com>
2846a94b