Unhandled Exception rises after few seconds, server closes - starting after version V1.5.0-LS280
Is there an existing issue for this?
- [X] I have searched the existing issues
Current Behavior
after version V1.5.0-LS280 the container starts, but then after a few seconds the following error arises, server is not accessible but the container keeps running:
2024-12-27 22:58:17,404 - root (7903b5e4bb28) : ERROR (server:73) - BAZARR cannot start because of unhandled exception. self.server.close()
Expected Behavior
Webserver accessible after container running
Steps To Reproduce
after running a few seconds the webserver closes, permissions on volumes are unchanged, the error disappears on version LS280, after this version the same error appears
Environment
- OS:Ubuntu 24.04
- How docker service was installed: official repositories with official guide
CPU architecture
x86-64
Docker creation
compose file if needed:
services:
bazarr:
container_name: "bazarr"
environment:
- "PUID=1000"
- "PGID=1000"
- "TZ=Etc/UTC"
image: "ghcr.io/linuxserver/bazarr:latest"
ports:
- "6767:6767"
restart: "unless-stopped"
volumes:
- "/data/movies:/movies"
- "/data/series:/tv"
- "/data/docker_configs/bazarr/config:/config"
Container logs
[migrations] started
[migrations] no migrations found
───────────────────────────────────────
██╗ ███████╗██╗ ██████╗
██║ ██╔════╝██║██╔═══██╗
██║ ███████╗██║██║ ██║
██║ ╚════██║██║██║ ██║
███████╗███████║██║╚██████╔╝
╚══════╝╚══════╝╚═╝ ╚═════╝
Brought to you by linuxserver.io
───────────────────────────────────────
To support the app dev(s) visit:
Bazarr: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=XHHRWXT9YB7WE&source=url
To support LSIO projects visit:
https://www.linuxserver.io/donate/
───────────────────────────────────────
GID/UID
───────────────────────────────────────
User UID: 1000
User GID: 1000
───────────────────────────────────────
Linuxserver.io version: v1.5.0-ls284
Build-date: 2024-12-25T22:17:44+00:00
───────────────────────────────────────
[custom-init] No custom files found, skipping...
2024-12-27 22:58:17,404 - root (7903b5e4bb28) : ERROR (server:73) - BAZARR cannot start because of unhandled exception.
Closing database...
Closing webserver...
Traceback (most recent call last):
File "/app/bazarr/bin/bazarr/app/server.py", line 46, in configure_server
self.server = create_server(app,
^^^^^^^^^^^^^^^^^^
File "/app/bazarr/bin/bazarr/../libs/waitress/server.py", line 78, in create_server
last_serv = TcpWSGIServer(
^^^^^^^^^^^^^^
File "/app/bazarr/bin/bazarr/../libs/waitress/server.py", line 243, in __init__
self.bind_server_socket()
File "/app/bazarr/bin/bazarr/../libs/waitress/server.py", line 364, in bind_server_socket
self.bind(sockaddr)
File "/app/bazarr/bin/bazarr/../libs/waitress/wasyncore.py", line 395, in bind
return self.socket.bind(addr)
^^^^^^^^^^^^^^^^^^^^^^
OSError: [Errno 99] Address not available
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/app/bazarr/bin/bazarr/main.py", line 43, in <module>
from app.server import webserver, app # noqa E402
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/bazarr/bin/bazarr/app/server.py", line 108, in <module>
webserver = Server()
^^^^^^^^
File "/app/bazarr/bin/bazarr/app/server.py", line 42, in __init__
self.configure_server()
File "/app/bazarr/bin/bazarr/app/server.py", line 74, in configure_server
self.shutdown()
File "/app/bazarr/bin/bazarr/app/server.py", line 100, in shutdown
self.close_all()
File "/app/bazarr/bin/bazarr/app/server.py", line 97, in close_all
self.server.close()
^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'close'
Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.
I have the same problem. The last two versions v1.5.0-ls283 and v1.5.0-ls284 don't work, I had to revert to v1.4.5-ls282.
v1.5.0-ls284 is working fine for me. The exception (OSError: [Errno 99] Address not available) suggests that the issue may be rooted in your configuration (bazarr's config.yaml), or something unique to your system(s).
- What value do you have set for
general.ip? Mine'sip: 0.0.0.0which, as far as I know, is the default. - If you start a new container with an empty
/configfolder, or just edit yourdocker-compose.ymlto use a new directory, e.g.test-dir:/config, causing bazarr to start with an empty/default configuration, is it able to start and respond? This would confirm that the issue is unique to yourconfig.yaml.
In Settings > General > Host > Address I had the IP address of my server. When I changed it to an asterisk in v1.4.5-ls282, it now works in v1.5.0-ls284. Thanks @brycied00d for pointing me in the right direction :)
I can confirm that was the issue. The IP address in the config was not set to 0.0.0.0, but my internal servers' IPs were.
You have to let the container recreate the config file and then copy and paste your Providers, Radarr, and Sonarr, to make it work and keep everything intact.
Thanks!
[migrations] started [migrations] no migrations found ─────────────────────────────────────── ██╗ ███████╗██╗ ██████╗ ██║ ██╔════╝██║██╔═══██╗ ██║ ███████╗██║██║ ██║ ██║ ╚════██║██║██║ ██║ ███████╗███████║██║╚██████╔╝ ╚══════╝╚══════╝╚═╝ ╚═════╝ Brought to you by linuxserver.io ─────────────────────────────────────── To support the app dev(s) visit: Bazarr: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=XHHRWXT9YB7WE&source=url To support LSIO projects visit: https://www.linuxserver.io/donate/ ─────────────────────────────────────── GID/UID ─────────────────────────────────────── User UID: 1000 User GID: 1000 ─────────────────────────────────────── Linuxserver.io version: v1.5.0-ls284 Build-date: 2024-12-25T22:17:44+00:00 ───────────────────────────────────────
[custom-init] No custom files found, skipping... Connection to localhost (127.0.0.1) 6767 port [tcp/*] succeeded! [ls.io-init] done. 2024-12-29 12:55:33,821 - waitress (72c15be5db28) : INFO (wasyncore:485) - BAZARR is started and waiting for requests on: http://0.0.0.0:6767 2024-12-29 12:55:33,836 - root (72c124a1cb30) : INFO (signalr_client:189) - BAZARR trying to connect to Radarr SignalR feed... 2024-12-29 12:55:33,840 - root (72c124e1cb30) : INFO (signalr_client:122) - BAZARR trying to connect to Sonarr SignalR feed... 2024-12-29 12:55:33,863 - root (72c124a1cb30) : INFO (signalr_client:150) - BAZARR SignalR client for Sonarr is connected and waiting for events. 2024-12-29 12:55:33,883 - root (72c12461cb30) : INFO (signalr_client:217) - BAZARR SignalR client for Radarr is connected and waiting for events.
This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.
Hi,
Just to add my experience : I got the same error from a fresh install. The fix worked. After generating the initial config.yaml file, I went in and changed general.ip: '*' to general.ip: '0.0.0.0', which did the trick. I guess the default configuration could be fixed accordingly to avoid errors in similar situations.
I'm running the container in k3s, if it can help.
This issue is locked due to inactivity