Skip to content

A desktop coding agent with free access to frontier models.

TypeScript

fix: let a sandbox plan in flight settle before the allowlist applies

ogsamrat7e861757871e
diff --git a/apps/server/src/box/service.ts b/apps/server/src/box/service.ts
index cc57b5a1..0645bc91 100644
--- a/apps/server/src/box/service.ts
+++ b/apps/server/src/box/service.ts
@@ -194,6 +194,8 @@ export class BoxService {
async serverBackendsChanged(): Promise<void> {
const allow = serverBackends(this.options.stateDir);
this.alternatives = null;
+ // A plan in flight (started with the old allowlist) settles first.
+ await Promise.allSettled([...this.projects.values()].map((project) => project.planning));
for (const project of this.projects.values()) {
if (!project.run || !allow || allow.includes(project.run.backend)) continue;
project.run = null;