Skip to content

The agent that grows with you

chore(desktop): require prepared build Python and refresh release comment

ethernete8a5e0978c9f
diff --git a/.github/workflows/desktop-bundled-release.yml b/.github/workflows/desktop-bundled-release.yml
index cdac24df738..4db5dfc2fe5 100644
--- a/.github/workflows/desktop-bundled-release.yml
+++ b/.github/workflows/desktop-bundled-release.yml
@@ -1508,7 +1508,7 @@ jobs:
# ensureWindowsBundleTools resolves the winCodeSign kit, ATS dlib
# and dotnet runtime through electron-builder's toolset cache.
path: ${{ github.workspace }}/.cache/electron-builder
- # Saved by the build-win32-release legs during preparation.
+ # Saved by the Windows release build legs during preparation.
key: eb3-${{ runner.os }}-${{ runner.arch }}-builder-${{ steps.toolchain.outputs.builder }}
restore-keys: |
eb3-${{ runner.os }}-${{ runner.arch }}-
diff --git a/apps/desktop/scripts/mac-sign.test.mjs b/apps/desktop/scripts/mac-sign.test.mjs
index 2c38df600e9..4e39a3862da 100644
--- a/apps/desktop/scripts/mac-sign.test.mjs
+++ b/apps/desktop/scripts/mac-sign.test.mjs
@@ -15,7 +15,7 @@ const config = require('../electron-builder.config.cjs')
const repo = path.resolve(import.meta.dirname, '../../..')
const desktop = path.resolve(import.meta.dirname, '..')
const digestModule = pathToFileURL(path.join(import.meta.dirname, 'payload-digests.mjs')).href
-const python = process.env.HERMES_PYTHON || 'python'
+const python = process.env.HERMES_PYTHON || (process.platform === 'win32' ? 'py' : 'python3')
function fixture() {
const root = fs.mkdtempSync(path.join(os.tmpdir(), 'mac-digest-order-'))
diff --git a/scripts/build/python.mjs b/scripts/build/python.mjs
index fc1218948ba..a4ba22f7fef 100644
--- a/scripts/build/python.mjs
+++ b/scripts/build/python.mjs
@@ -9,7 +9,10 @@ import { pathToFileURL } from 'node:url'
*/
export function runPython(args, options = {}) {
const env = options.env ?? process.env
- return execFileSync(env.HERMES_PYTHON || 'python', args, { stdio: 'inherit', ...options, env })
+ if (!env.HERMES_PYTHON) {
+ throw new Error('Set HERMES_PYTHON to the prepared build interpreter')
+ }
+ return execFileSync(env.HERMES_PYTHON, args, { stdio: 'inherit', ...options, env })
}
if (process.argv[1] && import.meta.url === pathToFileURL(process.argv[1]).href) {