"Could not initialize libusb. Check that your system has a usb controller." on Travis CI
See original GitHub issueFor some reason I get that error only when running inside a Travis CI job.
I tracked down the error to libusb_init
(http://libusb.sourceforge.net/api-1.0/group__lib.html#ga9517c37281bba0b51cc62eba728be48b). Do you have any clues about why that’s failing, and how we can at least workaround it?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:7 (2 by maintainers)
Top Results From Across the Web
"Could not initialize libusb. Check that your system has a usb ...
For some reason I get that error only when running inside a Travis CI job. I tracked down the error to libusb_init ...
Read more >"Could not initialize libusb. Check that your system has a usb ...
For some reason I get that error only when running inside a Travis CI job. I tracked down the error to libusb_init (http://libusb.sourceforge. ......
Read more >View topic - [SOLVED] unable to initialize libusb: -99
My system does not recognize USB drives, kernel configuration seems to be OK ... uhci_hcd: USB Universal Host Controller Interface driver
Read more >Diff - platform/external/libusb - android Git repositories
+ +On Linux, this is easy: the usbfs kernel interface exposes a file descriptor +which can be passed to poll(). If something similar...
Read more >asynDriver: Asynchronous Driver Support ... - epics-modules
Fixed a problem with output records that have the asyn:READBACK info tag, ... Previously if a client was connected and the IOC exited...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@agirorn If you want to make a PR removing this
throw
, I think the better API would be to check whether initialization failed ingetDeviceList
and anything else that can be called without a device, and make those functions throw an exception.Why does this module throw this error here usb.js#L11 this means that every code that requires this module needs to guard it is self against this (bug I think) even if it is not going to use the USB, and just wants go require it in the top of the js file and then later on do some feature detection.
Since the property
INIT_ERROR
is already on the module it should be enough to silently ignore this and allow the user of the module to decide how he want’s to handle this scenario.Would you accept a pull request that removes this check and adds the available function a simple and clean API to check if USB has been detected?