The rich having their ways and driving everyone else out is one way to create an area full of happy people. The problem is, you're just not counting the people who were screwed over by that strategy.
You can't bar anyone from cities. You can't bar them just like they can't bar you. It isn't policy that's driving anyone out. It's pricing, which is above the control of any one person or even group of people.
Some people will be forced out due to pricing. The local economy of every city is going to be unworkable at some income floor. The more expensive the city, the higher the floor.
If that floor is higher than what you make, it doesn't mean that no poor people live in SF. It just means that they feel poor even at a relatively higher income.
To illustrate, 80k per year is still a decent income in some towns. But it is definitely poor in NYC.