gestalt-mobile 0.75.2 → 0.75.3

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.
@@ -4,8 +4,7 @@
4
4
  * SPDX-License-Identifier: AGPL-3.0-or-later
5
5
  */
6
6
  import { execFile } from 'node:child_process';
7
- import { withoutSessionScratch } from './platform/scratch/child-environment.js';
8
- import { probePlaywrightComponent } from './platform/codex/playwright-component.js';
7
+ import { readPlaywrightComponent } from './platform/codex/playwright-component.js';
9
8
  import { existsSync } from 'node:fs';
10
9
  import { readFile } from 'node:fs/promises';
11
10
  import { homedir } from 'node:os';
@@ -78,26 +77,6 @@ export function componentVersions(mobileVersion, codexVersion, environment = pro
78
77
  },
79
78
  ];
80
79
  }
81
- export async function runStartupDoctor(cwd) {
82
- if (process.env.GESTALT_STARTUP_DIAGNOSTICS_DONE === '1')
83
- return { ok: true, report: '' };
84
- try {
85
- const result = await runFile('gestalt', ['doctor'], {
86
- cwd,
87
- env: withoutSessionScratch(),
88
- timeout: 60_000,
89
- maxBuffer: 1024 * 1024,
90
- });
91
- return { ok: true, report: `${result.stdout}${result.stderr}` };
92
- }
93
- catch (error) {
94
- const failure = error;
95
- return {
96
- ok: false,
97
- report: `${failure.stdout ?? ''}${failure.stderr ?? ''}${failure.message ? `${failure.message}\n` : ''}`,
98
- };
99
- }
100
- }
101
80
  export function packageRoot(moduleUrl) {
102
81
  let directory = dirname(fileURLToPath(moduleUrl));
103
82
  while (true) {
@@ -299,11 +278,6 @@ export async function runCli(dependencies = {}) {
299
278
  stderr.write(`${error instanceof Error ? error.message : 'Invalid --icon file'}\n\n${usage}\n`);
300
279
  return 2;
301
280
  }
302
- const diagnosis = await (dependencies.runStartupDoctor ?? runStartupDoctor)(cwd);
303
- if (diagnosis.report)
304
- stderr.write(diagnosis.report);
305
- if (!diagnosis.ok)
306
- stderr.write('WARNING: Startup diagnostics reported a problem; Gestalt Mobile will continue so it can show recovery controls.\n');
307
281
  const installedCodexVersion = await (dependencies.probeCodexVersion ?? probeCodexVersion)();
308
282
  const installedKimiVersion = await (dependencies.probeKimiVersion ?? probeKimiVersion)();
309
283
  const mobileVersion = await packageVersion(moduleUrl);
@@ -318,7 +292,7 @@ export async function runCli(dependencies = {}) {
318
292
  profiles: new LauncherProfileCatalog(),
319
293
  installedCodexVersion,
320
294
  installedKimiVersion,
321
- componentVersions: componentVersions(mobileVersion, installedCodexVersion, dependencies.environment, await (dependencies.probePlaywrightComponent ?? probePlaywrightComponent)(config.root, dependencies.environment)),
295
+ componentVersions: componentVersions(mobileVersion, installedCodexVersion, dependencies.environment, await (dependencies.readPlaywrightComponent ?? readPlaywrightComponent)(dependencies.environment)),
322
296
  startAppServers: true,
323
297
  homeDirectory: dependencies.homeDirectory,
324
298
  explicitSkillProfile,
@@ -4,9 +4,9 @@
4
4
  * SPDX-License-Identifier: AGPL-3.0-or-later
5
5
  */
6
6
  import { ManagedPlaywright } from './managed-playwright.js';
7
- /** Uses a disposable local page to test Chrome without acquiring a session lease. */
8
- export async function probePlaywrightComponent(cwd, environment = process.env, adapter = new ManagedPlaywright(environment)) {
9
- let component = {
7
+ /** Read the installed version for Mobile's component list without launching Chrome. */
8
+ export async function readPlaywrightComponent(environment = process.env, adapter = new ManagedPlaywright(environment)) {
9
+ const component = {
10
10
  id: 'playwright',
11
11
  label: 'Playwright MCP',
12
12
  version: null,
@@ -17,36 +17,18 @@ export async function probePlaywrightComponent(cwd, environment = process.env, a
17
17
  const installation = await adapter.check();
18
18
  if (installation.status !== 'installed')
19
19
  return component;
20
- component = { ...component, version: installation.version };
21
- let readiness = await adapter.ready(installation.manager, cwd, Date.now() + 15000, [
22
- '--launch',
23
- ]);
24
- // Older managers reject --launch. Preserve prerequisite reporting during
25
- // separate Mobile/manager upgrades, without claiming a browser was tested.
26
- if (readiness.package === 'unknown' && readiness.chrome === 'unknown') {
27
- readiness = await adapter.ready(installation.manager, cwd, Date.now() + 5000);
28
- }
29
- const engine = readiness.playwrightVersion ? `Playwright ${readiness.playwrightVersion}; ` : '';
30
20
  return {
31
21
  ...component,
32
22
  version: installation.version,
33
- status: readiness.ready
34
- ? readiness.browserTest === 'passed'
35
- ? 'working'
36
- : 'ready'
37
- : 'unavailable',
38
- detail: readiness.ready
39
- ? readiness.browserTest === 'passed'
40
- ? `${engine}Chrome ${readiness.chromeVersion ?? 'detected'}; browser page check passed at startup.`
41
- : `${engine}Chrome ${readiness.chromeVersion ?? 'detected'}; prerequisites ready. Browser session has not been tested.`
42
- : 'Playwright is installed; Chrome or runtime prerequisites are unavailable or unverified.',
23
+ status: 'unverified',
24
+ detail: 'Playwright is installed. Run gestalt update to check its prerequisites.',
43
25
  };
44
26
  }
45
27
  catch {
46
28
  return {
47
29
  ...component,
48
30
  status: 'unverified',
49
- detail: 'Playwright readiness could not be checked.',
31
+ detail: 'Playwright installation metadata could not be read.',
50
32
  };
51
33
  }
52
34
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gestalt-mobile",
3
- "version": "0.75.2",
3
+ "version": "0.75.3",
4
4
  "description": "Mobile-first web relay for durable Codex development sessions",
5
5
  "keywords": [
6
6
  "codex",