Throwing error in lifecycle hook doesn't stop script from executing

if a component is added to an entity, then it continues to save values when an exception/error is triggered. Does anyone know how to prevent this?