Skip to content

Commit

Permalink
Merge branch 'tickets/DM-26953' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
kfindeisen committed Oct 2, 2020
2 parents f56257d + e02bdec commit 039d31e
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
12 changes: 12 additions & 0 deletions config/export.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1179,6 +1179,18 @@ data:
host: null
timespan_begin: null
timespan_end: null
- type: collection
collection_type: RUN
name: skymaps
host: null
timespan_begin: null
timespan_end: null
- type: collection
collection_type: RUN
name: templates/deep
host: null
timespan_begin: null
timespan_end: null
- type: dataset_type
name: camera
dimensions:
Expand Down
4 changes: 2 additions & 2 deletions preloaded/gen3.sqlite3
Git LFS file not shown
9 changes: 9 additions & 0 deletions scripts/add_gen3_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ def main():
_migrate_gen2_to_gen3(dataset, gen2_repo, gen2_calibs, gen3_repo, mode="copy",
config_file="convertRepo_copied.py")

# ap_verify assumes specific collections are present
log.info("Adding unpopulated collections...")
butler = daf_butler.Butler(gen3_repo, writeable=True)
butler.registry.registerCollection("skymaps", daf_butler.CollectionType.RUN)
butler.registry.registerCollection("templates/deep", daf_butler.CollectionType.RUN)

log.info("Exporting Gen 3 registry to configure new repos...")
_export_for_copy(dataset, gen3_repo)

Expand Down Expand Up @@ -123,6 +129,9 @@ def _export_for_copy(dataset, repo):
# before ingest.
for collection in butler.registry.queryCollections(..., collectionTypes={daf_butler.CollectionType.CALIBRATION}):
contents.saveCollection(collection)
# Export empty template collections
contents.saveCollection("skymaps")
contents.saveCollection("templates/deep")


if __name__ == "__main__":
Expand Down

0 comments on commit 039d31e

Please sign in to comment.