fix: correct Node.js version references from 24 to 22 in comments and code
Fixed confusing messaging where comments mentioned Node 24 while actual requirement is Node 22: - environment.ts: Fixed areWorkerThreadsAvailableSync() to check for >= 22 instead of >= 24 - workerUtils.ts: Updated comments to reference Node.js 22 LTS instead of 24 - embedding.ts: Updated ONNX threading comment to reference Node.js 22 LTS Why Node 22 not Node 24: - ONNX Runtime has stability issues in Node 24 (V8 HandleScope crashes) - Node 22 LTS provides maximum stability with our embedding model - These stale Node 24 references were causing user confusion 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
fcf710c398
commit
22513ffcb4
3 changed files with 5 additions and 5 deletions
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
* Utility functions for executing functions in Worker Threads (Node.js) or Web Workers (Browser)
|
||||
* This implementation leverages Node.js 24's improved Worker Threads API for better performance
|
||||
* This implementation leverages Node.js 22's stable Worker Threads API for maximum reliability
|
||||
*/
|
||||
|
||||
import { isBrowser, isNode } from './environment.js'
|
||||
|
|
@ -82,7 +82,7 @@ export function executeInThread<T>(fnString: string, args: any): Promise<T> {
|
|||
|
||||
/**
|
||||
* Execute a function in a Node.js Worker Thread
|
||||
* Optimized for Node.js 24 with improved Worker Threads performance
|
||||
* Optimized for Node.js 22 LTS with stable Worker Threads performance
|
||||
*/
|
||||
function executeInNodeWorker<T>(fnString: string, args: any): Promise<T> {
|
||||
return new Promise<T>((resolve, reject) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue