disable round-robin for sequential
This commit is contained in:
@@ -113,10 +113,11 @@ prompts:
|
||||
> tasks, only the first two models are used. The third model is only touched when
|
||||
> a third concurrent task starts. Freed model slots are reused before new ones
|
||||
> are allocated.
|
||||
>
|
||||
> **Automatic failover**: if a provider/API is unreachable (rate limit, 503, etc.),
|
||||
> the task automatically cycles to the next model in the list without counting it
|
||||
> as a task failure. Each model is tried once before the task is marked as failed.
|
||||
> **NOTE**: this is only used in parallel execution, in sequential mode the
|
||||
> parent pi session's model is used
|
||||
|
||||
## State Files
|
||||
|
||||
|
||||
@@ -411,10 +411,9 @@ export async function executeBatch(
|
||||
return;
|
||||
}
|
||||
|
||||
// Execute sequentially
|
||||
// Execute sequentially (no round-robin — inherit parent model)
|
||||
for (const task of tasks) {
|
||||
try {
|
||||
const model = roundRobin?.assign(task.id);
|
||||
await executeTask(
|
||||
task,
|
||||
project,
|
||||
@@ -423,14 +422,11 @@ export async function executeBatch(
|
||||
ctx,
|
||||
sendChatMessage,
|
||||
projectDir,
|
||||
undefined,
|
||||
model,
|
||||
roundRobin,
|
||||
);
|
||||
} catch (error) {
|
||||
// Task failed — stop the batch. Dependent tasks are blocked by
|
||||
// the DAG layer (getBlockedTasks) so they won't appear in this batch.
|
||||
roundRobin?.release(task.id);
|
||||
|
||||
const errorMsg = error instanceof Error ? error.message : String(error);
|
||||
progress.markFailed(task.id, errorMsg);
|
||||
sendChatMessage?.(`✗ ${task.id} · ${task.title} — ${errorMsg}`);
|
||||
|
||||
Reference in New Issue
Block a user