Personal hotspot is one of those iPhone features that I use a lot. And on the whole it's been quite reliable. However, over the past few days I've had problems getting my MacBook Pro to connect.
This is the problem I was seeing. I could see my iPhone, and I could connect to it, but it took multiple connections and disconnections to give me access to the internet.
Needless to say, this was annoying, and it sent me on a long journey to find the solution.
And it turns out the solution is pretty simple.
First off, there are a lot of "solutions" for this problem out there. I tried dozens, and none of them worked. I was confident that the issue was related to my Mac and not my iPhone because other devices had no problem connecting to the iPhone.
I won't bore you with all the failed attempts, but while I was looking around in the macOS Network Preferences panel, (Go to System Preferences, click on Network, make sure Wi-Fi is selected in the left pane, and click Advanced…), I noticed that in the list of Preferred Networks, there was an entry with my iPhone's name.
That didn't seem right.
I deleted it (by selecting it and pressing the - at the bottom of the panel), closed the screen and my connection started working immediately.
I went back and cleared out a few years' worth of network detritus from the listing, old networks, networks at cafes in foreign countries, old Airbnb's, and test networks. I don't think that achieved much, but the listing is now a lot cleaner to parse.