mirror of
https://github.com/morpheus65535/bazarr.git
synced 2025-01-10 16:57:45 +08:00
Fix for restart after update from source on github.
This commit is contained in:
parent
626f5ea414
commit
a3484d2c16
1 changed files with 5 additions and 4 deletions
|
@ -294,10 +294,11 @@ def request_json(url, **kwargs):
|
||||||
def updated(restart=True):
|
def updated(restart=True):
|
||||||
if settings.general.getboolean('update_restart') and restart:
|
if settings.general.getboolean('update_restart') and restart:
|
||||||
try:
|
try:
|
||||||
from main import restart
|
requests.get('http://127.0.0.1:' + settings.general.port + settings.general.base_url + 'restart')
|
||||||
restart()
|
except requests.ConnectionError:
|
||||||
except:
|
pass
|
||||||
logging.info('BAZARR Restart failed, please restart Bazarr manualy')
|
except (requests.ConnectTimeout, requests.HTTPError, requests.ReadTimeout, requests.Timeout):
|
||||||
|
logging.info('BAZARR Restart failed, please restart Bazarr manually')
|
||||||
updated(restart=False)
|
updated(restart=False)
|
||||||
else:
|
else:
|
||||||
database.execute("UPDATE system SET updated='1'")
|
database.execute("UPDATE system SET updated='1'")
|
||||||
|
|
Loading…
Reference in a new issue