Clips aren't counted as versions, which was intended, but it means a photo whose only derived file is a clip looked like a plain photo. FileViewer only fetches /image/versions for photos with photo_version_counts > 0, so it never saw the clip.
PhotoVersionSummary gains clip_count, counted the same way as versions (live rows only), restricted to CLIP_KINDS. Photos with only clips now get a summary too.
/photos: a new parallel array, photo_clip_counts.
Records (memories, search hits, /photos/exif): a new clip_count field.
Everything is skipped when zero, so responses without clips are byte-identical.
CLAUDE.md is updated.
Testing
cargo test --lib (DATABASE_URL=:memory:): 1063 pass.
The end-to-end clip test now also asserts photo_clip_counts: [1] with no photo_version_counts.
The VersionFields serialisation test covers the clips-only case.
Follow-up to #209 (part of #208).
Clips aren't counted as versions, which was intended, but it means a photo whose only derived file is a clip looked like a plain photo. FileViewer only fetches `/image/versions` for photos with `photo_version_counts > 0`, so it never saw the clip.
- `PhotoVersionSummary` gains `clip_count`, counted the same way as versions (live rows only), restricted to `CLIP_KINDS`. Photos with only clips now get a summary too.
- **`/photos`:** a new parallel array, `photo_clip_counts`.
- **Records** (memories, search hits, `/photos/exif`): a new `clip_count` field.
- Everything is skipped when zero, so responses without clips are byte-identical.
- CLAUDE.md is updated.
## Testing
- `cargo test --lib` (`DATABASE_URL=:memory:`): 1063 pass.
- The end-to-end clip test now also asserts `photo_clip_counts: [1]` with no `photo_version_counts`.
- The `VersionFields` serialisation test covers the clips-only case.
- fmt and clippy are clean.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Derived clips (#208) aren't counted as versions, so a photo whose only
derived file is a clip looked like a plain photo, and clients never fetched
/image/versions for it. Summaries now carry clip_count: /photos adds the
parallel array photo_clip_counts, records (memories, search, /photos/exif)
carry clip_count. All skipped when zero, so other responses are unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cameron
merged commit f121457c43 into master2026-11-02 00:54:24 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Follow-up to #209 (part of #208).
Clips aren't counted as versions, which was intended, but it means a photo whose only derived file is a clip looked like a plain photo. FileViewer only fetches
/image/versionsfor photos withphoto_version_counts > 0, so it never saw the clip.PhotoVersionSummarygainsclip_count, counted the same way as versions (live rows only), restricted toCLIP_KINDS. Photos with only clips now get a summary too./photos: a new parallel array,photo_clip_counts./photos/exif): a newclip_countfield.Testing
cargo test --lib(DATABASE_URL=:memory:): 1063 pass.photo_clip_counts: [1]with nophoto_version_counts.VersionFieldsserialisation test covers the clips-only case.🤖 Generated with Claude Code