List all the arduinos attached to my Mac

I have 3 Arduino Micros connected via USB to my Mac, communicating via the serial-over-USB interface. They all work perfectly. But to interface to them from my code I'm currently looking in directory /dev and guessing which filenames correspond to the serial ports I want. What is the correct way to enumerate the serial devices for each connected Arduino?

(I'm currently working with Python, so a Python solution would be ideal. I'm able to enumerate the USB devices and use the Vendor ID to detect that I have three attached Arduinos. But that doesn't tell me where the serial ports are.)

You'd need to download the bootloader source, change the "product description", and upload a new, uniquely-named bootloader to the Micro. Then it's just up to you and Python to read the product description of the attached device to determine which is which.

http://galvant.ca/how-to-compiling-arduino-caterina-with-new-vidpid/