I think both extremes look bad. Somebody who has had 24 jobs in the last 24 months looks pretty bad. Somebody who has had 1 and only 1 job in the last 24 years also looks rather bad -- depending on the field. If it was a librarian and that's what you're looking to hire, great. But I've noticed that as a general rule, in the software field, if somebody stays at the same employer for 10-20 years, that's usually a bad sign. Not always, but generally.
Also think if you were in the software field in the mid/late 90's and you were NOT job hopping, in some sense, you were probably not being very smart. Because there was so much demand for our skills that you could almost always get more money by moving on. Once all the frothy demand died down, yes, it tended to become smarter to stay. But all of this -- all of it -- is just generalizations. People leave jobs for all sorts of reasons which do not or should not reflect badly on them. Family, sickness, education, career growth, moving to a better home or community, etc.
I think loyalty is more important at a startup than at a larger, more established business. But never EVER assume the business will be loyal to you, the employee. If you're lucky, they will, but don't assume that. The whole point of the business is to maximize profit for the owners, and the executive/managerial class sometimes really is just out for their own best interests, even if that means canning employees and/or shutting down entire lines of business that otherwise are staffed with good people doing good work. They look at the numbers, and may often "do what the numbers tell them." Likewise, an employee can analyze matters in the same way. It's fair.
As much as I support job changing (see my other comments), it's perfectly fine to stay at the same job for 24 years (heck, why not 50?) if it's really good, you're constantly growing, and can demonstrate a rising skill curve throughout.
Your extreme suspicion of anyone who stays for so long reveals a more fundamental truth about the software industry: very few companies manage to keep employees happy and challenged for so many years.