Skip to content

Commit

Permalink
Add load id to metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
sultaniman committed Mar 5, 2024
1 parent 500942a commit b5a5f84
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dlt/common/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,9 @@ def asdict(self) -> DictStrAny:
if self.metrics:
d["started_at"] = self.started_at
d["finished_at"] = self.finished_at
d["metrics"] = [dict(metric) for metric in self.metrics.values()]
d["metrics"] = [
{**dict(metric), "load_id": load_id} for load_id, metric in self.metrics.items()
]
return d

def __str__(self) -> str:
Expand Down

0 comments on commit b5a5f84

Please sign in to comment.