FreeTube icon indicating copy to clipboard operation
FreeTube copied to clipboard

[Bug]: IINA won't open: giving javascript error

Open gradygambrell opened this issue 1 year ago • 33 comments

Guidelines

  • [X] I have encountered this bug in the latest release of FreeTube.
  • [X] I have encountered this bug in the official downloads of FreeTube.
  • [X] I have searched the issue tracker for open and closed issues that are similar to the bug report I want to file, without success.
  • [X] I have searched the documentation for information that matches the description of the bug I want to file, without success.
  • [X] This issue contains only one bug.

Describe the bug

  1. Go to a video of choice
  2. Click on the video and let it play
  3. Click on the icon that allows to use another player
  4. When error occurs, I:
  5. Go into settings and click on the External Player section
  6. Click on "Ignore unsupported action warnings"
  7. type the full path of IINA player in the custom player (IINA is in my Applications folder)
  8. try again with no prevail.

Expected Behavior

To be able to open the IINA player.

Issue Labels

feature stopped working, text/string issue, usability issue, visual bug

FreeTube Version

v0.19.1 and nightly 3525

Operating System Version

macOS Sonoma 14.0

Installation Method

.dmg

Primary API used

Invidious API

Last Known Working FreeTube Version (If Any)

No response

Additional Information

I check the issue here, but hasn't be responded since Sept 5th (unsure if it's this year or 2022):

https://github.com/FreeTubeApp/FreeTube/issues/2158

The thing is closed and is unsure if an solution have been made.

I have used the nightly build, with no success.

Nightly Build

gradygambrell avatar Oct 10 '23 22:10 gradygambrell

have you added the directory of your IINA executable to your path environment variable?

ChunkyProgrammer avatar Oct 11 '23 01:10 ChunkyProgrammer

have you added the directory of your IINA executable to your path environment variable?

I have tried that, still gave me the Javascript error:

Uncaught Exception:
Error: spawn /Applications/IINA.app/Contents/MacOS/IINA  ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)

gradygambrell avatar Oct 11 '23 15:10 gradygambrell

@trostboot any thoughts one this?

I don't have any Apple devices so can't really debug this. Does spawning external players work at all on MacOS the way it's currently implemented? @gradygambrell test it with e.g. mpv.

trostboot avatar Oct 15 '23 20:10 trostboot

I don't have any Apple devices so can't really debug this. Does spawning external players work at all on MacOS the way it's currently implemented? @gradygambrell test it with e.g. mpv.

Tried MPV without any path name (default folder is /Applications/mpv.app and gives me this JS error:

Uncaught Exception:
Error: spawn mpv ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)

Tried with this path name: /Applications/mpv.app/Contents/MacOS/mpv-bundle and it opens the application, but then closes right away.

Tried VLC player using /Applications/VLC.app and another JS error appeared.

Uncaught Exception:
Error: spawn vlc ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)

HOWEVER, using this path in the custom path: /Applications/VLC.app/Contents/MacOS/VLC, I was able to open it via VLC. Had to do an extra step by clicking on the title of the video to play.

TL;DR: mpv didn't work. VLC does, but with an special path.

gradygambrell avatar Oct 15 '23 20:10 gradygambrell

Could you send a screenshot of your external player configuration?

ChunkyProgrammer avatar Oct 17 '23 01:10 ChunkyProgrammer

Could you send a screenshot of your external player configuration?

Yes.

Screen Shot 2023-10-17 at 2 14 31 PM

(This one is after everything is loaded) Screen Shot 2023-10-17 at 2 14 24 PM

gradygambrell avatar Oct 17 '23 18:10 gradygambrell

This works fine for me on Windows as well as Linux. I usually have miniplayer, potplayer and inbuilt linux ones, and each one plays fine. image

vdbhb59 avatar Oct 30 '23 14:10 vdbhb59

This issue is stale because it has been open 28 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Nov 28 '23 01:11 github-actions[bot]

I have the same Javascript error. BTW : Is IINA an mpv based player for macOS ?

sebma avatar Dec 21 '23 17:12 sebma

This issue is stale because it has been open 28 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Jan 23 '24 01:01 github-actions[bot]

Same issue on macos

superfreeman1989 avatar Jan 29 '24 14:01 superfreeman1989

same issue on linux (fedora 39) using mpv, open a youtube video directly with mpv from the shell works, but not from freetube

avfx avatar Feb 15 '24 12:02 avfx

same issue on linux (fedora 39) using mpv, open a youtube video directly with mpv from the shell works, but not from freetube

Hm, I can't repro this @avfx . Fresh Fedora 39 VM, updated to latest packages, only with the minimum additional packages needed for mpv and Freetube dev. Freetube default settings aside from external player -> mpv. Works from both the shell as well as from Freetube. Could you give it a try with a fresh profile with default Freetube settings and see if it still breaks?

trostboot avatar Feb 15 '24 17:02 trostboot

I did a Fresh Fedora 39 VM using VirtualBox, installed mpv , youtube-dl and freetube. All runs with default settings, mpv opens a YouTube video from the shell and Freetube still gives me the same error as I have in my host machine (see below). I originally thought it's because I have the flatpak version of mpv on my host and I used yt-dlp instead of youtube-dl, but it didn't seem to be the case as I didn't use flatpak on the VM and I used youtube-dl.

Screenshot from 2024-02-16 04-15-36

avfx avatar Feb 15 '24 20:02 avfx

Thanks @trostboot. I found the issue, it's running the flatpak version of Freetube. It works when I use the rpm version.

avfx avatar Feb 15 '24 20:02 avfx

Okay well that makes more sense given the nature of Flatpaks. I have no idea if the MacOS version is similarly sandboxed as to cause the original issue, but either way, this is a bit out of my wheelhouse and not something I personally have the time to look deeper into.

trostboot avatar Feb 15 '24 21:02 trostboot

I have the same issue with VLC on Win10. Fresh install of Freetube (I am new joiner) obraz

jurekcy avatar Feb 19 '24 13:02 jurekcy

This issue is stale because it has been open 28 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Mar 19 '24 01:03 github-actions[bot]

This issue is stale because it has been open 28 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Apr 17 '24 01:04 github-actions[bot]

Issue still exists in latest release

superfreeman1989 avatar May 15 '24 14:05 superfreeman1989

YUpppp just tried and have the same issue.

rishikanthc avatar May 29 '24 06:05 rishikanthc

This issue is stale because it has been open 28 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Jun 27 '24 01:06 github-actions[bot]

For me on macOS, putting /opt/homebrew/bin/iina into the Custom External Player Executable input works, as I installed iina with Homebrew.

ngocphamm avatar Jul 25 '24 14:07 ngocphamm