A friend of mine went to court 3 times for assaulting police officers and never got a custodial. On the second occasion the beak told him 'come up before me again and I'll have no hesitation...'
On the third he's broken one copper's nose by headbutting him and they have a photo of the other copper with a bootprint across his face. But the judge still slung him.
The prisons are full and have been for years. Always makes me laugh when there's been some minor infraction and someone says 'Ooh you should report that to the Police.' They just have no concept of the reality.