But it would be nice to actually SEE tech consistency in Trek.
Set up guidelines where each show in a given era should work with and work the story around that.
On Ds9 that was only a problem because the station was Cardassian in origin.
If you noticed, most of the UI on Ds9 was Cardassian... suggesting that the station was NEVER purged of Cardassian software 100%.
And Cardassians love their booby traps it seems.
The chances of a 'bad software update' are pretty much a rarity on SF ships... and besides, NOTHING is necessarily 100% safe.
The crews take chances every single time they go to Warp or use any kind of system
Point is, with that analogy, every single system on the ship can easily become a problem under the right circumstances... and you can't be living under that kind of paranoid state... which would mean, you wouldn't be cut out for Starfleet or serving on ships in general (also, Trek Computers DO run a huge number of things on board).
The automated defensive systems would only come online when necessary (when the ship is engaged in combat - just as a state of readiness to fight off potential invaders). They can pop out of the walls and would ALWAYS be set to heavy stun (SF default)... never vaporize (in fact, I'd just prevent internal automated systems from being able to achieve high enough yields to vaporize people - aka, the vaporize setting wouldn't exist for automated internal systems).
Forcefields automatically popping up to contain boarding parties should also be a thing... but SF ships should really have transporter inhibitors integrated onboard which would also come online during yellow and red alerts - and only authorized crew members can let certain aliens beam in or out.
Discovery was an outlier because I scoffed at the notion that the writers went into a direction of a sentient AI that wants to destroy everyone... an outdated and stupid trope I hoped to NEVER see in Trek again... it was just badly written alltogether.
And besides, SF ships in the 24th century demonstrated internal defensive and offensive capabilities.... the writers simply forgot about them over time or just ignored them.