@computesdk/workbench 5.0.2 → 5.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,12 +9,12 @@ var __export = (target, all) => {
9
9
  __defProp(target, name, { get: all[name], enumerable: true });
10
10
  };
11
11
 
12
- // ../../node_modules/.pnpm/tsup@8.5.0_jiti@2.6.1_postcss@8.5.6_tsx@4.20.3_typescript@5.8.3_yaml@2.8.0/node_modules/tsup/assets/esm_shims.js
12
+ // ../../node_modules/.pnpm/tsup@8.5.1_jiti@2.6.1_postcss@8.5.6_tsx@4.21.0_typescript@5.9.3_yaml@2.8.2/node_modules/tsup/assets/esm_shims.js
13
13
  import path from "path";
14
14
  import { fileURLToPath } from "url";
15
15
  var getFilename, getDirname, __dirname;
16
16
  var init_esm_shims = __esm({
17
- "../../node_modules/.pnpm/tsup@8.5.0_jiti@2.6.1_postcss@8.5.6_tsx@4.20.3_typescript@5.8.3_yaml@2.8.0/node_modules/tsup/assets/esm_shims.js"() {
17
+ "../../node_modules/.pnpm/tsup@8.5.1_jiti@2.6.1_postcss@8.5.6_tsx@4.21.0_typescript@5.9.3_yaml@2.8.2/node_modules/tsup/assets/esm_shims.js"() {
18
18
  "use strict";
19
19
  getFilename = () => fileURLToPath(import.meta.url);
20
20
  getDirname = () => path.dirname(getFilename());
@@ -271,6 +271,7 @@ ${c.bold("Running Commands:")}
271
271
  ${c.cyan("getUrl({ port: 3000 })")} ${c.dim("// Get public URL")}
272
272
  ${c.cyan(`runCode("console.log('hi')", "node")`)}
273
273
  ${c.cyan("sandboxInfo()")} ${c.dim("// Get sandbox details")}
274
+ ${c.cyan("ready()")} ${c.dim("// Get readiness status")}
274
275
  ${c.cyan("getInstance()")} ${c.dim("// Get native instance")}
275
276
 
276
277
  ${c.dim("Terminal (PTY & Exec):")}
@@ -702,6 +703,7 @@ async function getComputeInstance(state) {
702
703
  compute2 = gatewayCompute({
703
704
  provider: providerName,
704
705
  computesdkApiKey: gatewayConfig.apiKey,
706
+ requestTimeoutMs: 6e4,
705
707
  // Spread provider-specific config
706
708
  [providerName]: providerConfig
707
709
  });
@@ -1341,6 +1343,17 @@ function injectWorkbenchCommands(replServer, state) {
1341
1343
  }
1342
1344
  return sandbox.getInfo();
1343
1345
  };
1346
+ replServer.context.ready = async () => {
1347
+ const sandbox = state.currentSandbox;
1348
+ if (!sandbox) {
1349
+ throw new Error("No active sandbox. Run a command to auto-create one.");
1350
+ }
1351
+ const sandboxReady = sandbox;
1352
+ if (typeof sandboxReady.ready !== "function") {
1353
+ throw new Error("Ready status is not supported for this provider.");
1354
+ }
1355
+ return sandboxReady.ready();
1356
+ };
1344
1357
  replServer.context.runCode = async (code, runtime) => {
1345
1358
  const sandbox = state.currentSandbox;
1346
1359
  if (!sandbox) {