mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-10 08:38:30 +00:00
- Remove unused imports from various event and flow-related files - Reorder event imports to follow standard conventions - Remove unnecessary event type references - Simplify import statements in event and flow modules
28 lines
493 B
Python
28 lines
493 B
Python
from typing import Any, Optional
|
|
|
|
from crewai.utilities.events.crew_events import CrewEvent
|
|
|
|
|
|
class TaskStartedEvent(CrewEvent):
|
|
"""Event emitted when a task starts"""
|
|
|
|
type: str = "task_started"
|
|
context: Optional[str]
|
|
|
|
|
|
|
|
class TaskCompletedEvent(CrewEvent):
|
|
"""Event emitted when a task completes"""
|
|
|
|
output: Any
|
|
type: str = "task_completed"
|
|
|
|
|
|
|
|
class TaskFailedEvent(CrewEvent):
|
|
"""Event emitted when a task fails"""
|
|
|
|
error: str
|
|
type: str = "task_failed"
|
|
|