What planet are you living on? This is not the case in any major US city, let alone San Francisco.
Yeah, I think how "sketch" the mid-atlantic cities are is mostly overrated by people afraid of black people. The mentally ill on the street are much more concerning safety-wise for me.
But it's pretty easy to avoid. SF seems to have more open air suffering spread throughout.
I never felt unsafe anywhere in San Francisco. That was the least of my concerns while I was in that dystopian dump.
* I watched a man push another man into the street. The man pushed into the street drew a knife on the first man. This was around noon (we were out for lunch), in broad daylight. McAllister & Leavenworth
* I was openly approached to buy what was most likely not legal drugs. (I was noping out of there and trying to position myself between him & my now-finacée as fast as possible, so I couldn't really tell you.) ~10:30p, 8th & Folsom.
* Not technically SF, but a man entered the Caltrain car I was on screaming obscenities, muttering to himself, and making death threats to those in the car simply for looking at him. Sometime in the evening, slightly north of MTV. I believe he was detained at MTV.
Not to say I've not seen other stuff in other cities. But, "never felt unsafe anywhere in SF" … yeah, no. Esp. around Civic center, it's super sketch. (That said, the original "lawless" and "dangerous to enter into" comment is also overboard. SF is a fine city, parts of it are quite nice. But there are parts where you should have your wits about you, too.)
What I'm more used to is growing up in a bad neighborhood in Chicago in the 90s where I actually felt unsafe because the odds of getting robbed at gunpoint or getting beat up were very high. "Walking around" meant avoiding specific areas, avoiding alleyways, getting away from groups, not traveling alone, not having anything worth more than a dozen dollars on me or any clothing worth more than that, etc.
But yes, I was in the Tenderloin at 1 am on a weekday and felt unsafe and was followed by some people saying they would kill me. ¯\_(ツ)_/¯
The government and people of SF squandered years of opportunity to clean up the city, make it more affordable to live here (is there pride to be had in being the most expensive place to live?), implement sound policies, focus on the right things, and get people to make long term better decisions. They did very little of that preparation. It's like building up points for when hard times come.
Instead, they continued to enable housing restrictions to drive up rents like crazy (acknowledging that this is a California-wide problem I admit), letting entrenched owners interests combine with ridiculous things like rent control and "neighborhood preservation", failing to take a harder line on open air drug use and crime, letting Muni and Bart become public toilets that charge optional admission fees where you also are at risk of getting stabbed, etc. etc. the list goes on and on. Overlooking quality of life issues in favor of being tolerant of anything that someone would object to having restrictions on or less charitable approaches to.
And now, as the reality of the virus situation has exposed what people really prefer to do, they fled, and the impact to local businesses, tax base, etc. will be felt for years to come. Parts of the city are lawless and a danger for people to venture into. Good thing that all the supervisors were concerned with gender neutral bathrooms while fewer and fewer people could afford to live here to enjoy them.
I'm not a conservative. I'm not a Trump supporter. But even I can see that SF shot itself in the foot.