Details
-
Type:
Bug
-
Status: Done
-
Resolution: Done
-
Fix Version/s: None
-
Component/s: pipe_base
-
Labels:
-
Story Points:0
-
Team:Architecture
-
Urgent?:No
Description
Running pipetask run --skip-existing option with a collection where partial outputs already exist fails like following:
Failed to build graph: '_QuantumScaffolding' object has no attribute 'taskDef' |
Traceback (most recent call last):
|
File "/software/lsstsw/stack_20200515/stack/miniconda3-4.7.12-46b24e8/Linux64/ctrl_mpexec/20.0.0-4-g936b1ea+1/bin/pipetask", line 26, in <module> |
sys.exit(CmdLineFwk().parseAndRun())
|
File "/software/lsstsw/stack_20200515/stack/miniconda3-4.7.12-46b24e8/Linux64/ctrl_mpexec/20.0.0-4-g936b1ea+1/python/lsst/ctrl/mpexec/cmdLineFwk.py", line 474, in parseAndRun |
qgraph = self.makeGraph(pipeline, args)
|
File "/software/lsstsw/stack_20200515/stack/miniconda3-4.7.12-46b24e8/Linux64/ctrl_mpexec/20.0.0-4-g936b1ea+1/python/lsst/ctrl/mpexec/cmdLineFwk.py", line 620, in makeGraph |
qgraph = graphBuilder.makeGraph(pipeline, collections, run, args.data_query)
|
File "/software/lsstsw/stack_20200515/stack/miniconda3-4.7.12-46b24e8/Linux64/pipe_base/20.0.0-2-g04cfba9/python/lsst/pipe/base/graphBuilder.py", line 789, in makeGraph |
scaffolding.resolveDatasetRefs(self.registry, collections, run, skipExisting=self.skipExisting)
|
File "/software/lsstsw/stack_20200515/stack/miniconda3-4.7.12-46b24e8/Linux64/pipe_base/20.0.0-2-g04cfba9/python/lsst/pipe/base/graphBuilder.py", line 654, in resolveDatasetRefs |
f"Quantum {quantum.dataId} of task with label " |
AttributeError: '_QuantumScaffolding' object has no attribute 'taskDef' |
My steps to reproduce this using a built ci_hsc_gen3 repo, with w_2020_27 :
# first run the ISR part and establish the output collection
|
pipetask run -b $CI_HSC_GEN3_DIR/DATA/butler.yaml -i HSC/calib,HSC/raw/all,HSC/masks,ref_cats,skymaps,shared/ci_hsc --output debug02 -t lsst.ip.isr.IsrTask:isr -d "exposure = 903334 and detector = 22" --instrument lsst.obs.subaru.HyperSuprimeCam |
|
# Check the output collection in the datastore, obtain the run timestamp
|
# Replace these two commands with the correct timestamp
|
# Touch an empty file so to intentionally make the next pipetask command fail
|
mkdir -p $CI_HSC_GEN3_DIR/DATA/debug02/20200706T14h50m08s/icSrc/r/HSC-R/903334/ |
touch $CI_HSC_GEN3_DIR/DATA/debug02/20200706T14h50m08s/icSrc/r/HSC-R/903334/icSrc_r_HSC-R_903334_22_HSC_debug02_20200706T14h50m08s.fits |
|
# Run processCcd the first time. This should fail due to FileExistsError.
|
# I do this to make it fail (presumably) after writing out partial outputs |
pipetask run -b $CI_HSC_GEN3_DIR/DATA/butler.yaml --output debug02 -p $PIPE_TASKS_DIR/pipelines/ProcessCcd.yaml -d "exposure = 903334 and detector = 22" --instrument lsst.obs.subaru.HyperSuprimeCam --extend-run --skip-existing |
|
# Then, remove the empty file (Replace the timestamp!)
|
rm $CI_HSC_GEN3_DIR/DATA/debug02/20200706T14h50m08s/icSrc/r/HSC-R/903334/icSrc_r_HSC-R_903334_22_HSC_debug02_20200706T14h50m08s.fits |
|
# Run again. This time it will hit the AttributeError
|
pipetask run -b $CI_HSC_GEN3_DIR/DATA/butler.yaml --output debug02 -p $PIPE_TASKS_DIR/pipelines/ProcessCcd.yaml -d "exposure = 903334 and detector = 22" --instrument lsst.obs.subaru.HyperSuprimeCam --extend-run --skip-existing |
I have a built ci_hsc_gen3 repo at /project/hchiang2/ci_hsc_gen3/w_2020_27/ci_hsc_gen3_copy/ on lsst-dev. Copying it may be faster than running your own copy.