SF can barely build a public toilet without it turning into a taxpayer trough feeding frenzy, so expecting it to be the Mecca of the homeless, the addicted and the downtrodden is comedic at best, and tragic at worst. Even if someone were to get back on their feet from addiction, SF is the last place where they would want to try to live, given the astronomical cost of everything, unless they're going to suddenly become senior ML engineers who can afford a downpayment on a $1M 500sqft cockroach shoebox.
Most people with regular jobs can't afford to live in SF... think school teachers driving in every morning from Sacramento, and that's without fighting every day against a crippling meth addiction.
There's practically infinite room in Bakersfield, Stockton, Lancaster, Fresno, housing is more affordable, the local governance more amenable, the cost of living night and day, but nobody in policy will ever be able to pull that off, so we'll be stuck with the current status quo that nobody is happy with.