mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-09-21 03:01:27 -03:00
e14a084f0d
Installing a second LoRA Manager instance (standalone or a second ComfyUI install) that shares the settings directory puts two processes on the same cache databases. Three things made that unsafe. - The updater preserved cache/ and model_cache/ but not a legacy recipe_cache/ directory, so a portable install predating the cache/ move lost its recipe database on a git-based update. Add it to _PRESERVE_DIRS and to .gitignore. - Cache connections used the sqlite3 default 5s timeout, which a scanning instance can exceed, turning a concurrent write into "database is locked". Route every shared cache connection through connect_cache_db(), which raises the timeout to 30s and sets busy_timeout + synchronous=NORMAL to match the existing WAL mode. App-private databases (download queue, update history) are unchanged. - A full-table cache replace is a read-modify-write that SQLite cannot make atomic across processes, so two instances could interleave and one snapshot could overwrite the other. Guard the recipe and model save_cache paths with a cross-process advisory lock (flock on POSIX, msvcrt on Windows). Locking is best-effort: if it is unavailable the call proceeds and the SQLite busy timeout is the fallback. The lock file is a hidden sibling of the database and is deliberately never unlinked, so a second process cannot lock a fresh inode.
45 lines
695 B
Plaintext
45 lines
695 B
Plaintext
__pycache__/
|
|
.pytest_cache/
|
|
settings.json
|
|
path_mappings.yaml
|
|
output/*
|
|
py/run_test.py
|
|
.vscode/
|
|
cache/
|
|
civitai/
|
|
stats/
|
|
wildcards/
|
|
backups/
|
|
logs/
|
|
node_modules/
|
|
coverage/
|
|
.coverage
|
|
model_cache/
|
|
recipe_cache/
|
|
|
|
# agent / dev tooling
|
|
.opencode/
|
|
.claude/
|
|
.sisyphus/
|
|
.codex
|
|
.omo
|
|
reasonix.toml
|
|
.reasonix/
|
|
.codegraph/
|
|
.playwright-mcp/
|
|
|
|
# Vue widgets development cache (but keep build output)
|
|
vue-widgets/node_modules/
|
|
vue-widgets/.vite/
|
|
vue-widgets/dist/
|
|
|
|
# Hypothesis test cache
|
|
.hypothesis/
|
|
|
|
# Working/research notes (not committed)
|
|
.docs/
|
|
|
|
# HF enrichment validation baseline snapshots (contain potentially
|
|
# NSFW README content fetched from community model repos)
|
|
tests/enrich_hf_validation/baselines/
|