jeffvli / feishin

A modern self-hosted music player.
https://feishin.vercel.app
GNU General Public License v3.0
2.33k stars 90 forks source link

Tracks not playing when using `Audio Player > MPV` #286

Open foss- opened 11 months ago

foss- commented 11 months ago

Expected Behavior

Tracks should be played.

Current Behavior

When using Audio Player > MPV and playing a track, the track never plays. Tried MP3 and AAC files.

Possible Solution

Using Audio player > Web does play tracks.

Your Environment

Turtlepoker commented 10 months ago

Are you sure you have the executable path set correctly? I had the wrong location set so it didn't play. There was a play issue before 0.4.1 where you had to click play button, but that's been fixed.

foss- commented 10 months ago

MPV resides in application folder. I select the app and confirm with Open in Settins > MPV executable path but no tracks play.

darwintree commented 10 months ago

Supposed to select the binary rather than the app(.zip). If installed by homebrew, the binary would be /usr/local/bin/mpv

foss- commented 10 months ago

Did not install via homebrew. Have mpv.app in Applications folder and that is where I directed the path to. Is that incorrect? Persisting in 0.5.0.

darwintree commented 10 months ago

Did not install via homebrew. Have mpv.app in Applications folder and that is where I directed the path to. Is that incorrect? Persisting in 0.5.0.

It is wrong. The application is actually a zip. You need to point to a binary

foss- commented 10 months ago

Can you share steps? I visit https://mpv.io/installation/ which following the first mac link brings us to https://laboratory.stolendata.net/~djinn/mpv_osx/

There I download 2023-Jul-24 13:02 mpv-0.36.0.tar.gz

When I unpack that I receive the mpv.app file, which is a binary. Now where does a zip file come into play? Also how is a zip file an application? Maybe there is a misudnerstanding on my side?

darwintree commented 10 months ago

Can you share steps? I visit https://mpv.io/installation/ which following the first mac link brings us to https://laboratory.stolendata.net/~djinn/mpv_osx/

There I download 2023-Jul-24 13:02 mpv-0.36.0.tar.gz

When I unpack that I receive the mpv.app file, which is a binary. Now where does a zip file come into play? Also how is a zip file an application? Maybe there is a misudnerstanding on my side?

Yes, the mpv.app IS a zip. You can somehow unzip it.

As far as how to download a binary, for me, I uses brew.

brew install mpv

then type

whereis mpv

For me, the result is mpv: /usr/local/bin/mpv /usr/local/share/man/man1/mpv.1

And then in feishin, point the binary path to /usr/local/bin/mpv. You might need some tricks to specify the path(shift + command + g)

foss- commented 10 months ago

Great to hear this works via brew.

Do you know if this should also work with a download from https://mpv.io/installation/? As indicated earlier, I download and unpack the binary and point Feishin at the location of the binary in the applications folder.

While the applications folder lists mpv.app after setting that location in Feishin it shows as mpv.app.zip.

Unsure if that should work. I can't play any audio at all currently.

This is the settings: 1

It is interesting that after switching to another tab e.g. Hotkeys and back to Playback the executable path has changed to var/folders/lr/long_string_here.

Unsure what the expected behavior is.

darwintree commented 10 months ago

Great to hear this works via brew.

Do you know if this should also work with a download from https://mpv.io/installation/? As indicated earlier, I download and unpack the binary and point Feishin at the location of the binary in the applications folder.

While the applications folder lists mpv.app after setting that location in Feishin it shows as mpv.app.zip.

Unsure if that should work. I can't play any audio at all currently.

This is the settings: 1

It is interesting that after switching to another tab e.g. Hotkeys and back to Playback the executable path has changed to var/folders/lr/long_string_here.

Unsure what the expected behavior is.

The mvp.app is not a binary but a zip like .apk files. I've met the same problem you mentioned also and consider it impossible for an early version app to support this complex feature so I migrated to binary that brew downloads.

foss- commented 10 months ago

