Complete local metadata parsing with disc numbers
- Dominant language
- Dart
- Stars
- 63
- Forks
- 8
- Avg merge
- 7h 48m
- Merged PRs (30d)
- 136
Description
## Overview
Local metadata parsing is now largely implemented: Linthra reads title, artist, album artist, album, track number, duration, and embedded artwork for user-selected local music through Android's Storage Access Framework, with filename/folder fallbacks when tags are missing.
The remaining gap from the original issue is **disc number** support so multi-disc albums can be ordered and grouped correctly.
## What needs to be done
- [ ] Read disc number from local audio metadata when present
- [ ] Carry the disc number through `LocalAudioMetadata` and the local track mapping path
- [ ] Preserve the existing fallback behaviour when the tag is missing or malformed
- [ ] Add tests for multi-disc files and missing/partial disc metadata
- [ ] Keep file access SAF-scoped; do not add broad storage permission
## Goal
Local multi-disc albums preserve their disc ordering while keeping the metadata parsing and privacy model already shipped in Linthra.
## Already implemented
- [x] Title
- [x] Artist
- [x] Album artist
- [x] Album
- [x] Track number
- [x] Duration
- [x] Embedded artwork
- [x] Graceful filename/folder fallbacks
- [x] Scoped Storage Access Framework access
See `lib/core/sources/local/` and the Android SAF scanner for the current implementation.
Contributor guide
Research direction
Start by tracing the local metadata implementation under lib/core/sources/local/ and the Android Storage Access Framework scanner. Follow the existing track-number mapping path to see where disc metadata should travel, then add coverage for multi-disc files and missing or partial tags. Done means disc ordering is preserved, malformed tags retain current fallbacks, and SAF-scoped access remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, dart
- Domain
- mobile-dev
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100