exception in thread causes backtrace at very end of execution.
Expectation:
exception is handeled andproperly logged when the error happens
Code:
*** Settings ***
Library Collections
*** Keywords ***
threading_sync_base.thread1
Log entering thrd1 console=True
Sleep 1
Log Causing exception by accessing not existing list console=True
Append To List ${var_thrd} 11
Log This will not be reached console=True
Send Thread Notification threading_sync_base.thread1_finished 0
*** Test Cases ***
Threading Sync Base
THREAD TEST_THREAD1 False
threading_sync_base.thread1
END
Wait Thread Notification threading_sync_base.thread1_finished 5
Log:
$ /usr/bin/env C:\\Users\\pol2hi\\AppData\\Local\\Temp\\rf-ls-run\\run_env_00_lyxs0a2r.bat -u c:\\Program\ Files\\RobotFramework\\robotvscode\\data\\extensions\\robocorp.robotframework-lsp-1.11.0\\src\\robotframework_debug_adapter\\run_robot__main__.py --port 64196 --no-debug -T -d C:\\RobotTest\\testcases\\..\\logfiles -b debug\\hanging_thread.log -l htmllog\\hanging_thread_log.html -o xmloutput\\hanging_thread_output.xml -r htmlreport\\hanging_thread_report.html c:\\RobotTest\\testcases\\hanging_thread.robot
==============================================================================
Hanging Thread
==============================================================================
Threading Sync Base entering thrd1
Causing exception by accessing not existing list
RFStream Warning: keyword - BuiltIn.Wait Thread Notification did not have a corresponding pop.
Exception in thread TEST_THREAD1:
Traceback (most recent call last):
File "C:\Program Files\RobotFramework\python39\lib\threading.py", line 980, in _bootstrap_inner
self.run()
File "C:\Program Files\RobotFramework\python39\lib\threading.py", line 917, in run
self._target(*self._args, **self._kwargs)
File "C:\Program Files\RobotFramework\python39\lib\site-packages\robotframework-6.1-py3.9.egg\robot\running\bodyrunner.py", line 539, in run_worker
runner.run(data.body)
File "C:\Program Files\RobotFramework\python39\lib\site-packages\robotframework-6.1-py3.9.egg\robot\running\bodyrunner.py", line 62, in run
raise ExecutionFailures(errors)
robot.errors.ExecutionFailures: Variable '${var_thrd}' not found.
RFStream Warning: unable to pop keyword - BuiltIn.Wait Thread Notification because it does not match the current top: suite - s1
Threading Sync Base | FAIL |
Unable to received thread notification 'threading_sync_base.thread1_finished' in '5' seconds.
------------------------------------------------------------------------------
Hanging Thread | FAIL |
1 test, 0 passed, 1 failed, 0 unknown
==============================================================================
Debug: C:\RobotTest\logfiles\debug\hanging_thread-20231108-113102.log
Output: C:\RobotTest\logfiles\xmloutput\hanging_thread_output-20231108-113102.xml
Log: C:\RobotTest\logfiles\htmllog\hanging_thread_log-20231108-113102.html
Report: C:\RobotTest\logfiles\htmlreport\hanging_thread_report-20231108-113102.html
exception in thread causes backtrace at very end of execution.
Expectation: exception is handeled andproperly logged when the error happens
Code:
Log: