Thanks to visit codestin.com
Credit goes to github.com

Skip to content

installer-setup WS-D: co-locate [models].flm_store + free-space validation on chosen mount#1132

Merged
thinmintdev merged 1 commit into
mainfrom
feat/1100-flm-store-colocate
Jul 6, 2026
Merged

installer-setup WS-D: co-locate [models].flm_store + free-space validation on chosen mount#1132
thinmintdev merged 1 commit into
mainfrom
feat/1100-flm-store-colocate

Conversation

@thinmintdev

Copy link
Copy Markdown
Contributor

Summary

Closes #1100. Part of the guided Hal0 Installer Setup redesign (Wave 2 / WS-D, decision Q4). Extends #1095's _persist_store_dir() (which threads Selections.storage_dir into [models].store) to also handle the FLM/NPU side of the store:

  • Setting the model store now seeds [models].store and co-locates [models].flm_store at <store>/flm/models (the convention already documented on ModelsConfig.flm_store and used by installer/install.sh), so NPU weights no longer strand on the root filesystem when --models-dir is set.
  • Added a non-fatal writability + free-space check (_validate_store_mount) on the chosen mount: warns (log only, never raises) when the mount isn't writable, sits on the root filesystem, or has less than 10 GiB free — mirroring the ancestor-walk pattern in cli.setup_plan._free_space_gib without importing from it (isolation guardrail — that file is owned by a sibling workstream).
  • Idempotent: skips the rewrite only when both [models].store and the co-located [models].flm_store already match; a config that pre-dates this change (store set, flm_store empty) still gets the co-located value seeded on the next persist.
  • Best-effort per ADR-0010, matching installer-setup WS-A: honor or remove Selections.storage_dir #1095's existing behavior: empty/relative storage_dir values are ignored, and config-write failures are swallowed so a bad pick never aborts the slot/extension walk.

Files changed

No changes needed in src/hal0/config/schema.pyModelsConfig.flm_store (with its absolute-path validator and effective_store-style resolution via config.paths.flm_models_dir) already existed and needed no changes.

Test plan

  • uv run ruff format src tests — clean
  • uv run ruff check src tests — all checks passed
  • uv run ruff format --check src tests — 639 files already formatted
  • uv run pytest tests/install/test_orchestrate.py -q — 20 passed, 1 skipped (host-topology guard skips when tmp and / share a device, e.g. some sandboxes)
  • uv run pytest tests/ -q --ignore=tests/e2e — 4680 passed, 14 failed, 9 skipped, 1 error; confirmed via git stash that the same 14 failures + 1 error pre-exist on main (hermes venv/state-render, comfyui phase4, proxmox host detection, container spec dispatch, config-urls proxy, models-preview, settings-store writability) — unrelated to this change.

🤖 Generated with Claude Code

…ation

Extends #1095's _persist_store_dir to also seed [models].flm_store
co-located under the chosen model store (<store>/flm/models), so NPU/FLM
weights stop stranding on the root FS when --models-dir is set. Adds a
non-fatal writability + free-space check on the chosen mount, warning
(log only) when it's unwritable, on the root filesystem, or below a 10 GiB
threshold — mirrors cli.setup_plan's ancestor-walk pattern without
importing from it, keeping the two workstreams isolated.

Closes #1100

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@thinmintdev thinmintdev merged commit 8d2d017 into main Jul 6, 2026
3 checks passed
@thinmintdev thinmintdev deleted the feat/1100-flm-store-colocate branch July 6, 2026 05:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

installer-setup WS-D: co-locate [models].flm_store + free-space validation on chosen mount

1 participant