You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm opening this issue here to help ensure it gets fixed at source.
What I Did
It is preferable if an issue contains a Miminal Workable Example.
This will otherwise be one of the first questions you will get as a response.
It is also preferable if that example is not dependent on a specific peripheral device, but can be run and
reproduced with other BLE peripherals as well.
python two_devices.py
Exception has occurred: ValueError
a coroutine was expected, got <_GatheringFuture pending>
File "path to file", line 39, in <module>
"F0CBEBD3-299B-4139-A9FC-44618C720157",
ValueError: a coroutine was expected, got <_GatheringFuture pending>
Logs
Include any relevant logs here.
Logs are essential to understand what is going on behind the scenes.
This fixes several issues with the implementation. Notably, on Linux
trying to scan and connect to two devices at the same time results in:
bleak.exc.BleakDBusError: [org.bluez.Error.InProgress] Operation already in progress
This is worked around by using an asyncio.Lock to ensure only one scan
and connect is called at a time.
Fixes: #1036
Also fixes error due to main() not being a coroutine:
ValueError: a coroutine was expected, got <_GatheringFuture pending>
Fixes: #1288
Finally, command line args are added to make it easy to run the example
without modifying the code.
This fixes several issues with the implementation. Notably, on Linux
trying to scan and connect to two devices at the same time results in:
bleak.exc.BleakDBusError: [org.bluez.Error.InProgress] Operation already in progress
This is worked around by using an asyncio.Lock to ensure only one scan
and connect is called at a time.
Fixes: #1036
Also fixes error due to main() not being a coroutine:
ValueError: a coroutine was expected, got <_GatheringFuture pending>
Fixes: #1288
Finally, command line args are added to make it easy to run the example
without modifying the code.
bluetoothctl -v
) in case of Linux:Description
Describe what you were trying to get done.
Tell us what happened, what went wrong, and what you expected to happen.
This was raised as an issue on Stackoverflow:
https://stackoverflow.com/q/76101907/7721752
I'm opening this issue here to help ensure it gets fixed at source.
What I Did
It is preferable if an issue contains a Miminal Workable Example.
This will otherwise be one of the first questions you will get as a response.
It is also preferable if that example is not dependent on a specific peripheral device, but can be run and
reproduced with other BLE peripherals as well.
Logs
Include any relevant logs here.
Logs are essential to understand what is going on behind the scenes.
See https://bleak.readthedocs.io/en/latest/troubleshooting.html for information on how to collect debug logs.
If you receive an OS error (
WinError
,BleakDBusError
,NSError
, etc.), Wireshark logs of Bluetooth packets are required to understand the issue!The text was updated successfully, but these errors were encountered: