There are lots of bullies out there who will hurt you if they can get away with it. Some of them are official cops. Some of them are unaffiliated shitstains.
If you are armed, they will think twice about starting shit.
The Black Panthers knew this. That's why they went armed to patrol the police. (Then people who were afraid of the Black Panthers passed laws to stop that.)
Protests without armed people "turn violent", by which we really mean, cops go nuts and beat the shit out of people.
Protests with armed people tend to keep the cops restrained, and they have significantly less injury and death.
The weapons serve as a deterrent. Because bullies think they can win in a melee, but they don't want to be killed, and their targets are showing that capacity.
I don't like it. I wish we could have peaceful protests without the cops going wild. I wish we could have peaceful protests without the clowns who want to freak out starting fires and robbing stores.
But humans are what they are, and those risks are there.
Armed deterrence is a move that can be made.
Understand that, and take into account that some people will chose to make that move.
You don't have to like it. But acting surprised by it means you don't know what's going on.