In a case where I had evidence that a dog or coyote attacked a child (injuries, tooth marks on clothes, video, witnesses, whatever) I am fairly certain I would not have had any negative consequences for shooting the aggressive animal in the suburb I used to live - assuming I didn’t mess it up and put a round into an occupied vehicle or something.
Where I live now it is hard to imagine anyone ever even calling the cops for gunfire, much less the police responding to it.