If you have an intern or a Junior Engineer, they should have a more senior engineer to monitor and mentor them.
In the situation where a Junior Engineer gets blamed for a screw up:
1. The Senior Engineer failed in their responsibility. 2. The Senior Engineer failed in their responsibility.
A Junior Engineer should be expected to write bad code, but not put it into production, that's on the Senior. If I hit approve on a Junior Engineer's PR, it's my fault if their code brings the whole system down. If a Junior Engineer had the ability to push code without a review, it's my fault for allowing that. Either way it's my fault and it shouldn't be any other way. It's a failure to properly mentor. Not saying it doesn't happen, just that it's never the Junior Engineers fault when it does.