You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
IMPORT_ERRORS+="Or the troubleshooting page troubleshooting page: https://github.com/mathoudebine/turing-smart-screen-python/wiki/Troubleshooting#all-os-tkinter-dependency-not-installed"
60
-
print(IMPORT_ERRORS)
47
+
print("""Import error: %s
48
+
Please follow start guide to install required packages: https://github.com/mathoudebine/turing-smart-screen-python/wiki/System-monitor-:-how-to-start
49
+
Or the troubleshooting page: https://github.com/mathoudebine/turing-smart-screen-python/wiki/Troubleshooting#all-os-tkinter-dependency-not-installed"""%str(
Copy file name to clipboardExpand all lines: main.py
+14-10Lines changed: 14 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -48,21 +48,25 @@
48
48
importwin32con
49
49
importwin32gui
50
50
51
-
try:
52
-
importpystray
53
-
except:
54
-
pass
55
-
except:
56
-
print(
57
-
"[ERROR] Python dependencies not installed. Please follow start guide: https://github.com/mathoudebine/turing-smart-screen-python/wiki/System-monitor-:-how-to-start")
51
+
fromlibrary.logimportlogger
52
+
importlibrary.schedulerasscheduler
53
+
fromlibrary.displayimportdisplay
54
+
55
+
exceptExceptionase:
56
+
print("""Import error: %s
57
+
Please follow start guide to install required packages: https://github.com/mathoudebine/turing-smart-screen-python/wiki/System-monitor-:-how-to-start
58
+
Or the troubleshooting page: https://github.com/mathoudebine/turing-smart-screen-python/wiki/Troubleshooting#all-os-tkinter-dependency-not-installed"""%str(
59
+
e))
58
60
try:
59
61
sys.exit(0)
60
62
except:
61
63
os._exit(0)
62
64
63
-
fromlibrary.logimportlogger
64
-
importlibrary.schedulerasscheduler
65
-
fromlibrary.displayimportdisplay
65
+
try:
66
+
importpystray
67
+
except:
68
+
# If pystray cannot be loaded do not stop the program, just ignore it. The tray icon will not be displayed.
0 commit comments