← Session 10 — Website planning + local dashboard build
**Verdict: no, the webserver does not block any research file — proven, not just by design.**
**Empirical test** (`web/lockcheck.py`, committed `98dcd67`): 24 seconds of 4 concurrent threads hammering all 15 heavy pages (dashboard, big CSV charts, derivations, conversations, live logs) while simultaneously:
- Taking **120 SQLite write locks** on `research.db` and `agent.db` (`BEGIN IMMEDIATE` → `ROLLBACK`, so zero bytes written)
- Opening **360 write-intent handles** (`r+`) on STATE.md, NGUYEN.md, E-023 CSV, a derivation, a run-log, and a journal file
Result: **zero failures, zero stalls** — every write attempt succeeded instantly while the site was serving.
**Why it's safe by construction:**
1. Text files are read with Python `open(..., 'r')` — Windows share mode explicitly *allows* other processes to write concurrently; handles close within milliseconds.
2. Both SQLite DBs are opened `mode=ro` per query and closed immediately — a read lock exists only during each SELECT, never held between requests.
3. Server runs `--noreload` — Django's autoreloader (which holds file watchers on code) is off.
4. `git log` is read-only plumbing, takes no locks.
The guarantees and the test procedure are documented in RH-WEBSITE.md §6.5, and `lockcheck.py` stays in the repo so you (or I, at any session start) can re-verify anytime: `./.venv/Scripts/python.exe web/lockcheck.py`.
raw content_json (database row)
[{"type":"text","text":"**Verdict: no, the webserver does not block any research file — proven, not just by design.**\n\n**Empirical test** (`web/lockcheck.py`, committed `98dcd67`): 24 seconds of 4 concurrent threads hammering all 15 heavy pages (dashboard, big CSV charts, derivations, conversations, live logs) while simultaneously:\n- Taking **120 SQLite write locks** on `research.db` and `agent.db` (`BEGIN IMMEDIATE` → `ROLLBACK`, so zero bytes written)\n- Opening **360 write-intent handles** (`r+`) on STATE.md, NGUYEN.md, E-023 CSV, a derivation, a run-log, and a journal file\n\nResult: **zero failures, zero stalls** — every write attempt succeeded instantly while the site was serving.\n\n**Why it's safe by construction:**\n1. Text files are read with Python `open(..., 'r')` — Windows share mode explicitly *allows* other processes to write concurrently; handles close within milliseconds.\n2. Both SQLite DBs are opened `mode=ro` per query and closed immediately — a read lock exists only during each SELECT, never held between requests.\n3. Server runs `--noreload` — Django's autoreloader (which holds file watchers on code) is off.\n4. `git log` is read-only plumbing, takes no locks.\n\nThe guarantees and the test procedure are documented in RH-WEBSITE.md §6.5, and `lockcheck.py` stays in the repo so you (or I, at any session start) can re-verify anytime: `./.venv/Scripts/python.exe web/lockcheck.py`."}]