mirror of
https://github.com/TrezOne/docker-mods-uptime-kuma-timeout-fix.git
synced 2026-07-19 01:46:10 -04:00
Test #6 - importing TimeoutError from socketio.exceptions...
This commit is contained in:
@@ -2,7 +2,7 @@ import requests
|
|||||||
from uptime_kuma_api.api import UptimeKumaApi, MonitorType
|
from uptime_kuma_api.api import UptimeKumaApi, MonitorType
|
||||||
from auto_uptime_kuma.log import Log
|
from auto_uptime_kuma.log import Log
|
||||||
from auto_uptime_kuma.config_service import ConfigService
|
from auto_uptime_kuma.config_service import ConfigService
|
||||||
|
from socketio.exceptions import TimeoutError
|
||||||
|
|
||||||
class UptimeKumaService:
|
class UptimeKumaService:
|
||||||
|
|
||||||
@@ -144,7 +144,7 @@ class UptimeKumaService:
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
monitor = self.api.add_monitor(**monitor_data)
|
monitor = self.api.add_monitor(**monitor_data)
|
||||||
except socketio.exceptions.TimeoutError:
|
except TimeoutError:
|
||||||
Log.error("Timeout while trying to add monitor to Uptime Kuma. Is the server responsive?")
|
Log.error("Timeout while trying to add monitor to Uptime Kuma. Is the server responsive?")
|
||||||
return None
|
return None
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
|||||||
Reference in New Issue
Block a user