Prior to spacetelescope/romanisim#337 romanisim generated valid L2 files that did not contain a meta.cal_step. These files cause issues for romancal which assumes all L2 files have meta.cal_step. One example is in the flux step:
|
if model.meta.cal_step["flux"] == "COMPLETE": |
fails on L2 files that do not have a
meta.cal_step.
This could be addressed by updating the pipeline to avoid accessing cal_step directly and instead using some to-be-determined API for accessing the cal_step attribute. There is unused and unfinished code in Step for recording the status:
|
def record_step_status(self, model, step_name, success=True): |
jwst took a different approach implementing 2 utility functions:
which could be borrowed here.