ruvnet/ruflo · error
Failed to fetch WASM: ${response.status}
Error message
Failed to fetch WASM: ${response.status} What it means
loadWasmBrowser()'s bundler-import fallback failed and the raw fetch of the WASM path came back with a non-OK HTTP status. The status is surfaced so the caller can distinguish 404 (wrong path) from 5xx (serving problem); the WASM module is not loaded.
Source
Thrown at v3/plugins/prime-radiant/src/wasm-bridge.ts:260
// optionalDependency at build time (TS2307 when it isn't installed).
const pkg: string = 'prime-radiant-advanced-wasm';
const primeRadiant = await import(pkg);
if (typeof primeRadiant.default === 'function') {
await primeRadiant.default();
}
this.wasmModule = primeRadiant as unknown as WasmModule;
this.bundleSize = 92 * 1024;
if (this.config.enableLogging) {
console.log('[Prime Radiant] WASM module loaded via bundler');
}
} catch {
// Fall back to fetch
const response = await fetch(wasmPath);
if (!response.ok) {
throw new Error(`Failed to fetch WASM: ${response.status}`);
}
const wasmBuffer = await response.arrayBuffer();
this.bundleSize = wasmBuffer.byteLength;
const importObject = this.createImportObject();
if (typeof WebAssembly.instantiateStreaming === 'function') {
// Streaming compilation (faster)
const result = await WebAssembly.instantiateStreaming(
fetch(wasmPath),
importObject
);
this.wasmModule = result.instance.exports as unknown as WasmModule;
} else {
// Standard compilation
const wasmModule = await WebAssembly.compile(wasmBuffer);
const instance = await WebAssembly.instantiate(wasmModule, importObject as WebAssembly.Imports);
this.wasmModule = instance.exports as unknown as WasmModule;View on GitHub (pinned to fa13ee4ad6)
Solutions
- Verify the WASM URL is reachable and served with the correct MIME type (application/wasm).
- Check the HTTP status; fix CORS or hosting configuration if the fetch is rejected.
Defensive patterns
Strategy: fallback
When it happens
Trigger: Thrown at v3/plugins/prime-radiant/src/wasm-bridge.ts:260 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of ruvnet/ruflo@fa13ee4ad6 (2026-08-18).
Data as JSON: /api/errors/19022bd2b965eb79.
Report an issue: GitHub.