@emend-ai/utim 1.46.10 → 1.46.12
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.
- package/bin/utim.js +16 -9
- package/package.json +1 -1
package/bin/utim.js
CHANGED
|
@@ -107,15 +107,22 @@ function runPip(python, extraFlags) {
|
|
|
107
107
|
return isUtimInstalled(python);
|
|
108
108
|
} else {
|
|
109
109
|
// Linux / Termux fallback: run in current terminal
|
|
110
|
-
const
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
110
|
+
const pipArgs = ['-m', 'pip', 'install'];
|
|
111
|
+
if (isTermux) {
|
|
112
|
+
// On Termux: do NOT use --upgrade to prevent pip from pulling newer
|
|
113
|
+
// versions of pydantic-core from PyPI and trying to compile from source.
|
|
114
|
+
// Instead, use --upgrade-strategy only-if-needed to keep the pre-compiled version.
|
|
115
|
+
pipArgs.push('--upgrade-strategy', 'only-if-needed');
|
|
116
|
+
} else {
|
|
117
|
+
pipArgs.push('--upgrade');
|
|
118
|
+
}
|
|
119
|
+
pipArgs.push(...extraFlags, 'utim-cli');
|
|
120
|
+
|
|
121
|
+
const r = spawnSync(python, pipArgs, {
|
|
122
|
+
stdio: 'inherit',
|
|
123
|
+
shell: false,
|
|
124
|
+
timeout: 300000,
|
|
125
|
+
});
|
|
119
126
|
return r.status === 0;
|
|
120
127
|
}
|
|
121
128
|
} catch (_) {
|