{"record":{"id":"0c3eefaa40bd8212","repo":"ruvnet/ruflo","slug":"wasm-dag-module-not-available-using-js-fallback","errorCode":null,"errorMessage":"WASM DAG module not available, using JS fallback","messagePattern":"WASM DAG module not available, using JS fallback","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"v3/plugins/legal-contracts/src/bridges/dag-bridge.ts","lineNumber":86,"sourceCode":"export class DAGBridge implements IDAGBridge {\n  // WASM module for future performance optimization (currently uses JS fallback)\n  private wasmModule: DAGWasmModule | null = null;\n  private initialized = false;\n\n  /**\n   * Initialize the WASM module\n   */\n  async initialize(): Promise<void> {\n    if (this.initialized) return;\n\n    try {\n      // Dynamic import of WASM module\n      // In production, this would load from @claude-flow/ruvector-upstream\n      this.wasmModule = await this.loadWasmModule();\n      this.initialized = true;\n    } catch {\n      // Fallback to pure JS implementation if WASM not available\n      console.warn('WASM DAG module not available, using JS fallback');\n      this.wasmModule = null;\n      this.initialized = true;\n    }\n  }\n\n  /**\n   * Check if initialized\n   */\n  isInitialized(): boolean {\n    return this.initialized;\n  }\n\n  /**\n   * Build obligation dependency graph\n   */\n  async buildDependencyGraph(\n    obligations: Obligation[]\n  ): Promise<ObligationTrackingResult['graph']> {","sourceCodeStart":68,"sourceCodeEnd":104,"githubUrl":"https://github.com/ruvnet/ruflo/blob/fa13ee4ad60ac2090b1480656eb233521790d640/v3/plugins/legal-contracts/src/bridges/dag-bridge.ts#L68-L104","documentation":"Fallback in DAGBridge.initialize(): the WASM DAG module could not be loaded, so all graph operations (critical path, topo sort, cycle detection, float calculation) run on the JavaScript implementation.","triggerScenarios":"DAG WASM module unavailable; bridge falls back to the JS DAG implementation for obligation graph operations.","commonSituations":"See trigger scenarios.","solutions":["Build and ship the WASM DAG module and verify its load path.","Check WebAssembly support in the runtime environment.","If JS fallback is acceptable, no action needed; note it is slower for large graphs."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fa13ee4ad60ac2090b1480656eb233521790d640","analyzedAt":"2026-08-18T21:34:22.708Z","contentChangedAt":"2026-08-18T21:34:22.708Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}