Posts can carry a Photo (IndieWeb photo) backed by a SQLite media store #136
No reviewers
Labels
No labels
kind
bug
kind
enhancement
wayfinder
grilling
wayfinder
map
wayfinder
prototype
wayfinder
research
wayfinder
task
workflow
needs-info
workflow
needs-triage
workflow
ready-for-agent
workflow
ready-for-human
workflow
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rosa/vernier!136
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/post-photo-media"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Implements #131: a Post can carry a single optional Photo (its IndieWeb
photo), uploaded, optimized, and stored as a BLOB in SQLite, served from thisinstance's own origin, and shown at the top of the Post under the byline. Both
the web editor and Micropub can attach one.
Built bottom-up in ten phases, each compiling and independently tested:
Mediamodel +Photo/PhotoRef, threaded throughPostmediatable +photo_media_id/photo_alt, port opsSVG → strip EXIF (orientation applied first) → downscale-only → AVIF
GET /media/{id}at an Unlisted-grade capability URLImageProcessorportPOST /media+ themediascopephoto— create / update /q=source, URL→id resolutionu-photounder the bylinemedia:content+ Atomrel="enclosure"Design change from the ADRs
The stored rendition format is AVIF, not WebP (ADR-0017 and the migration
comment updated to match). The input allowlist still decodes JPEG/PNG/WebP.
Security invariants (all test-covered)
from magic bytes, never the client's
Content-Type.photomay only reference same-origin, author-owned Media — athird-party URL or another author's Media is rejected.
(ADR-0018): a Private Post's Photo is Unlisted-grade, documented and accepted.
Notes
image(default-features off; JPEG/PNG/WebP decode + AVIFencode via
rav1e).cargo auditis clean.since they are the design for this feature.
multipart photo in create, #134 orphan-Media GC, #135 responsive renditions.
Full CI (audit / fmt / yaml / tests) is green.
Closes #131
fc76b7b9260fa975f4580fa975f458243c5d80ca243c5d80ca9f42e0bfa5