[Python-modules-team] Bug#476796: usb.USBError: No error, workaround

Paul Sladen debian at paul.sladen.org
Thu Mar 19 11:29:14 UTC 2009

In the meantime, for anyone else who hits this bug while coding with pyusb
and gets the message:

  usb.USBError: No error

I used the following kludge, which likely will also work for you:

      data = fd.interruptRead(endpoint.address, endpoint.maxPacketSize)
  except usb.USBError as e:
      if e.args != ('No error',): # http://bugs.debian.org/476796
          raise e

Why do one side of a triangle when you can do all three.  Somewhere, GB.

More information about the Python-modules-team mailing list