Improved reporting of failed scripts and added failure message