Open jacopo-massa opened 4 years ago
Even if block=True, the function is still run in a separate through. The blocking appears to be done artificially solely for the purpose of enabling different execution flows.
https://github.com/sankalpjonn/timeloop/blob/master/timeloop/app.py#L38-L41 https://github.com/sankalpjonn/timeloop/blob/master/timeloop/app.py#L64-L65
I'm using timeloop with pybluez to discover bluetooth devices every x seconds. But during the loop, the following warning is printed:
WARNING: nextEventMatchingMask should only be called from the Main Thread! This will throw an exception in the future.
I'm running the loop in the main thread with
tl.start(block=True)
And the loop doesn't continue. How can I solve this problem?