Reviving the War on Drugs in SF is not going great: "the crackdowns have[n't] prevented overdose fatalities, reduced street violence, [or] improved neighborhood conditions... At best, enforcement strategies have improved some blocks at the expense of others, while creating turf wars that have increased gun violence. We need to use a comprehensive strategy with evidence-based solutions." - @deanpreston
This is a solved problem. You make rehab (real rehab) available. Decriminalize and distribute methadone and Suboxone use this to steer people towards rehab and make it cheaper than the drugs which you decriminalize for users.
Then have proper social services to deal with the reasons people self medicate with these drugs.