Repository navigation
Commit 1ef1221
committed
refactor(sdk)!: make wait_ready succeed only on Ready
wait_ready previously also returned Ok for a sandbox that reached
Completed. A caller waiting for a sandbox almost always needs a live one,
and the name suggests that, so a sandbox that completes before becoming
ready is now an error that fails fast, like Stopped, Error and the
suspended phases. This applies to the Rust SDK's OpenShellClient and
WorkspaceScopedClient, the Go SDK's WaitReady and the TypeScript SDK's
waitReady, so the three SDKs agree.
BREAKING CHANGE: Rust wait_ready, Go SandboxInterface.WaitReady and
TypeScript waitReady return an error instead of the sandbox when it
reaches the Completed phase. Callers that need to wait for a finished
workload should poll the sandbox.
Signed-off-by: Evan Lezar <[email protected]>1 parent de26d07 commit 1ef1221
4 files changed
Lines changed: 15 additions & 11 deletions
File tree
- sdk
- go/openshell/v1
- typescript/src
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
368 | 368 | | |
369 | 369 | | |
370 | 370 | | |
371 | | - | |
372 | | - | |
373 | | - | |
374 | 371 | | |
375 | 372 | | |
376 | 373 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
974 | 974 | | |
975 | 975 | | |
976 | 976 | | |
977 | | - | |
| 977 | + | |
978 | 978 | | |
979 | 979 | | |
980 | 980 | | |
| |||
983 | 983 | | |
984 | 984 | | |
985 | 985 | | |
986 | | - | |
| 986 | + | |
987 | 987 | | |
988 | | - | |
989 | | - | |
| 988 | + | |
| 989 | + | |
990 | 990 | | |
991 | 991 | | |
992 | 992 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1325 | 1325 | | |
1326 | 1326 | | |
1327 | 1327 | | |
1328 | | - | |
| 1328 | + | |
1329 | 1329 | | |
1330 | 1330 | | |
1331 | 1331 | | |
| |||
1334 | 1334 | | |
1335 | 1335 | | |
1336 | 1336 | | |
1337 | | - | |
| 1337 | + | |
| 1338 | + | |
| 1339 | + | |
| 1340 | + | |
1338 | 1341 | | |
1339 | 1342 | | |
1340 | 1343 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1341 | 1341 | | |
1342 | 1342 | | |
1343 | 1343 | | |
1344 | | - | |
| 1344 | + | |
| 1345 | + | |
1345 | 1346 | | |
1346 | 1347 | | |
1347 | 1348 | | |
| |||
1361 | 1362 | | |
1362 | 1363 | | |
1363 | 1364 | | |
1364 | | - | |
| 1365 | + | |
| 1366 | + | |
| 1367 | + | |
| 1368 | + | |
1365 | 1369 | | |
1366 | 1370 | | |
1367 | 1371 | | |
| |||
0 commit comments