INNER CODE UNIT · JavaScript

forceStop

figranium/figranium · src/agent/figranite/index.js:219

    const forceStop = async () => {
        isForceStopped = true;
        userStopped = true;
        stopRequested = true;
        logs.push('Execution force-stopped by user after 3s timeout.');
        try {
            await syncBrowserState();
            if (page) await page.close().catch(() => {});
            if (context) await context.close().catch(() => {});
            if (browser) await browser.close().catch(() => {});
        } catch {
            // ignore
        }
    };

    if (runId) {
        registerActiveRun(runId, { forceStop });
    }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…