sandboxedjs 0.1.56 → 0.1.57

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.
package/dist/index.js CHANGED
@@ -17918,10 +17918,10 @@ var bundledManifest = {
17918
17918
  persistence: "memory"
17919
17919
  }
17920
17920
  };
17921
- var bundledWheelIndex = new URL(
17921
+ var bundledWheelIndex = (typeof process !== "undefined" && process.versions?.node ? new URL(
17922
17922
  import.meta.url.includes("/src/runtime/python/") ? "../../../dist/python/wheels/" : "./python/wheels/",
17923
17923
  import.meta.url
17924
- ).href;
17924
+ ) : new URL("/python/wheels/", globalThis.location?.href ?? import.meta.url)).href;
17925
17925
  var config = {
17926
17926
  backend: "sbx-cpython-wasm",
17927
17927
  manifest: bundledManifest,
@@ -20442,7 +20442,9 @@ environments. A package with no usable wheel is an error, never a silent skip.`,
20442
20442
  const loaded = await client.json(`${url}/index.json`);
20443
20443
  index = { baseUrl: url, wheels: loaded.wheels ?? [] };
20444
20444
  } catch (error) {
20445
- return ctx.fail(`could not read the wheel index at ${configured}: ${error.message}`);
20445
+ return ctx.fail(
20446
+ `could not read the wheel index at ${configured}: ${error.message}. When running under a bundler such as Vite, publish dist/python/wheels as a static asset and configurePython({ wheelIndex: '/python/wheels' }) before creating the container.`
20447
+ );
20446
20448
  }
20447
20449
  } else if (configured) {
20448
20450
  index = configured;