Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

List Index Out of Range

See original GitHub issue

Hi Corpnewt,

First of all, thanks for creating this awesome tool. I’m trying to figure out my USB port mapping on my first Hackintosh build and was recommended to try using this tool. Unfortunately, I am getting the following error when attempting to discover ports:

Traceback (most recent call last): File "./USBMap.command", line 2214, in <module> u.main() File "./USBMap.command", line 2130, in main p = File "./USBMap.command", line 285, in discover original = self.get_by_port() File "./USBMap.command", line 247, in get_by_port pnum = int(m.split("@")[1][:3], 16) IndexError: list index out of range

Any ideas what could be causing this and what I might be able to do to fix it?

Thanks so much!

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

corpnewtcommented, Oct 8, 2019

I reread the error - and I was looking at the wrong line it seems. This specific line in your usb.txt appears to have been falsely matching:

+-o SanDisk Ext SSD@14530000  <class IOUSBHostDevice, id 0x100000384, registered, matched, active, busy 0 (129 ms), retain 24>

As it contains @1, USB, and does not contain HS15. I pushed a commit but haven’t been able to test it yet. If you wouldn’t mind confirming that it fixes the issue, I’d appreciate it. It just verifies the line contains AppleUSB[##][XXXX]Port where the # is a number, and the X is a letter (to match XHCI, EHCI, 30, 20, etc).



corpnewtcommented, Oct 9, 2019

Glad to hear it 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

List Index Out of Range – Python Error Message Solved
You'll get the Indexerror: list index out of range error when iterating through a list and trying to access an item that doesn't...
Read more >
Python IndexError: List Index Out of Range Error Explained
Learn how to resolve the Python IndexError, list index out of range, why it occurs in for loops, while loops, and how to...
Read more >
Indexerror: list Index Out of Range in Python - STechies
“List index out of range” error occurs in Python when we try to access an undefined element from the list. The only way...
Read more >
Python IndexError: List Index Out of Range [Easy Fix] - Finxter
The error “list index out of range” arises if you access invalid indices in your Python list. For example, if you try to...
Read more >
Index Error: list index out of range (Python) - Stack Overflow
Generally it means that you are providing an index for which a list element does not exist. E.g, if your list was [1,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found