improvements in build error handling, bug fixes