feat(media,api): face scope-crop thumbnails (spec 052 T001+T002) #1059

Merged
chris merged 2 commits from fix/face-scope-crop-backend into main 2026-10-07 08:46:26 +02:00
Owner

Spec 052: media worker derives per-face scope crops (bbox + Vis-område context, scopeCropFit-equivalent geometry) as face_scope_thumbnail; idempotent version-gated enqueue + periodic backfill; faces thumbnail endpoint gains crop=scope serving ONLY scope assets — missing asset is 404 (client owns the fallback; framing never silently changes to tight). Authz CTE unchanged. Version 1.21.71. Merge before web PR #1058.

Spec 052: media worker derives per-face scope crops (bbox + Vis-område context, scopeCropFit-equivalent geometry) as face_scope_thumbnail; idempotent version-gated enqueue + periodic backfill; faces thumbnail endpoint gains crop=scope serving ONLY scope assets — missing asset is 404 (client owns the fallback; framing never silently changes to tight). Authz CTE unchanged. Version 1.21.71. Merge before web PR #1058.
feat(media,api): face scope-crop thumbnails (spec 052 T001+T002)
All checks were successful
Wiki Sync / Sync wiki from docs (push) Has been skipped
Build and Deploy / Detect changed services and test scopes (push) Successful in 2s
Build and Deploy / Android unit tests and debug APK (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Smoke people worker (push) Has been skipped
Build and Deploy / Build postgres image (push) Has been skipped
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Deploy postgres (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Successful in 1m52s
1d4b318ea1
Worker: new generate_face_scope_thumbnail job rendering a square scope crop
that mirrors apps/web scopeCropFit (margin 1.01, maxZoom 32, tile aspect 1)
via FaceScopeCrop; degenerate/missing bbox and non-photo media issue instead
of burning a crop.

API: idempotent, version-gated face-scope-thumbnail-v1 enqueue + periodic
backfill; acceptFaceScopeThumbnail result promotion (no tight-crop pointer
touch); crop=scope on the face thumbnail endpoint preferring
face_scope_thumbnail with tight-crop fallback; absent/unknown crop param keeps
exact prior behavior and the authz CTE is unchanged.

Capabilities wired through WorkerProperties/application.yml/compose,
JobEventsService, ProcessingActivityLanes, WorkerCredentialBootstrap,
MediaMaintenanceService. Version 1.21.71. Spec 052 T001/T002 -> done.
fix(api): crop=scope returns 404 instead of tight-crop fallback (spec 052 contract)
All checks were successful
Wiki Sync / Sync wiki from docs (push) Has been skipped
Build and Deploy / Detect changed services and test scopes (push) Successful in 3s
Build and Deploy / Android unit tests and debug APK (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Smoke people worker (push) Has been skipped
Build and Deploy / Build postgres image (push) Has been skipped
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Deploy postgres (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Successful in 1m49s
96594ede0b
Orchestrator contract decision: a missing face_scope_thumbnail must surface
as 404 so the web client falls back to its whole-photo CSS-zoom path —
silently serving the tight crop would change the framing mid-deployment
(the pre-upgrade API ignores the crop param entirely, same hazard). Simplifies
faceThumbnail to a single row lookup; spec 052 S3 amended accordingly.
chris merged commit a9e8ffcf88 into main 2026-10-07 08:46:26 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
chris/memories!1059
No description provided.