Keck-DataReductionPipelines / KCWI_DRP

KCWI python DRP
BSD 3-Clause "New" or "Revised" License
8 stars 12 forks source link

Precondition logging in MakeMasterFlat is misleading #78

Open MNBrod opened 3 years ago

MNBrod commented 3 years ago

The requirements logged in MakeMasterFlat's precondition

self.logger.info(f"pre condition got {len(self.stack_list)},"
                             f" expecting {self.action.args.min_files}")

doesn't match the actual test,

if len(self.stack_list) >= 1:
    return True
else:
    return False

Going by the logs alone, it looks like this primitive should fail more than it does. Fix is to adjust the logging statement to reflect the conditional below