Fixes for error when puppet apply fails