de5ee3bb956967f1ca42bee45e49c6757461141a,reframe/frontend/executors/policies.py,AsynchronousExecutionPolicy,_setup_all,#AsynchronousExecutionPolicy#,309

Before Change


        // This would not be not safe and could have unxpected consequences.
        for task in self._waiting_tasks[:]:
            try:
                if self.deps_failed(task):
                    exc = TaskDependencyError("dependencies failed")
                    task.fail((type(exc), exc, None))
                elif self.deps_succeeded(task):
                    task.setup(task.testcase.partition,
                               task.testcase.environ,
                               sched_flex_alloc_nodes=self.sched_flex_alloc_nodes,
                               sched_account=self.sched_account,
                               sched_partition=self.sched_partition,
                               sched_reservation=self.sched_reservation,
                               sched_nodelist=self.sched_nodelist,
                               sched_exclude_nodelist=self.sched_exclude_nodelist,
                               sched_options=self.sched_options)
                else:
                    still_waiting.append(task)
            except TaskExit:
                pass

        self._waiting_tasks[:] = still_waiting

After Change


        // could fail on setup and be removed from the list _waiting_tasks.
        // This would not be not safe and could have unxpected consequences.
        for task in self._waiting_tasks[:]:
            if not task.failed and not self._setup_task(task):
                still_waiting.append(task)

        self._waiting_tasks[:] = still_waiting

    def _finalize_all(self):
        getlogger().debug("finalizing tasks: %s", len(self._completed_tasks))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: eth-cscs/reframe
Commit Name: de5ee3bb956967f1ca42bee45e49c6757461141a
Time: 2020-01-13
Author: eirini.koutsaniti@cscs.ch
File Name: reframe/frontend/executors/policies.py
Class Name: AsynchronousExecutionPolicy
Method Name: _setup_all


Project Name: eth-cscs/reframe
Commit Name: de5ee3bb956967f1ca42bee45e49c6757461141a
Time: 2020-01-13
Author: eirini.koutsaniti@cscs.ch
File Name: reframe/frontend/executors/policies.py
Class Name: AsynchronousExecutionPolicy
Method Name: runcase


Project Name: eth-cscs/reframe
Commit Name: 24b605e8ec48b9b67e507ca959eaed4ff4afc6a6
Time: 2018-02-14
Author: karakasis@cscs.ch
File Name: reframe/frontend/executors/policies.py
Class Name: AsynchronousExecutionPolicy
Method Name: run_check