Closed tomaszkob89 closed 3 years ago
Thanks for the submission.
I believe that setting the daemon
flag is not a proper solution to what you are describing. All threads should exit cleanly when told to do so. Could you provide a stack trace of the thread that refuses to terminate?
This issue is not reproducing 100%, I observed it few times while testing locally and one time while running CI suite on Jenkins. For now, I don't have a stack trace, but if my memory serves me right, the thread, that was still alive after .join() was "serial_writer" (but I may be wrong)
better solution for my problem in PR: https://github.com/NordicSemiconductor/nRF-Sniffer-for-802.15.4/pull/48
Sometimes not all threads, started by sniffer, are stopped after executing "stop_sig_handler" which leads to suspended scripts/tests (sniffer threads are still alive after main thread is closed)