Exception Handling - USB device disconnects.
pymenow opened this issue · comments
pymenow commented
Whats the best way to catch exceptions like these from the custom script.
!!! transfer not completed: status=4
!!! transfer not completed: status=4
!!! transfer not completed: status=5
!!! transfer not completed: status=5
CAUGHT
Exception ignored on calling ctypes callback function: <bound method USBTransfer.__callbackWrapper of <class 'usb1.USBTransfer'>>
Traceback (most recent call last):
File "C:\Users\thisi\AppData\Roaming\Python\Python39\site-packages\usb1\__init__.py", line 327, in __callbackWrapper
callback(self)
File "D:\Anaconda3\lib\site-packages\bumble\transport\usb.py", line 284, in on_packet_received
exit()
File "D:\Anaconda3\lib\_sitebuiltins.py", line 26, in __call__
raise SystemExit(code)
SystemExit: None
!!! transfer not completed: status=5
CAUGHT
Exception ignored on calling ctypes callback function: <bound method USBTransfer.__callbackWrapper of <class 'usb1.USBTransfer'>>
Traceback (most recent call last):
File "C:\Users\thisi\AppData\Roaming\Python\Python39\site-packages\usb1\__init__.py", line 327, in __callbackWrapper
callback(self)
File "D:\Anaconda3\lib\site-packages\bumble\transport\usb.py", line 284, in on_packet_received
exit()
File "D:\Anaconda3\lib\_sitebuiltins.py", line 26, in __call__
raise SystemExit(code)
SystemExit: None
Gilles Boccon-Gibod commented
Hi. Can you tell me a bit more about the specific scenario here. Is this a trace for when you unplug the USB device? Or some other error condition?
pymenow commented
While running an app just unplug the bluetooth USB.
This actualy simulated power management related senarios that eventually cause the BT USb device to disconnect