diff --git a/backend/src/cyclone/db.py b/backend/src/cyclone/db.py index a64f9c2..f6ff401 100644 --- a/backend/src/cyclone/db.py +++ b/backend/src/cyclone/db.py @@ -2,9 +2,10 @@ `init_db()` is called from `cyclone.__main__:serve` before uvicorn starts. It reads `CYCLONE_DB_URL` (default `sqlite:///~/.local/share/cyclone/cyclone.db`), -creates the engine, runs `Base.metadata.create_all`, then runs the migration -runner. Calling `init_db()` is idempotent — calling it twice on the same URL -re-uses the same engine. +creates the engine, runs the migration runner, then runs `Base.metadata.create_all` +as a safety net (which is a no-op when the migration is current). Calling +`init_db()` is idempotent — calling it twice on the same URL re-uses the +same engine. """ from __future__ import annotations