California cities struggle with implications of homeless ruling