added debug output for the scripts