As it seems there is no easy solution in sight to point Feishin at the mpv app tried the brew route. After installing received the same output for whereis mpv: mpv: /usr/local/bin/mpv /usr/local/share/man/man1/mpv.1

Then pointed Feishin at /usr/local/bin/mpv but after a restart still no audio will play and setting shows: 1

darwintree commented 10 months ago

It seems that you are not pointing to the right path. Would you check if the binary is in /usr/local/cellar/mpv/0.36.0/bin/mpv? The path is strange

foss- commented 10 months ago

/usr/local/cellar/mpv/0.36.0/bin/mpv indeed holds mpv file while /usr/local/bin/mpv is only a simlink.

darwintree commented 10 months ago

In that case I could not figure out any better solution. Sorry for that

altodd commented 9 months ago

I would suggest Further instructions in the directions, was able to get music playing after searching and finding this issue. I was trying to specify the app like @foss- as they pointed out the instructions say to just go get the app from the link and don't elaborate on further extracting it.

Fyi, it didn't work at first, after restarting the app once or twice after the fix it started working, so hopefully you've also got it cooperating

alfureu commented 8 months ago

the same applies to W10 and mpv installed via scoop

bitkris-dev commented 8 months ago

For anyone else still wondering, it took me a while even after reading this topic. So I will write step-by-step the clear instructions, to ease someone else's life (Mac OS only!):

1) Download and install Feishin from releases

2) Open terminal and run brew install mpv to install mpv from homebrew (it will take a while)

3) Keep the terminal open and run whereis mpv to find the path to mpv, it will return 2 paths but none of them is the one we are going to use. We must use the results to get the homebrew root path and then deduce the right mpv path. For example, if the first path returned by whereis is /opt/homebrew/bin/mpv, your homebrew root is /opt/homebrew. Then the path to mpv is found adding /Cellar/mpv/<version>/bin/mpv. In my case the final result was /opt/homebrew/Cellar/mpv/0.37.0_1/bin/mpv

4) Make sure the deduced path is found in Finder (Cmd+Shift+G and paste the path) and that the mpv file is identified as exec by your Mac (screenshot below)

Screenshot 2023-12-28 at 16 12 18

5) Open Feishin and add that path to mpv in the welcome screen. If you already added it, you can add change it clicking the Hamburger menu to the left --> Settings --> Playback --> Mpv executable path.

6) After doing that, open your Activity Monitor, find Feishin in the list and Force quit it. Wait it disappears from the processes, open it again and Force quit again, and repeat at least 3 times in total.

7) Now your Feishin should play flawlessly. Enjoy!

jboxman commented 7 months ago

I can confirm that I couldn't get this to work until I selected the full path to the brew cellar version of the binary. Pointing to a symlink isn't enough. For whatever reason, that doesn't work. For version 0.37.0_1 the path is: /usr/local/Cellar/mpv/0.37.0_1/bin/mpv.

To get there in the file browser, you need to navigate to your root Mac OS drive, and then enable hidden folders in Finder with SHIFT-CMD-.. Then you'll see /usr and you can navigate to the binary. Plays great now after a restart.

bagusnl commented 3 months ago

the same applies to W10 and mpv installed via scoop

I can confirm the same with W11 and MPV installed via chocolatey

C:\Users\bagusnl>where mpv
C:\ProgramData\chocolatey\lib\mpv.install\tools\mpv.com
C:\ProgramData\chocolatey\lib\mpv.install\tools\mpv.exe

C:\Users\bagusnl>mpv --version
mpv 1c9c2f5 Copyright © 2000-2023 mpv/MPlayer/mplayer2 projects
 built on Dec 10 2023 12:02:37
libplacebo version: v6.338.0-62-g52314e0-dirty
FFmpeg version: N-112938-g12e25af7a
FFmpeg library versions:
   libavutil       58.32.100
   libavcodec      60.35.100
   libavformat     60.18.100
   libswscale      7.6.100
   libavfilter     9.14.100
   libswresample   4.13.100

note: tried overriding the install path with both the COM wrapper and direct exe, both wont work.