From bd020d30b063894e01eb6516a53dfc0e41f7bb1d Mon Sep 17 00:00:00 2001 From: gutosie Date: Sat, 19 Jun 2021 21:50:03 +0300 Subject: [PATCH] fix atv 7 crash --- NeoBoot/plugin.py | 10 ++++++++-- NeoBoot/unpack.py | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/NeoBoot/plugin.py b/NeoBoot/plugin.py index a06130f..69550e2 100644 --- a/NeoBoot/plugin.py +++ b/NeoBoot/plugin.py @@ -46,7 +46,7 @@ import os import time from time import gmtime, strftime from Tools.Testinout import getTestIn, getTestOut, getTestInTime, getTestOutTime, getAccessN, getAccesDate, getButtonPin, getTestToTest -if fileExists('/etc/vtiversion.info') or fileExists('/etc/bhversion') or fileExists('/usr/lib/python3.8') and fileExists('/.multinfo'): +if fileExists('/etc/vtiversion.info') or fileExists('/etc/bhversion') or fileExists('/usr/lib/python3.8') or fileExists('/usr/lib/python3.9') and fileExists('/.multinfo'): from Screens.Console import Console else: try: @@ -55,7 +55,7 @@ else: from Screens.Console import Console loggscrash = time.localtime(time.time()) -PLUGINVERSION = '9.26' +PLUGINVERSION = '9.27' UPDATEVERSION = '9.30' UPDATEDATE = '"+%Y07%d"' LinkNeoBoot = '/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot' @@ -843,6 +843,12 @@ class NeoBootImageChoose(Screen): False def close_exit(self): + if fileExists('/usr/lib/python3.9'): + self.close() + else: + self.close_exit2() + + def close_exit2(self): system('touch /tmp/.init_reboot') if fileExists('/tmp/error_neo'): try: diff --git a/NeoBoot/unpack.py b/NeoBoot/unpack.py index 76af183..06528cb 100644 --- a/NeoBoot/unpack.py +++ b/NeoBoot/unpack.py @@ -30,7 +30,7 @@ from os import system, listdir, mkdir, chdir, getcwd, rename as os_rename, remov from os.path import dirname, isdir, isdir as os_isdir import os import time -if fileExists('/etc/vtiversion.info') or fileExists('/etc/bhversion') or fileExists('/usr/lib/python3.8') and fileExists('/.multinfo'): +if fileExists('/etc/vtiversion.info') or fileExists('/etc/bhversion') or fileExists('/usr/lib/python3.8') or fileExists('/usr/lib/python3.8') or fileExists('/usr/lib/python3.9') and fileExists('/.multinfo'): from Screens.Console import Console else: try: