Repository navigation
Conversation
The demo now launches the installed Chrome or Edge through Playwright's channel option. Without one, it downloads only Chromium's headless shell instead of the full browser. A channel browser that fails to start falls back to Playwright's own build. OPENADAPT_FLOW_BROWSER selects auto, chrome, msedge, or bundled. The tutorial's record run and both replays share one browser process. Each run still gets a fresh browser context. The OCR models load on a background thread while the browser starts. Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
On a fresh macOS install the first OpenCV import takes 9 to 13 seconds while the system verifies its native libraries. The demo now starts that load on a background thread before it starts the browser. The browser process code moves to a module that does not import OpenCV. The demo prints one line per stage as it starts, instead of staying silent until both runs end. Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
The demo's summary stays at most eight lines. Stage progress now rewrites a single line on a terminal and prints nothing when output is piped. Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
abrichr
marked this pull request as ready for review
October 17, 2026 04:07
abrichr
enabled auto-merge (squash)
October 17, 2026 04:07
abrichr
disabled auto-merge
October 17, 2026 04:49
replay, resume, bench, record, the attended service, and generated MCP tools still launched Playwright's own Chromium, while PlaywrightBackend picked the installed Chrome. A project pinned under one browser then replayed under the other, so the qualification environment check halted the Desktop check-it practice run. All of these paths now go through launch_chromium. Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
The attended service now picks and prepares the browser through launch_chromium, which runs after Playwright starts. The test still checks that every step runs on the owner thread. Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
Member
Author
|
Carried over into the monorepo as OpenAdaptAI/OpenAdapt#1189 (merged as e395969abee94bdd906beb7d277dc534b05c8e47). openadapt-flow now lives in OpenAdapt/packages/flow. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
channeloption. When neither exists, Flow downloads only Chromium's headless shell (218 MB on disk, against 576 to 587 MB for the full download in 2.0.0). Headed runs still get the full build. If a channel browser is present but won't start,autofalls back to Playwright's build.OPENADAPT_FLOW_BROWSERacceptsauto,chrome,msedge, orbundled.close()took about 2.8 s.import cv2takes 9 to 19 s while the system verifies OpenCV's 78 MB of bundled libraries. The demo now starts that load on a background thread before it starts the browser. The browser-process code moved tobackends/_browser_process.py, which doesn't import OpenCV.uvx --python 3.12 --from 'openadapt-flow[browser]' openadapt-flow demo, with pip as the alternative.Nothing in recording, compiling, gating, or verification changed. Both runs still really execute, and the second run still halts on the system-of-record read.
Measurements
MacBook Pro (12 cores), Python 3.12. Each run uses a new virtual environment. The machine was shared with other jobs (load average 8 to 43), so single runs vary by a few seconds. "Cold" means an empty pip or uv cache and an empty
PLAYWRIGHT_BROWSERS_PATH. Baseline is the published 2.0.0 installed with pip. "New" is this branch's wheel installed withuv pip. Every run printed "Done and checked" for run 1 and "Stopped" for run 2.In a reused environment (native libraries already verified), the demo takes 19.7 to 22 s. First output appears at 0.5 s, and the first stage line at 1.6 s.
Where the time goes (fresh environment, new build)
import cv2(macOS library verification)The remaining large costs are the OpenCV first load and OCR. Removing them means replacing the OCR stack, which needs the identity evidence rerun first. This PR doesn't do that.
Signed-off-by: Richard Abrich richard.abrich@mldsai.com
Same browser on every web path
CI found that
replay,resume,bench,record, the attended service and generated MCP tools still launched Playwright's own Chromium, whilePlaywrightBackendpicked the installed Chrome. A project pinned under one browser then replayed under the other, and the qualification environment check halted the Desktop check-it practice run (tests/test_desktop_check_it_cli_mockmed.py). All of these paths now go throughlaunch_chromium.tests/test_console.pynow expects browser setup inside the Playwright context, still on the owner thread.