Make calwebb_tso3 more robust #5107
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A user recently reported that MIRI imaging TSO data were going through the spectroscopic branch of the
calwebb_tso3
pipeline, which turned out to be due to the fact that the TSOVISIT keyword was missing. These updates make thecalwebb_tso3
pipeline more robust to that kind of obvious problem with the input data and causes it to issue an error message and abort. Also needed to update theis_tso
helper function, because it was assuming that anyCubeModel
data were TSO, which is not correct: coronagraphy data is alsoCubeModel
. Also just did a little general clean-up and addition of comments, etc. to the modules involved, as well as adding a description of the keyword logic to the docs.At some point we should probably also try to figure out how to update the
extract_1d
andwhite_light
steps to have them figure out if they've actually been given spectroscopic data as input and if not, then abort. Before the updates here, MIRI imaging data actually somehow made it through both of those steps, which is crazy.