• Stefy Lanza (nextime / spora )'s avatar
    config: stop settings reverting on reboot (broker save omission + models.json write race) · 2846a94b
    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: 's avatarClaude Opus 4.8 <noreply@anthropic.com>
    2846a94b
Name
Last commit
Last update
codai Loading commit data...
docs Loading commit data...
packaging Loading commit data...
samples Loading commit data...
tests Loading commit data...
tools Loading commit data...
.dockerignore Loading commit data...
.gitignore Loading commit data...
AI.PROMPT Loading commit data...
CODERAI_API_DOCUMENTATION.md Loading commit data...
CoderAI.gif Loading commit data...
DISTRIBUTION.md Loading commit data...
LICENSE.md Loading commit data...
MULTIMODAL_CAPABILITIES.md Loading commit data...
MULTIMODAL_UI_EXAMPLES.md Loading commit data...
README.md Loading commit data...
build-oci.sh Loading commit data...
build.ps1 Loading commit data...
build.sh Loading commit data...
coderai Loading commit data...
coderai-broker-implementation-reference.md Loading commit data...
coderai-integration.md Loading commit data...
commands Loading commit data...
osxbuild.sh Loading commit data...
package-oci.sh Loading commit data...
package-tarball.sh Loading commit data...
requirements-nvidia.txt Loading commit data...
requirements-vulkan.txt Loading commit data...
requirements.txt Loading commit data...
run-oci.sh Loading commit data...
smoke-test-oci.sh Loading commit data...
todo.md Loading commit data...
video_editor.config.json Loading commit data...