fix: NetEase source tagging + lossless quality, and lyrics-card extended Unicode glyphs#2442
Merged
Merged
Conversation
… glyphs NetEase library sync (#2431): - syncUnifiedLibrarySongsFromNetease() built SongEntity without sourceType, so rows defaulted to SourceType.LOCAL. NetEase tracks showed up in the local media library, the incremental-sync deletion diff was a no-op (getAllNeteaseSongIds filters source_type=2), and logout cleanup via clearAllNeteaseSongs deleted nothing. Now set sourceType = NETEASE and artistsJson, matching the SyncWorker path. - getSongUrl defaulted to "exhigh" with no lossless tier, so SVIP accounts were capped to lower quality. Default to "lossless" and fall back through exhigh/higher/standard so non-privileged accounts still resolve a URL. Lyrics card glyphs (#2427): - Extended Unicode glyphs (e.g. Icelandic æ ð þ) rendered as tofu because the lyrics text used the bundled Google Sans Rounded variable font, which drops those codepoints at runtime. Render lyrics with the platform default font (fontFamily = null), which has full Latin Extended coverage.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Combined fix for two unrelated bugs.
#2431 — NetEase Cloud Music sync
Songs miscategorized as local + broken playlist/cleanup sync.
NeteaseRepository.syncUnifiedLibrarySongsFromNetease()built itsSongEntityrows withoutsourceType, so they defaulted toSourceType.LOCAL(0). Consequences:source_type).getAllNeteaseSongIds()filterssource_type = 2and the repo rows were0— so playlists never reconciled.clearAllNeteaseSongs()) deleted nothing for the same reason.Every other source repo (Navidrome / GDrive / QQ / Jellyfin) sets
sourceType, and theSyncWorkerNetEase path already set bothsourceTypeandartistsJson; only this repository copy omitted them. Now fixed to match.Quality capped despite SVIP.
getSongUrl()defaulted to"exhigh"with a fallback set ofhigher/standard— no lossless tier was ever requested, so SVIP accounts could not get FLAC. The API already mapslevel=lossless→encodeType=flac. Default is now"lossless"with a graceful fallback chainlossless → exhigh → higher → standard, so non-privileged accounts still resolve a URL.#2427 — Extended Unicode glyphs missing in Lyrics Card
Glyphs like Icelandic
æ,ð,þrendered as tofu (□) in the lyrics card. The lyrics text used the bundled Google Sans Rounded variable font, which drops those codepoints at runtime. The lyrics text style now uses the platform default font (fontFamily = null), which has full Latin Extended coverage.Verification
./gradlew :app:compileDebugKotlin— BUILD SUCCESSFUL.level=lossless → flacAPI mapping are verified statically.Follow-up (not in this PR)
NeteaseRepository.syncUnifiedLibrarySongsFromNetease()and the NetEase block inSyncWorkerduplicate the song→entity mapping and had drifted — that drift is what caused the #2431 miscategorization. Worth consolidating into one shared mapper so they cannot diverge again.Closes #2431
Closes #2427