music-assistant / hass-music-assistant

Turn your Home Assistant instance into a jukebox, hassle free streaming of your favorite media to Home Assistant media players.
Apache License 2.0
1.31k stars 48 forks source link

Playlist: relative Path not working when going up two levels #2291

Open sebmuc99 opened 4 months ago

sebmuc99 commented 4 months ago

What version of Music Assistant has the issue?

2.0.3

What version of the Home Assistant Integration have you got installed?

No response

Have you tried everything in the Troubleshooting FAQ and reviewed the Open and Closed Issues and Discussions to resolve this yourself?

The problem

relative Path in local Playlists not working

image

How to reproduce

Use relative Path in Playlists

Music Providers

local disc

Player Providers

any

Full log output

No response

Additional information

No response

What version of Home Assistant Core are your running

2024.5.3

What type of installation are you running?

Home Assistant Core

On what type of hardware are you running?

Raspberry Pi

marcelveldt commented 4 months ago

Relative paths are supported but not in an higher level than the folder you added to the file provider.

Rudd-O commented 4 months ago

A bit of context is needed:

The MASS container mounts your music on /media. Naturally, any playlist that tries to traverse above that folder (using relative paths) will look invalid from the perspective of MASS, even if it works directly on the machine serving or containing the files.

sebmuc99 commented 4 months ago

All music Files are located here (no Folders for Arist or whatever): /volume1/media01/musicLibrary/musicLibrary/

All Playlists are located here: /volume1/media01/musicLibrary/musicLibrary/_PLAYLISTS

thats my mounting: /volume1/media01/musicLibrary/musicLibrary:/media

Sample1 is working: located in /media/_PLAYLISTS/Happy Favorits 2.m3u ../FILE003372.mp3 ../FILE004255.mp3

Sample2 is working (wired because the path is not correct): located in /media/_PLAYLISTS/Happy Favorits 3.m3u FILE003372.mp3 FILE004255.mp3

Sample3 is NOT working: located in /media/_PLAYLISTS/Allgemein/Happy Favorits.m3u ../../FILE000996.mp3 ../../FILE004803.mp3

OzGav commented 4 months ago

Based on the above it seems the title of this report is incorrect. For paths that only go up one level it seems to work but when going up two levels it does not. Is that the case?

Rudd-O commented 3 months ago

Sample3 is NOT working: located in /media/_PLAYLISTS/Allgemein/Happy Favorits.m3u ../../FILE000996.mp3 ../../FILE004803.mp3

Yes, that's not gonna work because it's trying to go above /media.

Edit: I was wrong.

OzGav commented 3 months ago

@Rudd-O i think it goes to media doesn’t it?

Rudd-O commented 3 months ago

Oh! I stand corrected. Thanks.

OzGav commented 2 months ago

@sebmuc99 Please confirm if this is still and issue in beta 14

OzGav commented 2 months ago

We will close this soon due to no follow up

sebmuc99 commented 1 month ago

Sorry needed some time to setup a beta environment. issue still exists with version 2.1.0rc3 It is working with 1st level but not with 2nd level

_Working (Path /media/mediaLibrary/Playlists): image

_Not Working (Path /media/mediaLibrary/Playlists/Interpreten): image