Yes I believe it's often very loose. Just because a position is open, not all those HAVE to be filled, and even if so, not immediately. The urgency isn't there. Also, the mgmt may not be in sync on the role.
A number of things need to fall exactly into place for them to pull the trigger on the offer. Smart technical people I think tend to think Sr. management and processes must be sensible and completely aligned. "How could they not be..". HR can have some of the biggest nut cases..
Not there is anything much to be done about it, although it is wrong to waste peoples' time. I tend to not put much stock in what I'm told about the reasons, in that situation anyway.
Sadly, some companies are disorganized. Many companies are more disorganized when hiring because they are short staffed.
Once, I went thru 3 rounds of in-person interviews. They weren't sure what they wanted me to do, so they tried to cobble together a role with 4 hats and touching almost every area of the business.
After meeting both CEOs, I realized there was a disagreement between the 2 CEOs and the Director of IT. The Director wanted to hire me, but the CEOs didn't see the need. And since I am not good at selling myself, the CEOs won the disagreement.
I have found a fair number of companies don't have their hiring process figured out in any meaningful way. It sucks to feel like you've wasted a lot of time interviewing (not to mention any excitement about the opportunity and its possibilities), but you should take solace in the fact that you do not now work at a company where they have these kinds of issues. Keep your head up!