Closed araichoor closed 8 months ago
Thanks for the quick fix. As a maintenance detail, I changed fn.replace('redrock', 'zmtl')
to desispec.io.util.replace_prefix(fn, "redrock", "zmtl")
which will replace only the prefix of the filename, but not other places where "redrock" might appear, e.g. in a SPECPROD="test_redrock" path.
With this PR, the night_qa
create_petalnz_pdf()
now parses theredrock*fits
files to identify the processed petals, instead of thezmtl*fits
file.It addresses https://desisurvey.slack.com/archives/C01HNN87Y7J/p1703203812637849. I.e. when we archived+mtl-updated a tile, then realized a petal was bad, so we re-process the tile, with creating a "dummy"
zmtl*fits
file (but no redrock or other files). Thecreate_petalnz_pdf()
function was looking forzmtl*fits
files to parse the existing petals. Here it would find the "dummy"zmtl*fits
file, but then crash as there s noredrock*fits
file.I ve successfully run on night here: https://data.desi.lbl.gov/desi/users/raichoor/nightqa_dev/nightqa_v25/20231209/.