diff options
Diffstat (limited to 'CLAUDE.md')
| -rw-r--r-- | CLAUDE.md | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -639,7 +639,19 @@ do. Read them before writing anything that touches the same mechanism. reaches the deployed hub. Symptom: one endpoint answering 500 with an HTML body while everything else works, and a `psycopg` `UndefinedColumn` in the journal. `deploy-hub.sh` runs `alembic upgrade head` before restarting the service; a schema - change that skips a migration file will still pass every test you have + change that skips a migration file used to pass every test there was. + **`test_migrations_reach_head.py` is the one that does not**: it upgrades to head + on SQLite and compares what that built against `Base.metadata`, in both + directions. It could not have existed before 2026-09-13, because + `add_email_verification` wrote PostgreSQL's `(now() at time zone 'utc')` as a + literal server default — a syntax error on SQLite — so the chain could not reach + head on the only database the suite has, and the single test that ran alembic + stopped at the revision before it. The two newest migrations had therefore been + run by exactly one thing: a production deploy. **A server default goes in + `sa.func.now()`**, which the dialect running it renders; a dialect's own SQL + written out by hand is a migration that only one database can apply. What this + still does not check is PostgreSQL-only behaviour — running the chain somewhere + beats running it nowhere and is not the same as running it where it ships - **Some paths only exist in a browser, and only one browser has them.** The download-to-disk story is three different mechanisms — File System Access |