Add pre-flight checks to prevent lost work on silly errors