jcorporation / myMPD

myMPD is a standalone and mobile friendly web mpd client with a tiny footprint and advanced features.
https://jcorporation.github.io/myMPD/
GNU General Public License v3.0
419 stars 65 forks source link

Lyrics again #683

Closed Hajuskin closed 2 years ago

Hajuskin commented 2 years ago

myMPD version: 9.1.2 devel

Describe the bug

In previous versions (haven't checked when it stoped working) you could chose between different lyrics (embedded synced or unsynced, probably also external lyrics, haven't tested that). Now if a song has embedded synced and unsynced lyrics, only the synced were displayed. The log states that no unsynced lyrics were found, but the file has both, synced and unsynced lyrics embedded.

Log:

INFO     mympdapi  MYMPD API request (38)(0) MYMPD_API_LYRICS_GET: {"jsonrpc":"2.0","id":0,"method":"MYMPD_API_LYRICS_GET","params":{"uri":"MP3 Selection/B/Bruce Springsteen/1973 - Greetings From Asbury Park, N.J/01 Blinded By The Light.mp3"}}
DEBUG    mympdapi  Trying to open lyrics file: /music/MP3 Selection/B/Bruce Springsteen/1973 - Greetings From Asbury Park, N.J/01 Blinded By The Light.lrc
DEBUG    mympdapi  No lyrics file found in music directory
DEBUG    mympdapi  Exctracting synced lyrics from /music/MP3 Selection/B/Bruce Springsteen/1973 - Greetings From Asbury Park, N.J/01 Blinded By The Light.mp3
DEBUG    mympdapi  Sylt encoding: 0
DEBUG    mympdapi  Synced lyrics successfully extracted
DEBUG    mympdapi  Trying to open lyrics file: /music/MP3 Selection/B/Bruce Springsteen/1973 - Greetings From Asbury Park, N.J/01 Blinded By The Light.txt
DEBUG    mympdapi  No lyrics file found in music directory
DEBUG    mympdapi  Exctracting unsynced lyrics from /music/MP3 Selection/B/Bruce Springsteen/1973 - Greetings From Asbury Park, N.J/01 Blinded By The Light.mp3
DEBUG    mympdapi  No embedded unsynced lyrics detected
DEBUG    mympdapi  Push response to web_server_queue for connection 38: {"jsonrpc":"2.0","id":0,"result":{"method":"MYMPD_API_LYRICS_GET","data":[{"synced":true,"encoding":0,"lang":"eng","timestamp":2,"contenttype":1,"desc":"","text":"[00:20.600]Madman drummers bummers\n[00:22.430]and indians in the summer\n[00:24.370]with a teenage diplomat\n[00:27.930]In the dumps with the mumps\n[00:29.930]as the adolescent pumps\n[00:31.870]his way into his hat\n[00:35.760]With a boulder on my shoulder\n[00:38.160]feelin' kinda older\n[00:39.910]i tripped the merry-go-round\n[00:43.540]With this very unpleasing\n[00:45.910]sneezing and wheezing\n[00:47.600]the calliope crashed to the ground\n[00:51.290]Some all-hot half-shot\n[00:53.480]was headin' for the hot spot\n[00:55.480]snappin' his fingers clappin' his hands\n[00:58.240]And some fleshpot mascot\n[01:00.870]was tied into a lover's knot\n[01:02.930]with a whatnot in her hand\n[01:05.800]And now young scott with a slingshot\n[01:08.690]finally found a tender spot\...

If a file has only unsynced lyrics, they are displayed but with "undefined" added to the first line: 2022-02-13_010117

jcorporation commented 2 years ago

I can not reproduce your issue with my lyrics testfiles. Can you provide a testfile?

Hajuskin commented 2 years ago

Yes sure 🙂 testfile.zip only_unsynced.zip

[edit] The first has synced and unsynced lyrics embedded, the second only unsynced.

jcorporation commented 2 years ago

The undefined phrase for unsynced lyrics was an error removing windows line endings. This is fixed. Sure that the other file contains synced + unsynced lyrics? Neither kid3 nor eyeD3 shows unsynced lyrics.

Hajuskin commented 2 years ago

Sure that the other file contains synced + unsynced lyrics? Neither kid3 nor eyeD3 shows unsynced lyrics.

I was sure, but I was wrong 😂 I sync my music with MusicBee to my raspberry and it seems that MusicBee preferes synced lyrics over unsynced and copies only them. Sorry for that!