pragha-music-player / pragha

Pragha is a Lightweight Music Player for GNU/Linux.
GNU General Public License v3.0
173 stars 35 forks source link

Album covers saved in .cache even though local images defined #150

Open apps4research opened 5 years ago

apps4research commented 5 years ago

I've setup pragha to use the local jpegs saved in each album folder of my collection, which is a great feature. This local image is also being used for notifications via MPRIS DBUS interface (I wrote a little bash scripts to see what the dictionary entails and to see what the url of the album cover returns) ... all good so far ...

However, its seems like album images are being extraced from the mp3 file (they are sometimes different than my local album folder.jpg) and saved in the .cache folder (i have disabled all plugins that would/could do that) ... so I wonder if its a bug ... it kind of bugs me as its filling up my local home directory unnecessarily with images that I have saved elsewhere.

--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/70976215-album-covers-saved-in-cache-even-though-local-images-defined?utm_campaign=plugin&utm_content=tracker%2F352350&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F352350&utm_medium=issues&utm_source=github).
apps4research commented 5 years ago

Just as some additional info ... if I delete the cache album covers, play a song for the first time, MPRIS returns the local jpeg file in the album folder e.g. mpris:artUrl = file:///mnt/server/music/2%20Pac/Greatest%20Hits/folder.jpg of course it also saves an album cover in the cache

but when I close pragha and restart, I guess it looks in the cache first and then uses that image e.g. mpris:artUrl = file:///home/tina/.cache/pragha/album-2%20Pac-Greatest%20Hits.jpeg

matiasdelellis commented 5 years ago

Hi @apps4research Now that you mention it, it can be a bit annoying as it is developed..

At this moment, practically pragha search in parallel with all the providers (folder, tags, and songinfo plugin), and the first one that is found is saved in cache..

In the particular case of the cover in folders, it was not cached again, to save space, but when it finds it in the tags, it caches it to be able to visualize it, with any file viewer, or Mpris2.. This is what is happening to you in the last comment ... :disappointed:

Keep in mind that I am making efforts to work with some music servers, like ampache or koel, and the simplest thing is to take the cover of the same file.

How do you suggest the behavior? :wink: