Skip to content

Commit 126954f

Browse files
committed
refactor(ci): remove obsolete uv fallback paths
1 parent 5257548 commit 126954f

2 files changed

Lines changed: 17 additions & 56 deletions

File tree

.github/workflows/release.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -161,9 +161,6 @@ jobs:
161161
fi
162162
echo "tag=$tag" >> "$GITHUB_OUTPUT"
163163
164-
- name: Setup uv
165-
uses: astral-sh/setup-uv@v7
166-
167164
- name: Setup Python
168165
id: setup-python
169166
uses: actions/setup-python@v6
@@ -384,7 +381,6 @@ jobs:
384381
- name: Install dependencies
385382
shell: bash
386383
run: |
387-
uv sync
388384
pnpm --dir dashboard install --frozen-lockfile
389385
pnpm --dir desktop install --frozen-lockfile
390386

desktop/scripts/build-backend.mjs

Lines changed: 17 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -96,65 +96,30 @@ const installRuntimeDependencies = (runtimePython) => {
9696
throw new Error(`Backend requirements file does not exist: ${requirementsPath}`);
9797
}
9898

99-
const runPipInstall = (extraArgs = []) => {
100-
const installArgs = [
101-
'-m',
102-
'pip',
103-
'--disable-pip-version-check',
104-
'install',
105-
'--no-cache-dir',
106-
'-r',
107-
requirementsPath,
108-
...extraArgs,
109-
];
110-
const installResult = spawnSync(runtimePython.absolute, installArgs, {
111-
cwd: outputDir,
112-
stdio: ['ignore', 'pipe', 'pipe'],
113-
encoding: 'utf8',
114-
windowsHide: true,
115-
});
116-
if (installResult.stdout) {
117-
process.stdout.write(installResult.stdout);
118-
}
119-
if (installResult.stderr) {
120-
process.stderr.write(installResult.stderr);
121-
}
122-
return installResult;
123-
};
124-
125-
let installResult = runPipInstall();
99+
const installArgs = [
100+
'-m',
101+
'pip',
102+
'--disable-pip-version-check',
103+
'install',
104+
'--no-cache-dir',
105+
'-r',
106+
requirementsPath,
107+
];
108+
const installResult = spawnSync(runtimePython.absolute, installArgs, {
109+
cwd: outputDir,
110+
stdio: 'inherit',
111+
windowsHide: true,
112+
});
126113
if (installResult.error) {
127114
throw new Error(
128115
`Failed to install backend runtime dependencies: ${installResult.error.message}`,
129116
);
130117
}
131-
if (installResult.status === 0) {
132-
return;
133-
}
134-
135-
const outputText = `${installResult.stderr || ''}\n${installResult.stdout || ''}`;
136-
const shouldRetryWithBreakSystemPackages =
137-
outputText.includes('externally-managed-environment') ||
138-
outputText.includes('This environment is externally managed');
139-
140-
if (shouldRetryWithBreakSystemPackages) {
141-
console.warn(
142-
'Detected externally managed Python runtime; retrying pip install with --break-system-packages.',
118+
if (installResult.status !== 0) {
119+
throw new Error(
120+
`Backend runtime dependency installation failed with exit code ${installResult.status}.`,
143121
);
144-
installResult = runPipInstall(['--break-system-packages']);
145-
if (installResult.error) {
146-
throw new Error(
147-
`Failed to install backend runtime dependencies: ${installResult.error.message}`,
148-
);
149-
}
150-
if (installResult.status === 0) {
151-
return;
152-
}
153122
}
154-
155-
throw new Error(
156-
`Backend runtime dependency installation failed with exit code ${installResult.status}.`,
157-
);
158123
};
159124

160125
const main = () => {

0 commit comments

Comments
 (0)