Skip to content

Commit

Permalink
Merge pull request #2328 from cta-observatory/pipe-down
Browse files Browse the repository at this point in the history
Make provenance information in log optional
  • Loading branch information
kosack committed Jun 30, 2023
2 parents 3f21780 + 7ec41c8 commit 0f97f75
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ctapipe/core/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -456,7 +456,9 @@ def write_provenance(self):
output_str = " ".join([x["url"] for x in activity.output])
self.log.info("Output: %s", output_str)

self.log.debug("PROVENANCE: '%s'", Provenance().as_json(indent=3))
self.log.debug(
"PROVENANCE: 'Details about provenance is found in %s'", self.provenance_log
)
self.provenance_log.parent.mkdir(parents=True, exist_ok=True)
with open(self.provenance_log, mode="a+") as provlog:
provlog.write(Provenance().as_json(indent=3))
Expand Down
1 change: 1 addition & 0 deletions docs/changes/2328.feature.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Remove writing the full provenance information to the log and instead simply refer the reader to the actual provenance file.

0 comments on commit 0f97f75

Please sign in to comment.