forked from linkong/planet
release: bump version to 0.85.0
This commit is contained in:
1 parent
30b44ec00d
commit
1c0066edc6
223 files changed
+30277
-340
No files matched your search
@@ -99,7 +99,25 @@ function checkAdminBuildSeparation() {
|
||||
}
|
||||
}
|
||||
|
||||
function checkElectronHeadlessSmoke() {
|
||||
async function resolveSmokeBackendUrl() {
|
||||
const configured = (process.env.PLANET_CLIENT_SMOKE_BACKEND_URL || '').trim()
|
||||
if (configured) {
|
||||
return configured
|
||||
}
|
||||
try {
|
||||
const res = await fetch('http://127.0.0.1:8000/health/ready', {
|
||||
signal: AbortSignal.timeout(1000),
|
||||
})
|
||||
if (res.ok) {
|
||||
return 'http://127.0.0.1:8000'
|
||||
}
|
||||
} catch {
|
||||
// Fall back to default endpoint when local backend is not running.
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
async function checkElectronHeadlessSmoke() {
|
||||
const electronBin = join(
|
||||
clientDir,
|
||||
'node_modules',
|
||||
@@ -111,7 +129,13 @@ function checkElectronHeadlessSmoke() {
|
||||
const mainEntry = join(clientDir, 'dist-electron', 'main', 'index.cjs')
|
||||
assert(existsSync(mainEntry), `missing built Electron main entry at ${mainEntry}`)
|
||||
|
||||
const electronArgs = [mainEntry, '--headless-smoke', '--no-sandbox']
|
||||
const smokeBackendUrl = await resolveSmokeBackendUrl()
|
||||
const electronArgs = [
|
||||
mainEntry,
|
||||
'--headless-smoke',
|
||||
'--no-sandbox',
|
||||
...(smokeBackendUrl ? [`--backend-url=${smokeBackendUrl}`] : []),
|
||||
]
|
||||
const hasDisplay = Boolean(process.env.DISPLAY || process.env.WAYLAND_DISPLAY)
|
||||
let result
|
||||
if (!hasDisplay && process.platform === 'linux') {
|
||||
@@ -183,4 +207,4 @@ function checkElectronHeadlessSmoke() {
|
||||
|
||||
checkOfflineEarthBundle()
|
||||
checkAdminBuildSeparation()
|
||||
checkElectronHeadlessSmoke()
|
||||
await checkElectronHeadlessSmoke()
|
||||
Reference in new issue
Block a user