Skip to content

Commit

Permalink
feat: Update error message for incompatible task types
Browse files Browse the repository at this point in the history
  • Loading branch information
provos committed Sep 1, 2024
1 parent 7434075 commit e79d7cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/planai/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ def register_consumer(self, task_cls: Type[Task], consumer: "TaskWorker"):

if task_cls not in self.output_types:
raise ValueError(
f"Task {self.name} cannot publish work of type {task_cls.__name__}"
f"Downstream consumer {consumer.name} only accepts work of type {task_cls.__name__} but Worker {self.name} does not produce it"
)

if task_cls in self._consumers:
Expand Down

0 comments on commit e79d7cf

Please sign in to comment.