Skip to content

iterate_comports on Windows sometimes appends an incorrect interface indicator to the location of USB COM ports #802

@joshstrohminger

Description

@joshstrohminger

When calling serial.tools.list_ports.comports() on Windows, the ListPortInfo.location attribute of a USB COM port without multiple interfaces will have the interface number of a previously enumerated port incorrectly applied to it, ':x.0' for example. This is because the variable bInterfaceNumber is set to None in the outer GUID loop, and not the inner device loop.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions