An Agno workflow emits StepError when a step's executor raises and when it returns an explicitly failed output. The event carries the failed step's name and index.
When a nightly billing run stops partway, StepError tells you which step broke without reading back through the whole stream.
StepError fires when the failure stops the workflow, as it does for a step with HumanReview(on_error="fail"). A step left on the default on_error="skip" is skipped, and the workflow carries on.
from agno.workflow import HumanReview, Step
charge = Step(name="charge_cards", executor=charge_cards, human_review=HumanReview(on_error="fail"))
try:
for event in workflow.run("Run nightly billing", stream=True, stream_events=True):
if event.event == "StepError":
print(f"{event.step_name} failed: {event.error}")
except Exception:
pass # the stream re-raises the original error after WorkflowErrorBoth console streaming printers render StepError directly. They show the original failure and clear any progress output left over from the step.

Function reports still arrive as StepOutput, and Agent, Team and nested Workflow steps keep their existing stream.
Learn more about handling step errors in the documentation.
Frequently asked questions
Stream the run with stream=True, stream_events=True and watch for a StepError event. The event carries the name and index of the failed step, and event.error holds the failure.
Agno emits StepError when a step's failure stops the workflow, as it does for a step with HumanReview(on_error="fail"). With the default on_error="skip", Agno skips the failed step and the workflow keeps going.
No. Function steps keep streaming their reports as StepOutput, and Agent, Team and nested Workflow steps stream the same events as before. See handling step errors in the documentation.




