The police could have left her alone and come back later. They were in her house, and she was only threatening to harm the officers, not her child.
It's also intolerable in a society with the rule of law that someone could opt out of being subject to the law by waving a gun around and refusing to comply with a lawful order from the police. If that worked, everyone would do it. It would be impossible to enforce the law.
If she didn't have a child with her, maybe they could have waited her out. They had already been there for quite a while before they decided to act. But to suggest that they just walk away and come back later is absurd.