Skip to content

The intro detection fingerprints live on disk under /data/fingerprints, out of the database and its backups - #104

Merged
gravity-zero merged 4 commits into
devfrom
feat/fingerprints-on-disk
Nov 15, 2026
Merged

gravity-zero merged 4 commits into
devfrom
feat/fingerprints-on-disk

Conversation

@gravity-zero

Copy link
Copy Markdown
Contributor

The Chromaprint and pHash fingerprints that intro detection caches per media item made up most of every database backup, while being derived data that is computed again from the media files. They now live in /data/fingerprints/{audio,phash}/<media_id>.fp, beside the other derived per-media stores.

  • Two file stores implement the existing cache ports, so intro detection is unchanged. Writes are atomic (temp file + rename) and every file carries a CRC: a damaged file reads as a miss and is recomputed.
  • At boot, the rows still in the database are copied to disk with their original extraction time and deleted once written. A file already on disk wins, so a row brought back by an older backup never replaces a newer entry.
  • The database used to drop an entry by cascade with its media item. A sweep now removes the files of deleted media at boot and once a day, and removes nothing when the database lookup fails.
  • The backup page says these fingerprints are not part of a backup, in every language.

The two tables are left in place, empty. Dropping them belongs to a later release, once the move has run on existing installs.

@gravity-zero
gravity-zero merged commit 8eb0be9 into dev Nov 15, 2026
11 checks passed
@gravity-zero
gravity-zero deleted the feat/fingerprints-on-disk branch November 15, 2026 22:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant