Self-hosted web interface and downloader for Qobuz.

refactor(util,audiotag): canonicalize track identifiers and validate cover images on entry #35

Merged glerp.sullen.net
targeting v1 from glerp.sullen.net/gobuz:refactor/audiotag-entry-validation
Merged opened by and assigned to glerp.sullen.net
targeting v1 from glerp.sullen.net/gobuz:refactor/audiotag-entry-validation

Canonicalizes track identifier tags and validates embedded cover headers once at internal/audiotag entry, branched directly off upstream/v1:

  • internal/util: Folds barcode.go into identifier.go (NormalizeUUID, NormalizeISRC, NormalizeGTIN, CalculateCheckDigit with NormalizeGTIN logic unchanged from upstream/v1), renames formatutil.go -> format.go and httputil.go -> http.go, and adds ExtractYear.
  • internal/audiotag: Canonicalizes MBRecordingID, MBReleaseID, MBReleaseGroupID, ISRC, Year, and FilePath once in ReadTrack, renames *Ext helpers to IsAudioExtension / IsBrowserStreamableExtension / IsCoverExtension, and adds header-only JPEG/PNG ValidateCover in ReadCover.
Commits 1

refactor(util,audiotag): canonicalize track identifiers and validate cover images on entry