changed build so script can listen to errors