mirror of
https://github.com/OpenRouterTeam/spawn.git
synced 2026-05-06 08:10:48 +00:00
Each cloud module (aws, daytona, digitalocean, gcp, hetzner, sprite) previously stored per-operation state in bare module-level `let` variables, making them process-global singletons. This is safe for single-cloud CLI invocations today but creates latent bugs for multi-cloud orchestration and test isolation. Replace scattered `let` globals with a single typed `_state` object per module: - `AwsState` / `resetAwsState()` — 8 fields including `selectedBundle` - `DaytonaState` / `resetDaytonaState()` — 5 fields - `DigitalOceanState` / `resetDigitalOceanState()` — 3 fields - `GcpState` / `resetGcpState()` — 5 fields - `HetznerState` / `resetHetznerState()` — 3 fields - `SpriteState` / `resetSpriteState()` — 2 fields Each module exports a `resetXxxState()` function for test isolation. No function signatures or existing exports were changed. Fixes #2251 Agent: issue-fixer Co-authored-by: B <6723574+louisgv@users.noreply.github.com> Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| cli | ||
| shared | ||