Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to add server #373

Open
SaurabhHarwande opened this issue Mar 27, 2024 · 1 comment
Open

Unable to add server #373

SaurabhHarwande opened this issue Mar 27, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@SaurabhHarwande
Copy link

SaurabhHarwande commented Mar 27, 2024

Describe the bug
I have setup my jellyfin server on a raspberry pi which is accessible at http://jellyfin.rbpi.home(I have a reverse proxy running on the server so ports are not needed the URL is automatically routed to the server).

I am able to open this URL in the browser. But when I am trying to add server with the above URL it does not work.

jellyfin-mpv-shim has been installed using the AUR package on Arch Linux.

From logs the error could be that the application is appending a port to the URL which will not work in my case. http://jellyfin.rbpi.home but http://jellyfin.rbpi.home:8096 will fail.

Solution could be to add an option to exclude port in the http url? Or we can also do something official jellyfin clients do. Try connecting both URLs one after the other. First attempt <entered_url>, then attempt <entered_url>:8096.

To Reproduce
Steps to reproduce the behavior:

  1. Open jellyfin-mpv-shim
  2. Enter the server url http://jellyfin.rbpi.home
  3. Enter the username and password for user that has been setup on the server
  4. Click on Add Server
  5. Following error is shown Could not add server. Please check your connection information.

Expected behavior
When we enter correct URL, credentials and click on add server we should be able to connect to the jellyfin server and access content.

Screenshots
image

Desktop (please complete the following information):

  • OS: Arch Linux
  • Version: 6.8.1-arch1-1

Error Messages

2024-03-27 11:34:55,109 [    INFO] conf: Loaded settings from json: /home/saurabh/.config/jellyfin-mpv-shim/conf.json
2024-03-27 11:34:55,169 [    INFO] player: Using libmpv1 playback backend.
2024-03-27 11:34:55,175 [   ERROR] menu: Could not load profile manager.
Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/jellyfin_mpv_shim/menu.py", line 79, in __init__
    self.profile_manager = VideoProfileManager(self, player_manager, player)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/jellyfin_mpv_shim/video_profile.py", line 66, in __init__
    raise FileNotFoundError("Could not find default shader pack.")
FileNotFoundError: Could not find default shader pack.
2024-03-27 11:34:55,179 [ WARNING] mpv: cplayer: The shared-script-properties property is deprecated and will be removed in the future. Use the user-data property instead.

Process STrayProcess-1:
Traceback (most recent call last):
  File "/usr/lib/python3.11/multiprocessing/process.py", line 314, in _bootstrap
    self.run()
  File "/usr/lib/python3.11/site-packages/jellyfin_mpv_shim/gui_mgr.py", line 439, in run
    from pystray import Icon, MenuItem, Menu
ModuleNotFoundError: No module named 'pystray'
2024-03-27 11:35:24,591 [ WARNING] clients: Adding port 8096 for insecure local http connection.
2024-03-27 11:35:24,592 [ WARNING] clients: If you want to connect to standard http port 80, use :80 in the url.
2024-03-27 11:35:24,592 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.client: JellyfinClient initializing...
2024-03-27 11:35:24,592 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.configuration: Configuration initializing...
2024-03-27 11:35:24,592 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.configuration: Begin http constructor.
2024-03-27 11:35:24,592 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.ws_client: WSClient initializing...
2024-03-27 11:35:24,592 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.connection_manager: ConnectionManager initializing...
2024-03-27 11:35:24,593 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.credentials: Credentials initializing...
2024-03-27 11:35:24,593 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.configuration: Begin app constructor.
2024-03-27 11:35:24,593 [    INFO] JELLYFIN.jellyfin_apiclient_python.api: Sending get request to system/info/public
2024-03-27 11:35:24,593 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.api: 5
2024-03-27 11:35:24,593 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.api: {'Accept': 'application/json', 'Content-type': 'application/x-www-form-urlencoded; charset=UTF-8', 'X-Application': 'Jellyfin MPV Shim/2.6.0', 'Accept-Charset': 'UTF-8,*', 'Accept-encoding': 'gzip', 'User-Agent': 'Jellyfin-MPV-Shim/2.6.0', 'x-emby-authorization': 'MediaBrowser Client=Jellyfin MPV Shim, Device=DevMachine, DeviceId=aac9e453-6064-40f6-8edc-057cd3f86f0e, Version=2.6.0'}
2024-03-27 11:35:24,597 [   DEBUG] urllib3.connectionpool: Starting new HTTP connection (1): jellyfin.rbpi.home:8096
2024-03-27 11:35:24,606 [   ERROR] JELLYFIN.jellyfin_apiclient_python.connection_manager: connect_to_address http://jellyfin.rbpi.home:8096 failed
2024-03-27 11:35:24,606 [    INFO] JELLYFIN.jellyfin_apiclient_python.api: Trying to login to http://jellyfin.rbpi.home:8096/Users/AuthenticateByName as root
2024-03-27 11:35:24,606 [    INFO] JELLYFIN.jellyfin_apiclient_python.api: Sending post request to Users/AuthenticateByName
2024-03-27 11:35:24,606 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.api: (5, 30)
2024-03-27 11:35:24,606 [   DEBUG] JELLYFIN.jellyfin_apiclient_python.api: {'Accept': 'application/json', 'Content-type': 'application/json', 'X-Application': 'Jellyfin MPV Shim/2.6.0', 'Accept-Charset': 'UTF-8,*', 'Accept-encoding': 'gzip', 'User-Agent': 'Jellyfin-MPV-Shim/2.6.0', 'x-emby-authorization': 'MediaBrowser Client=Jellyfin MPV Shim, Device=DevMachine, DeviceId=aac9e453-6064-40f6-8edc-057cd3f86f0e, Version=2.6.0'}
2024-03-27 11:35:24,607 [   DEBUG] urllib3.connectionpool: Starting new HTTP connection (1): jellyfin.rbpi.home:8096
2024-03-27 11:35:24,613 [   ERROR] JELLYFIN.jellyfin_apiclient_python.api: HTTPConnectionPool(host='jellyfin.rbpi.home', port=8096): Max retries exceeded with url: /Users/AuthenticateByName (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7383cb086a10>: Failed to establish a new connection: [Errno 111] Connection refused'))
2024-03-27 11:35:24,614 [    INFO] JELLYFIN.jellyfin_apiclient_python.connection_manager: Failed to login as `root`
@SaurabhHarwande SaurabhHarwande added the bug Something isn't working label Mar 27, 2024
@gudvinr
Copy link

gudvinr commented Apr 20, 2024

Solution could be to add an option to exclude port in the http url? Or we can also do something official jellyfin clients do. Try connecting both URLs one after the other. First attempt <entered_url>, then attempt <entered_url>:8096.

It's not a solution, there's no such thing as "no port". When you connect to URL in the browser without explicitly adding :<port number> browser will connect to :80 when using http:// or to :443 when using https://.

Application log even says:

If you want to connect to standard http port 80, use :80 in the url

So, you just need to do exactly that if your jellyfin instance listens on port 80

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants