The 'turning ugly' is a tactic.
The putting-together of a tactic is crafted-around a pre-packaged response. Can well-meaning, innocent, Trump-supporting protest 'amateurs' be coaxed into appearing to be rioting... ? -Thus the crafted response is for a riot.
What's the most glaring omission from traditional riots we've seen everywhere thru-out human-history? The second day of rioting. Where was it? To me, that's the clue of why this situation seems manufactured.
So the tactic played-out, but Trump couldn't be faulted because the response was too tied-to its original intent. And the Capitol Police didn't behave how the original intent 'intended' them to.