Class: RCrewAI::Process::Sequential
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from RCrewAI::Process::Base
Instance Method Details
#execute ⇒ Object
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/rcrewai/process.rb', line 32 def execute log_execution_start results = [] crew.tasks.each do |task| @logger.info "Executing task: #{task.name}" begin result = task.execute results << { task: task, result: result, status: :completed } rescue StandardError => e @logger.error "Task #{task.name} failed: #{e.}" results << { task: task, result: e., status: :failed } end end log_execution_end(results) results end |