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
418 stars 65 forks source link

Embedded covers do not show in WSL #277

Closed parkmino closed 4 years ago

parkmino commented 4 years ago

myMPD version: 6.4.1

Describe the bug

When mympd runs in Windows 10 WSL1 (Windows Subsystem for Linux) with mpd.exe, embedded covers are not available.

To Reproduce

  1. In Windows 10, run "mpd mpd.conf"
  2. In WSL, run "sudo mympd"
  3. Open "Browse > Covergrid"

Expected behavior

It shows embedded covers as well as external covers.

Server plattform (please complete the following information):

Client plattform (please complete the following information):

Debug logs (please attach if it can be usefull)

mympd.log

Additional context

FYI, music directories are different between mpd in Windows (d:\Music) and mympd in WSL (/mnt/d/Music).

jcorporation commented 4 years ago

DEBUG /build/mympd-syQ4gK/mympd-6.4.1/src/web_server/web_server_albumart.c:194: Mimetype of /mnt/d/Music//Various Artists - [멜론] 2020년 05월 09일 TOP100 (320Kbps)/090 HYNN (박혜원) - 시든 꽃에 물을 주듯.MP3 is application/octet-stream

This was the problem. myMPD does not detect the mime type of your music file, because the extension is all upper case. I fixed it quickly in devel, can you give it a try?

parkmino commented 4 years ago

Now it shows "ERROR Can't parse id3_file: /mnt/d/Music//Various Artists..."

parkmino commented 4 years ago

Hmm... I changed one of the file extensions to lower case. Some files show covers while others don't.

parkmino commented 4 years ago

After initializing, it works fine. Thanks a lot!

mympd

parkmino commented 4 years ago

After rebooting, db update is needed to show embedded covers. Is there any way to figure it out?

jcorporation commented 4 years ago

Please enable debug and attach the log of myMPD and MPD.

parkmino commented 4 years ago

Please find the attached file for mympd log.

mympd.log

mpd.log is quite simple as attached. Should I download debug version for this?

mpd.log

jcorporation commented 4 years ago

For MPD set log level to verbose. But the myMPD log is sufficient.

ERROR /build/mympd-5yEJ8Y/mympd-6.4.2/src/web_server/web_server_albumart.c:225: Can't parse id3_file: /mnt/d/Music//Various Artists - [멜론] 2020년 05월 09일 TOP100 (320Kbps)/069 Maroon 5 - Memories.MP3

This error is thrown if id3_file_open can not open or parse the file.

parkmino commented 4 years ago
  1. No problem with browse function, only embedded covers are broken.
  2. I removed "/" at the end, however it points out the same directory "/mnt/d/Music//.." in error message.
jcorporation commented 4 years ago

You changed it in the web ui in the connection dialog?

A ls /mnt/d/Music//Various Artists - [멜론] 2020년 05월 09일 TOP100 (320Kbps)/069 Maroon 5 - Memories.MP3 works as myMPD user?

parkmino commented 4 years ago

No, I edited musicdirectory in /etc/mympd.conf

jcorporation commented 4 years ago

No, I edited musicdirectory in /etc/mympd.conf

Web UI overrides this setting.

parkmino commented 4 years ago

I changed it in web browser and duplicated slashes are gone. However it shows error message as following and no embedded covers.

ERROR Can't parse id3_file: /mnt/d/Music/Various Artists - [멜론] 2020년 05월 09일 TOP100 (320Kbps)/087 Anne-Marie - Birthday.MP3

parkmino commented 4 years ago

reset_state & clear_covercache did work and embedded covers show up after reboot. Thanks!