Description
If an error occurs during the initial setup (like cookie validation failure or network issues), the program crashes with an UnboundLocalError instead of displaying the actual error message.
This happens because the script tries to evaluate if tasks: at the end of the block, but tasks was never declared if the process failed early on.
Suggested Fix
You can declare tasks = [] before the try block, or update the condition around line 117 in main.py to:
if 'tasks' in locals() and tasks:
Alternatively, initializing tasks = [] before entering the main try block also works cleanly to prevent UnboundLocalError.
Description
If an error occurs during the initial setup (like cookie validation failure or network issues), the program crashes with an UnboundLocalError instead of displaying the actual error message.
This happens because the script tries to evaluate if tasks: at the end of the block, but tasks was never declared if the process failed early on.
Suggested Fix
You can declare tasks = [] before the try block, or update the condition around line 117 in main.py to:
if 'tasks' in locals() and tasks:
Alternatively, initializing tasks = [] before entering the main try block also works cleanly to prevent UnboundLocalError.