recursive-llm-ts 2.0.10 → 2.0.11

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.
@@ -77,7 +77,24 @@ class BunpyBridge {
77
77
  }
78
78
  // Import sys module to add path
79
79
  const sys = this.python.import('sys');
80
- const pythonExecutable = String(sys.executable || 'python');
80
+ const pythonExecutable = (() => {
81
+ try {
82
+ const sysExecutable = sys.executable;
83
+ if (sysExecutable && typeof sysExecutable.valueOf === 'function') {
84
+ const value = sysExecutable.valueOf();
85
+ if (typeof value === 'string' && value.trim()) {
86
+ return value;
87
+ }
88
+ }
89
+ if (typeof sysExecutable === 'string' && sysExecutable.trim()) {
90
+ return sysExecutable;
91
+ }
92
+ }
93
+ catch (_a) {
94
+ // Fall back if bunpy can't coerce sys.executable
95
+ }
96
+ return 'python';
97
+ })();
81
98
  const pythonCmd = pythonExecutable.includes(' ') ? `"${pythonExecutable}"` : pythonExecutable;
82
99
  const pythonPackagePath = path.join(__dirname, '..', 'recursive-llm');
83
100
  const pythonSrcPath = path.join(pythonPackagePath, 'src');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "recursive-llm-ts",
3
- "version": "2.0.10",
3
+ "version": "2.0.11",
4
4
  "description": "TypeScript bridge for recursive-llm: Recursive Language Models for unbounded context processing",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",