File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -68,7 +68,9 @@ def _watch_profile(self):
6868 # If last line is not a valid profile file, no profile can be loaded so its an error
6969 if potential_profile is None or not os .path .isfile (potential_selected_file ):
7070 message = 'The following profile is selected, but could not be found: ' + potential_selected_file
71- raise Exception (message )
71+ FreePieVars .diagnostics .debug (message )
72+ FreePieVars .diagnostics .notify (message )
73+ return
7274
7375 # If the selected profile file is the same as the current active profile, then nothing to do
7476 elif potential_selected_file == self ._active_profile_path :
@@ -106,6 +108,10 @@ def _watch_profile(self):
106108
107109 # If profile selection has not changed, then check whether the active selected profile has changed
108110 else :
111+ # Occurs at first run with invalid profile selection: no profile path exists yet
112+ if self ._active_profile_path is None :
113+ return
114+
109115 stamp = os .stat (self ._active_profile_path ).st_mtime
110116 if stamp != self ._cached_selected_profile_stamp :
111117 self ._generate_pretty_profile_print ()
You can’t perform that action at this time.
0 commit comments