ruvnet/ruflo · error
WASM topo sort failed, falling back to JS
Error message
WASM topo sort failed, falling back to JS
What it means
Log warning in getExecutionOrder: the WASM topo_sort call failed (other than the deliberate cycle error); the method falls back to the JS topological sort to compute execution order.
Source
Thrown at v3/plugins/gastown-bridge/src/convoy/observer.ts:530
if (this.config.useWasm && this.wasmModule) {
try {
const wasmNodes = this.beadsToWasmNodes(beads);
const resultJson = this.wasmModule.topo_sort(JSON.stringify(wasmNodes));
const result: TopoSortResult = JSON.parse(resultJson);
if (result.hasCycle) {
throw new GasTownError(
'Cannot compute execution order: dependency cycle detected',
GasTownErrorCode.DEPENDENCY_CYCLE,
{ cycleNodes: result.cycleNodes }
);
}
return result.sorted;
} catch (error) {
if (error instanceof GasTownError) throw error;
this.logger.warn('WASM topo sort failed, falling back to JS', {
error: error instanceof Error ? error.message : String(error),
});
}
}
// JavaScript fallback using Kahn's algorithm
return this.topoSortJS(beads);
}
/**
* Stop watching a convoy
*/
stopWatching(convoyId: string): void {
const watcher = this.watchers.get(convoyId);
if (watcher) {
clearTimeout(watcher.timer);
this.watchers.delete(convoyId);
View on GitHub (pinned to fa13ee4ad6)
Solutions
- Check the WASM topo sort error; the JS fallback is used — reinstall or rebuild the WASM module to restore speed.
Defensive patterns
Strategy: fallback
When it happens
Trigger: Thrown at v3/plugins/gastown-bridge/src/convoy/observer.ts:530 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/243e930e8ac02a00.
Report an issue: GitHub.