LeoVasanko
0ebff0ec17
Preview: simplify pyvips timing to single processing ms + req total.
2026-04-25 00:06:35 +00:00
LeoVasanko
d5ff7757c8
Preview: persistent worker pool, fast AVIF encode, access-log timing
...
- Add preview_worker.py: long-lived subprocess; JSONL request / framed binary
response protocol (BLAKE3 checksum + LE uint32 sizes + msgspec JSON + payload)
- Add _PreviewWorkerPool: asyncio queue-based pool; kill+replace workers on timeout,
checksum error, or protocol error; PREVIEW_TIMEOUT=3s, PREVIEW_WORKERS=cpu-scaled
- Use pyvips effort=0,strip=True for fast AVIF thumbnails; CISTA_PIL=1 env forces Pillow
- Report load/process/save ms in PreviewResponse; inject into access log via req.ctx._log_extra
- Wire start/shutdown_preview_workers into Sanic lifecycle hooks (app.py)
- Call configure_main_logging() after Sanic() to install emoji formatter
- Silence worker stderr (DEVNULL)
2026-04-24 23:53:23 +00:00
LeoVasanko
0190bda853
Avoid useless check.
2026-04-24 00:04:58 +00:00
LeoVasanko
da4bba95be
Handle missing preview files with silent 404
2026-04-23 19:02:54 +00:00
LeoVasanko
ded7ce65bc
Faster image previews by pyvips.
2026-04-23 17:19:24 +00:00
LeoVasanko
0b269aef7f
Set avif=1 flag for SVT-AV1 when encoding a single image, for increased efficiency and less memory usage.
2026-04-23 16:57:27 +00:00
LeoVasanko
f578a50007
Pass the new allocated field through search filtering. Fixes issue where 0 allocated was reported in search results.
2026-02-04 23:55:05 +00:00
LeoVasanko
f40d9c1abd
Cache previews in server RAM for much faster access (they are about 70kB each).
2026-02-04 20:56:16 +00:00
LeoVasanko
036c4342de
Better error logging on preview generation errors.
2026-01-31 22:00:26 +00:00
LeoVasanko
232fd92b22
Finalize Paskia integration and built-in authentication.
2026-01-31 00:47:04 +00:00
LeoVasanko
7be02e951d
Consistent dialog styling widgets and using Paskia's shared backdrop. Internal password auth mimics Paskia. API paths changed (/auth goes to internal or paskia depending on config). All API calls and previews get access checks.
2026-01-30 18:28:05 +00:00
LeoVasanko
442816a0ae
Fix video preview images that were displayed sideways for portrait video. The least bad approach loses HDR but shows in correct orientation. For 0 and 180 degrees we preserve HDR too.
2026-01-22 02:20:39 +00:00
LeoVasanko
0d853032bf
Cleaner handling when preview generation fails. Using original file as fallback.
2026-01-21 23:29:51 +00:00
LeoVasanko
f627890e55
Image previews improved, all EXIF Orientations handled.
2025-08-17 19:00:52 +00:00
LeoVasanko
64de17a74b
Maintenance update ( #7 )
...
- Use modern tooling uv and bun
- Various changes to work with latest PyAV and PIL that have changed their API
- Improved image, video and document previews (uses AVIF, renders AVIF/HEIC/videos in HDR, faster processing)
- Fix a server hang in some cases where a folder was moved or renamed
- Log exceptions instead of only returning 500 response to client
- Log timing of preview generation functions
- Default to quality 50 in previews (previously 40)
2025-08-15 16:03:04 +00:00
LeoVasanko
83bc1bea81
Various build fixes, cleanup and details ( #6 )
...
- Major memory usage reduction in video previews
- Finally builds properly on Windows too
2023-11-21 15:32:49 +00:00
LeoVasanko
d939c1ddbb
Video preview posters
2023-11-19 08:44:46 +00:00
LeoVasanko
66698869d6
Minor changes
2023-11-19 08:03:23 +00:00
LeoVasanko
c72e3d91ee
Added PDF previews. Preview quality configurable. Preview browser caching and cache busting.
2023-11-19 07:16:24 +00:00
LeoVasanko
fb565a95d6
Fix preview images that need rotation
2023-11-19 03:56:16 +00:00
LeoVasanko
c84c570d2e
Implement media preview thumbnails for Gallery
2023-11-19 03:38:25 +00:00