During investigation of
DM-12672, I discovered several bugs in how ap_pipe and ap_verify handled data IDs:
- Most command-line tasks implicitly assume their run or runDataRef methods take a fully expanded data reference. This is provided by pipe.base.ArgumentParser, but ap_pipe's task runner inadvertently bypassed the data ID expansion. In practice, this meant ImageDifferenceTask didn't have all the information it expected.
- The same bypass would have prevented ap_pipe from processing multiple datasets specified as visit=#, though visit=# ccd=1..62 would have still worked.
- ap_verify always provided partial data references, because it assumed the run method (or, more precisely, its butler calls) would expand any unambiguous reference.
- The tests in test_ingestion.py were based on a naive view of how data IDs work, and most of the outstanding issues with the tests can now be fixed.