@youdie006/prodex 0.40.15 → 0.40.17
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.
- package/README.md +1 -1
- package/dist/cli-pro.js +24 -1
- package/docs/cli-reference.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -191,7 +191,7 @@ The last recorded window mode is reused by later `login` commands and by CLI/MCP
|
|
|
191
191
|
|
|
192
192
|
`--headless` may be blocked even with a saved login: a previous test on a signed-in profile stayed on Cloudflare's interstitial past sixty seconds. `--background` verifies the actual handoff and only reports READY when the signed-in composer works headless. A challenge does not prove that the saved login was lost. Only the window is optional; authentication and protection checks still apply.
|
|
193
193
|
|
|
194
|
-
If a running headless browser needs login, captcha, Cloudflare, or account verification, run `prodex pro browser login --headed --recover-visible`. This is an explicit, guarded switch for a known authentication/protection blocker, not an automatic fallback or a general browser reset. It preserves the profile and page, waits for a clean shutdown, and opens a visible browser for any required manual step. That window is temporary: after
|
|
194
|
+
If a running headless browser needs login, captcha, Cloudflare, or account verification, run `prodex pro browser login --headed --recover-visible`. This is an explicit, guarded switch for a known authentication/protection blocker, not an automatic fallback or a general browser reset. It preserves the profile and page, waits for a clean shutdown, and opens a visible browser for any required manual step. That window is temporary: after the dedicated browser fully exits, the next launch remains headless. On macOS, closing a window alone may leave Chrome running; prodex stops rather than reopening that temporary visible window. Another challenge also stops instead of opening a visible window automatically; an ordinary explicit `login --headed` selects headed mode permanently. A virtual-display browser must still be closed manually before `login --headed`; it is not covered by this headless-only recovery. Merely omitting `--headless` does not switch modes because the saved preference persists. prodex never bypasses protection or force-kills a browser for a mode change.
|
|
195
195
|
|
|
196
196
|
Before a prompt is submitted, a browser confirmed to have stopped answering its control port can be ended and started fresh, and the receipt says so (`PRODEX_NO_AUTO_CLEAR=1` turns that off). A browser that is merely slow is left alone. After submission, prodex never auto-resends a lost prompt.
|
|
197
197
|
|
package/dist/cli-pro.js
CHANGED
|
@@ -2082,6 +2082,14 @@ async function attemptMissingChatGptTabRecovery(stderr, options) {
|
|
|
2082
2082
|
throw new ChatGptBrowserBlockerError(status.blocker);
|
|
2083
2083
|
return false;
|
|
2084
2084
|
}
|
|
2085
|
+
if (saved?.headless !== true && resolveBrowserWindowMode({ lastLogin: saved, forRelaunch: true }).headless) {
|
|
2086
|
+
throw new ChatGptBrowserBlockerError({
|
|
2087
|
+
code: "browser_mode_transition_required",
|
|
2088
|
+
message: "The temporary visible browser is still running after its ChatGPT tab closed; reopening a tab would show another window.",
|
|
2089
|
+
retryable: false,
|
|
2090
|
+
next_step: "Fully quit only the dedicated browser, then retry to launch the saved profile headlessly. On macOS, closing a window alone does not quit Chrome. Do not log in again solely because this transition stopped."
|
|
2091
|
+
});
|
|
2092
|
+
}
|
|
2085
2093
|
stderr("recover: the browser is running but its ChatGPT tab was closed; opening one tab and checking the saved login...");
|
|
2086
2094
|
if (!await openChatGptTab(port))
|
|
2087
2095
|
return false;
|
|
@@ -2282,7 +2290,7 @@ async function completeVisibleAuthRecovery(io, options) {
|
|
|
2282
2290
|
sourceCli: options.sourceCli, commandOptions: options.commandOptions
|
|
2283
2291
|
});
|
|
2284
2292
|
io.stdout("recovery: visible browser opened with the same profile and page. Complete a manual step only if ChatGPT requests it; no prompt was sent.");
|
|
2285
|
-
io.stdout("recovery: this visible window is temporary. After
|
|
2293
|
+
io.stdout("recovery: this visible window is temporary. After the dedicated browser fully exits, the next launch remains headless. On macOS, closing its window alone may leave Chrome running; prodex will not reopen that temporary visible window automatically.");
|
|
2286
2294
|
if (!options.shouldWait)
|
|
2287
2295
|
return 0;
|
|
2288
2296
|
const ready = await waitForChatGptLoginReady(io.stderr, {
|
|
@@ -3067,6 +3075,21 @@ export function printBrowserLoginGuide(stdout, input) {
|
|
|
3067
3075
|
: input.opened
|
|
3068
3076
|
? "Opened the dedicated Chrome window for ChatGPT."
|
|
3069
3077
|
: "Dry run: no browser was opened.");
|
|
3078
|
+
if (noInteractiveWindow && !input.opened && !input.reused) {
|
|
3079
|
+
const previewCommand = formatBrowserLoginCommand(input.sourceCli, {
|
|
3080
|
+
...input.commandOptions,
|
|
3081
|
+
profileDir: input.profileDir,
|
|
3082
|
+
port: input.port
|
|
3083
|
+
});
|
|
3084
|
+
const modeFlag = input.headless ? "--headless" : "--virtual-display";
|
|
3085
|
+
stdout("");
|
|
3086
|
+
stdout(`Next: run \`${previewCommand} ${modeFlag}\` without \`--dry-run\` to start or reuse Chrome with no visible window.`);
|
|
3087
|
+
stdout("Readiness was not checked. A real launch reuses this profile and reports any login or protection blocker; it does not switch to a visible window automatically.");
|
|
3088
|
+
stdout("");
|
|
3089
|
+
stdout(`Profile: ${input.profileDir}`);
|
|
3090
|
+
stdout(`Debug: http://127.0.0.1:${input.port}`);
|
|
3091
|
+
return;
|
|
3092
|
+
}
|
|
3070
3093
|
if (noInteractiveWindow && (input.opened || input.reused)) {
|
|
3071
3094
|
stdout("");
|
|
3072
3095
|
stdout(input.headless
|
package/docs/cli-reference.md
CHANGED
|
@@ -125,7 +125,7 @@ For a one-time interactive login followed by a no-window handoff, run `prodex pr
|
|
|
125
125
|
|
|
126
126
|
To inspect an authentication/protection blocker in a running headless browser, explicitly use `prodex pro browser login --headed --recover-visible`. The command requires one verified dedicated headless browser and one ChatGPT page reporting `login_required`, `cloudflare_check`, `captcha_required`, or `permission_required`. It preserves the exact profile and page under the shared send lock, refuses unfinished inputs, active work, dialogs, attachments, extra tabs, and ambiguous identity, and waits for a verified shutdown before launching headed. It does not click, solve, or suppress a security check. Use `--wait` to wait for manual handling or `--no-wait` to return after launch; `--dry-run` performs no browser change. This is headless-only, not a generic reset or a virtual-display switch.
|
|
127
127
|
|
|
128
|
-
The visible recovery window does not change the headless relaunch preference. Once
|
|
128
|
+
The visible recovery window does not change the headless relaunch preference. Once the dedicated browser fully exits, both a new `login` launch and an automatic browser restart use headless mode again. On macOS, closing its last window may leave the process running: automatic missing-tab recovery stops with `browser_mode_transition_required` instead of opening another visible window. Fully quit only the dedicated browser before retrying; the closed tab alone is not a reason to log in again. Reusing a still-open window with `login --wait` keeps the preference. An ordinary explicit window-mode option or environment override replaces it. There is no automatic headed fallback when the next headless launch encounters another challenge.
|
|
129
129
|
|
|
130
130
|
If only the ChatGPT tab was closed, MCP and auto-login-enabled CLI requests can reopen one tab in the existing browser before an unsent request. They verify the saved login before sending and never use this path to resend an accepted or uncertain request.
|
|
131
131
|
|