fix: surface web probe target readiness blockers
This commit is contained in:
@@ -111,7 +111,13 @@ try {
|
||||
page = await context.newPage();
|
||||
attachPassiveListeners(page, "control", pageId);
|
||||
auth = await runControlCommand({ id: "startup-login", type: "login", createdAt: startedAt, source: "startup" }, async () => authenticate(context));
|
||||
await runControlCommand({ id: "startup-goto", type: "goto", path: targetPath, createdAt: new Date().toISOString(), source: "startup" }, async () => gotoTarget(targetPath));
|
||||
const startupGoto = await runControlCommand({ id: "startup-goto", type: "goto", path: targetPath, createdAt: new Date().toISOString(), source: "startup" }, async () => gotoTarget(targetPath));
|
||||
if (startupGoto?.degraded === true) {
|
||||
const error = new Error("startup target page is not ready: " + (startupGoto.degradedReason || "target-not-ready"));
|
||||
error.details = startupGoto;
|
||||
error.navigationReadiness = startupGoto.readiness || null;
|
||||
throw error;
|
||||
}
|
||||
observerPage = await context.newPage();
|
||||
attachPassiveListeners(observerPage, "observer", observerPageId);
|
||||
await runControlCommand({ id: "startup-observer-goto", type: "observerGoto", path: targetPath, createdAt: new Date().toISOString(), source: "startup" }, async () => {
|
||||
|
||||
Reference in New Issue
Block a user