Program: 166751
Project: 166751
Buggy source:
/** 
 * called during each memory cycle
 */
public void cycle(){
  long now=memory.time();
  if (now - lastExecution < (memory.param.duration.get() / maxExecutionsPerDuration)) {
    return;
  }
  lastExecution=now;
  updateTasks();
  updateSensors();
  if (tasks.isEmpty()) {
    return;
  }
  if (memory.emitting(TaskExecution.class)) {
    if (tasks.size() > 1) {
      for (      TaskExecution tcc : tasks) {
        memory.emit(Executive.class,memory.time(),tcc);
      }
    }
 else {
      memory.emit(Executive.class,memory.time(),tasks.first());
    }
  }
  TaskExecution topExecution=tasks.first();
  Task top=topExecution.t;
  Term term=top.getContent();
  if (term instanceof Operation) {
    execute((Operation)term,top);
    removeTask(topExecution);
    return;
  }
 else   if (Parameters.TEMPORAL_PARTICLE_PLANNER && term instanceof Conjunction) {
    Conjunction c=(Conjunction)term;
    if (c.operator() == Symbols.NativeOperator.SEQUENCE) {
      executeConjunctionSequence(topExecution,c);
      return;
    }
  }
 else   if (Parameters.TEMPORAL_PARTICLE_PLANNER && term instanceof Implication) {
    Implication it=(Implication)term;
    if ((it.getTemporalOrder() == TemporalRules.ORDER_FORWARD) || (it.getTemporalOrder() == TemporalRules.ORDER_CONCURRENT)) {
      if (it.getSubject() instanceof Conjunction) {
        Conjunction c=(Conjunction)it.getSubject();
        if (c.operator() == Symbols.NativeOperator.SEQUENCE) {
          executeConjunctionSequence(topExecution,c);
          return;
        }
      }
 else       if (it.getSubject() instanceof Operation) {
        execute((Operation)it.getSubject(),top);
        removeTask(topExecution);
        return;
      }
    }
    throw new RuntimeException("String_Node_Str" + it.getSubject() + "String_Node_Str"+ it.getSubject().getClass()+ "String_Node_Str"+ top);
  }
 else {
  }
}

Fixed version (ground truth):
/** 
 * called during each memory cycle
 */
public void cycle(){
  long now=memory.time();
  if (now - lastExecution < (memory.param.duration.get() / maxExecutionsPerDuration)) {
    return;
  }
  lastExecution=now;
  updateTasks();
  updateSensors();
  if (tasks.isEmpty()) {
    return;
  }
  if (memory.emitting(TaskExecution.class)) {
    if (tasks.size() > 1) {
      for (      TaskExecution tcc : tasks) {
        memory.emit(Executive.class,memory.time(),tcc);
      }
    }
 else {
      memory.emit(Executive.class,memory.time(),tasks.first());
    }
  }
  TaskExecution topExecution=tasks.first();
  Task top=topExecution.t;
  Term term=top.getContent();
  removeTask(topExecution);
  if (term instanceof Operation) {
    execute((Operation)term,top);
    return;
  }
 else   if (Parameters.TEMPORAL_PARTICLE_PLANNER && term instanceof Conjunction) {
    Conjunction c=(Conjunction)term;
    if (c.operator() == Symbols.NativeOperator.SEQUENCE) {
      executeConjunctionSequence(topExecution,c);
      return;
    }
  }
 else   if (Parameters.TEMPORAL_PARTICLE_PLANNER && term instanceof Implication) {
    Implication it=(Implication)term;
    if ((it.getTemporalOrder() == TemporalRules.ORDER_FORWARD) || (it.getTemporalOrder() == TemporalRules.ORDER_CONCURRENT)) {
      if (it.getSubject() instanceof Conjunction) {
        Conjunction c=(Conjunction)it.getSubject();
        if (c.operator() == Symbols.NativeOperator.SEQUENCE) {
          executeConjunctionSequence(topExecution,c);
          return;
        }
      }
 else       if (it.getSubject() instanceof Operation) {
        execute((Operation)it.getSubject(),top);
        return;
      }
    }
    throw new RuntimeException("String_Node_Str" + it.getSubject() + "String_Node_Str"+ it.getSubject().getClass()+ "String_Node_Str"+ top);
  }
 else {
  }
}