0

I am using python 3.10 with pyUSB to fetch the information of connected usb devices using usb.core.find. Then I iterate trough them and have to get the device.port_numbers property for stuff afterwards.

In previous macOS version this worked find. But after switching to macOS Tahoe it does only return None. More specifically I’m using Tahoe 26.0..

Not sure if it has something to do with pyUSB or the underlying libusb.

Here my short troubleshooting script:

import usb.core

devices = usb.core.find(
     find_all=True,
)

for device in devices:
    print(device.port_numbers) # prints None, but should return something like [5,]…

Does someone know what’s going on or how to solve it? Greatly appreciate your help!

1 Answer 1

0

UPDATE: There's a fix to the libusb for macOS https://github.com/libusb/libusb/pull/1700

AFAIK there were some changes in macOS Tahoe for USB stuff:

To simplify, here are the old and new key for the ports identification:
Old: UsbConnector, port
New: usb-port-type, usb-port-number

So libraries like libusb and other Python-related USB might need an update on those.

Source: a hackintosh forum https://elitemacx86.com/threads/how-to-fix-usb-ports-on-macos-tahoe.2359/

As a workaround I started using the serial.tools from pip install pyserial on Tahoe.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.