Spaces:
Runtime error
Runtime error
Commit History
-
fix(deploy): make alembic failure fatal so the error stops being silent
BIM Query Deploy +1: Claude Opus 4.7 (1M context)The 'alembic upgrade head || { WARNING; continue }' pattern hid the real migration failure behind a healthy-looking app that then 500'd on the first request with 'relation projects does not exist'. Now the container refuses to start without a clean migration, and the postgres.log tail is dumped to stderr to make the cause visible in the HF Space build log. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>035fe5e -
fix(deploy): use unix socket for bootstrap psql (trust auth)
BIM Query Deploy +1: Claude Opus 4.7 (1M context)initdb sets --auth-local=trust + --auth-host=md5 and never writes a password for the postgres superuser, so TCP psql -h 127.0.0.1 fails with 'password authentication failed for user postgres'. The unix socket at /tmp uses local auth (trust), which is what we want for in-container bootstrap. The application itself still connects over TCP using the bim user (POSTGRES_HOST=localhost), and the bim role has a password set via CREATE ROLE during this bootstrap — that path keeps working. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>55f0196 -
fix(deploy): postgres startup robustness on HF Spaces
BIM Query Deploy +1: Claude Opus 4.7 (1M context)- Move unix socket to /tmp (default /var/run/postgresql is not writable for uid 1000 on HF Spaces). - Drop memory tunables: shared_buffers 256MB→64MB, work_mem 16MB→4MB, max_connections 50→20. /dev/shm in HF containers is typically ~64MB, which is what was almost certainly blocking startup. - huge_pages = off and dynamic_shared_memory_type = posix (explicit defaults that some restricted container runtimes override). - Surface postgres.log on pg_ctl failure so the next iteration gets a real error message instead of "Examine the log output". Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>42d2a35 -
deploy: initial BIM Query API on Hugging Face Spaces
BIM Query Deploy +1: Claude Opus 4.7 (1M context)Containerised FastAPI + Celery worker/beat behind supervisord, with Postgres 15 + pgvector running in-container (started by entrypoint.sh, data ephemeral in /tmp/pgdata). External managed services configured via Space secrets: - Upstash Redis (broker + L2 cache) - Cloudflare R2 (S3-compatible IFC storage) - Groq (LLM intent classification) - Supabase (JWT verification only — auth happens in the frontend) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>e6be672