X2CommunityCore / X2ModBuildCommon

An improved XCOM 2 mod build system
MIT License
5 stars 5 forks source link

Build should fail when encountering errors in SDK cleanup #54

Closed robojumper closed 3 years ago

robojumper commented 3 years ago

There's a large try / finally block that cleans up the SDK from its temporarily invalid state from cooking. I/O errors during cleanup are reported in the middle of the log and then ignored because we need to clean up as much as possible, even when one individual cleanup step fails.

https://github.com/X2CommunityCore/X2ModBuildCommon/blob/3fef85d111c2dbad2b6cd89caa25b9601543ba09/build_common.ps1#L849-L921

However, the SDK is still in a potentially invalid state. This should be reported at the end of the build and the build should fail so that users can investigate.