Skip to content

Commit

Permalink
desispec.io.util.replace_prefix instead of str.replace
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen Bailey authored and Stephen Bailey committed Dec 22, 2023
1 parent 5bb618e commit fcee794
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion py/desispec/night_qa.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
# AR desispec
from desispec.fiberbitmasking import get_skysub_fiberbitmask_val
from desispec.io import findfile
from desispec.io.util import replace_prefix
from desispec.calibfinder import CalibFinder
from desispec.scripts import preproc
from desispec.tile_qa_plot import get_tilecov
Expand Down Expand Up @@ -1448,7 +1449,7 @@ def create_petalnz_pdf(
log.warning("{} : no file".format(fn))
else:
# AR switching to zmtl
fn = fn.replace("redrock", "zmtl")
fn = replace_prefix(fn, "redrock", "zmtl")
if not os.path.isfile(fn):
log.warning("{} : no file".format(fn))
continue
Expand Down

0 comments on commit fcee794

Please sign in to comment.