It isn't the shrapnel from flywheel failure that's hard to deal with. Frag containment, particularly of composite rotors that have high volume fractions of fiber and low volume fractions of binder, is actually pretty easy.
What's really hard to deal with is the angular momentum. Regardless of how the rotor fragments, angular momentum is conserved. What this means is that the failing rotor will produce amazingly high torques as it encounters stationary surroundings.
For typical rotor failures, you can figure that most of the angular momentum will get dumped into the environment in a few seconds as the fragments dig into whatever they hit and come to rest. So as a napkin exercise, if your flywheel spins up to full charge over a period of an hour, and then dumps all that momentum during ten seconds when it fails, you can kind of approximate the torque drama by multiplying the charging torque times the ratio of the charge duration to the failure duration. (I know the torque varies with the flywheel speed, etc. - this is just a disaster estimation exercise.)
The practical effect is that you have to secure the containment really well to make sure it doesn't break loose and roll through your facility on its way out into the street.
The only two ways I've seen of dealing with the angular momentum problem are (1) have two adjacent counter-rotating wheels that jam into each other when there's a failure or (2) have a containment shell that is free to rotate on one-time use mechanical bearings so it can take the failed rotor momentum and dissipate it over a reasonable time with a braking mechanism. Neither solution is cheap.