ulysses/services
Giuseppe Castelluccio 6c9a16a7a8
fix: search analytics FileHandler crashes on startup writing to read-only image layer (#2366)
* fix: move search analytics log to writable /app/logs volume

services/search/analytics.py opened a FileHandler at module import
time pointing to /app/services/search_engine_error.log — inside the
container image's read-only layer. The process runs as non-root so
the open() fails with PermissionError, crashing uvicorn before it
ever binds. ANALYTICS_FILE had the same problem.

Both paths now point to /app/logs (bind-mounted from the host data
directory). The FileHandler creation is wrapped in try/except so a
missing mount doesn't hard-crash on import.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: derive log dir from DATA_DIR instead of hardcoded /app/logs

Fixes reviewer feedback on #2366: /app/logs only exists inside Docker,
so native runs couldn't write the analytics file. DATA_DIR resolves to
the repo's data/ directory on native and /app/data (writable mount) in
Docker, making both the error log handler and ANALYTICS_FILE work on
every platform.

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-07 19:26:22 +02:00
..
docs fix: docs RAG query crashes on a non-dict row from the index (#1706) 2026-06-03 13:35:01 +09:00
faces Odysseus v1.0 2026-05-31 23:58:26 +09:00
hwfit fix(hwfit): detect NVIDIA GPU on WSL and other minimal-PATH environments (#3306) 2026-06-07 17:53:49 +02:00
memory fix(skills): tolerate a stray brace before the JSON in skill extraction (#2200) 2026-06-07 16:54:36 +02:00
research fix: services research lists junk no-content pages as cited sources (#1669) 2026-06-03 14:22:58 +09:00
search fix: search analytics FileHandler crashes on startup writing to read-only image layer (#2366) 2026-06-07 19:26:22 +02:00
shell fix: use running loop for shell stream deadlines (#1694) 2026-06-03 13:37:46 +09:00
stt STT: clean temp audio files on transcription failure 2026-06-02 20:43:24 +09:00
tts fix(tts): tolerate a malformed tts_speed instead of 500-ing (#1450) 2026-06-03 14:12:03 +09:00
youtube fix: extract_youtube_id crashes on a non-string url instead of returning None (#1689) 2026-06-03 13:38:11 +09:00
__init__.py Odysseus v1.0 2026-05-31 23:58:26 +09:00