mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: build script venv handling and lint fixes
- Use /opt/venv directly when --entrypoint bash bypasses entrypoint.sh - Use sys.executable for all pip calls (not bare pip) - Override entrypoint in CI workflow to avoid startup banner - Fix Biome formatting (template literals, try/catch blocks)
This commit is contained in:
@@ -655,15 +655,21 @@ export async function importBundleArchive(
|
||||
if (existsSync(stagingFixups)) {
|
||||
const wheels = readdirSync(stagingFixups).filter((f) => f.endsWith(".whl"));
|
||||
if (wheels.length > 0) {
|
||||
const venvPython =
|
||||
(process.env.PYTHON_VENV_PATH || join(AI_DIR, "venv")) + "/bin/python3";
|
||||
const venvPython = `${process.env.PYTHON_VENV_PATH || join(AI_DIR, "venv")}/bin/python3`;
|
||||
for (const wheel of wheels) {
|
||||
try {
|
||||
execFileSync(venvPython, [
|
||||
"-m", "pip", "install", "--no-index",
|
||||
`--find-links=${stagingFixups}`,
|
||||
wheel.split("-")[0],
|
||||
], { stdio: "ignore", timeout: 30_000 });
|
||||
execFileSync(
|
||||
venvPython,
|
||||
[
|
||||
"-m",
|
||||
"pip",
|
||||
"install",
|
||||
"--no-index",
|
||||
`--find-links=${stagingFixups}`,
|
||||
wheel.split("-")[0],
|
||||
],
|
||||
{ stdio: "ignore", timeout: 30_000 },
|
||||
);
|
||||
} catch {
|
||||
// Non-fatal
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user