The first issue, where multiple monitors have the same vendor/model/manufacture date/serial number, couldn't that be solved by also storing which port it's connected to? That way, if you have two HDMI ports, if both monitors have the same UUID, you store settings based on port rather than UUID. I don't know if this is possible with this new USB-C world, but at least with traditional hardware, it seems like the OS knows which port a monitor is connected to.

Anyways, interesting post. It's always fun to discover how much hardware is just broken and doesn't actually correctly implement the protocols or features it's supposed to implement.

I strongly suspect that this is not the full picture.

I had this exact same issue, two displays, always connected to the same TB3 Dock, and they would randomly get re-assigned after wake-up. Which in my case was doubly irritating, since one of those is in portrait mode, so "fixing it" required tilting my head to be able to navigate the mouse correctly.

There's a small CLI utility called `displayplacer`[1], that basically fixed this for me. I don't... really know what exact EDID fields or whatever metadata it's reading, but after I used it once to "save" the correct orientation/placement, I could reset it to the "correct" one every time after that. Highly recommended if that's something you're struggling with.

[1]: https://github.com/jakehilborn/displayplacer