Browse Source

only warn about failed pre-evaluation if it matters

Falko Schindler 2 years ago
parent
commit
30010cd6a1
1 changed files with 2 additions and 1 deletions
  1. 2 1
      nicegui/run.py

+ 2 - 1
nicegui/run.py

@@ -76,7 +76,8 @@ def run(self, *,
         return  # server is reloading
 
     if not globals.pre_evaluation_succeeded:
-        logging.warning('Failed to pre-evaluate ui.run().')
+        if exclude or reload:
+            logging.warning('Failed to pre-evaluate ui.run().')
         if exclude:
             logging.warning('The `exclude` argument will be ignored.')
         if reload: