Commit Graph
191 Commits
Author SHA1 Message Date
ldm0 3d124b5690 fix(navigation): check beforeunload before browser fetches
Run browser-initiated main-document checks through the existing asynchronous
lifecycle scheduler before Fetch interception or network loading. Project the
source turn first, reject superseded navigation tokens, and share navigation
finalization so failed checks retain the committed document and release state.
Foreground DevTools callers remain pending through the check and load, preserving
typed navigation results and the captured target owner.

Keep beforeunload and commit unload commands out of nested non-V8 Page-agent
dispatch while the owner is debugger-paused. Cover real navigate/reload/history
responses, retained documents, pause/resume, supersession, and Fetch ordering.
2026-11-24 14:36:20 +08:00
ldm0 efca9affd1 fix(navigation): preserve inherited top-level about:blank state 2026-11-24 14:36:03 +08:00
ldm0 754c138b07 fix(navigation): defer unload until document replacement 2026-11-24 14:34:56 +08:00
ldm0 c28d8273ea fix(preload): consume document-owned preload responses 2026-11-24 14:32:20 +08:00
ldm0 ca833c7e86 fix(history): restore top-level navigation snapshots
Carry committed renderer history through browser navigation requests and
restore structured state, entry identities, and activation before new
Document scripts execute. Read the latest committed source entries when
creating the destination so state updates made during a pending response
are retained.

Keep browser traversals aligned with native Document identities, rebuild
private history ordinals for restored top-level entries, and use native
entry indices for fragment mutations after a cross-origin history prefix.

Cover structured-state restoration, pending-navigation source updates,
fragment indices, browser-owned back/forward traversal, and same-Document
realm and element preservation after WebDriver history restoration.
2026-11-24 14:31:52 +08:00
ldm0 6f04d6d2da refactor(molio): split viewport page creation and popup adoption 2026-11-24 14:06:54 +08:00
ldm0 ea713850e4 fix(molio): share popup and Location navigation handling 2026-11-24 14:06:54 +08:00
ldm0 6fc898d229 fix(molio): preserve popup navigation context and tab state 2026-11-24 14:06:54 +08:00
ldm0 6dd8cd1c84 fix(molio): open renderer popups in tabs 2026-11-24 14:06:54 +08:00
ldm0 b26c9aa7f4 refactor(molio): decouple navigation state from viewport frames 2026-11-24 05:52:38 +08:00
ldm0 d79cb70d37 feat(cdp): render DevTools node and rectangle highlights 2026-11-24 04:50:24 +08:00
ldm0 b086aaa1fb fix(molio): gate desktop download handling 2026-11-24 03:43:26 +08:00
ldm0 80468e1335 feat(molio): add file downloads and a downloads page 2026-11-24 03:43:26 +08:00
ldm0 401e4c461c fix(molio): show page favicons in tabs 2026-11-23 23:32:36 +08:00
ldm0 5a6c0eb5e4 perf(renderer): coalesce pending wheel input across render modes 2026-11-23 22:18:56 +08:00
ldm0 b334fabb4a feat(renderer): add opt-in desktop viewport support 2026-11-23 22:18:56 +08:00
ldm0 b10e63b2f3 test(core): stabilize shared readiness deadline coverage 2026-11-23 21:24:35 +08:00
ldm0 9e5a752aaa fix(cdp): report committed Document MIME types in frame snapshots
Extracted from wpt-misc-fix commit cadb514514d0bf9486929ad48439353d8039dd05.
2026-11-23 00:23:55 +08:00
ldm0 d3e8d3af15 feat(renderer): advance realtime rendering without capture
Drive animation frames, resize and intersection observers, environment changes, scroll events, and font completion through the page owner. Expose the realtime policy in fetch and serve. Dispatch wheel input through the existing action window and keep transient output separate from screen publication.
2026-11-22 03:15:08 +08:00
ldm0 359c32095a refactor(network): separate request updates from transport observations 2026-11-20 02:23:32 +08:00
ldm0 3cfec23af6 refactor(target): decouple Browser sessions from Renderer readiness
Commit Browser attachment and withdrawal independently of native Page and
Inspector initialization. Keep shared initial builds on the target and bind
queued Main/IO work to its admitted session connection and native agent.

Separate minimum Inspector connect from ordered binding replay, and publish
unobserved initialization facts without snapshots or completion fences.
Retire Browser contributions immediately and supervise cleanup using the
original native authority, including failed or replaced connections.
2026-11-20 02:10:47 +08:00
ldm0 1a08aa3454 fix(target): supervise deferred Inspector initialization 2026-11-20 02:10:47 +08:00
coolswood f3504965ab fix(target): complete Target.attachToTarget while a JavaScript dialog is open
Chromium resolves Target.attachToTarget in ~0 ms even when the target
shows a modal alert/confirm/prompt; moli parked the attach response
behind the renderer's modal wait because the attachment binding apply
was awaited before the commit.

Defer the binding apply instead: a dialog that is already published for
the target (or one that opens while the apply waits) hands the
still-queued dispatch to a supervised background wait, and the attach
commits immediately. The apply settles once the renderer frees up and
its completion is consumed by the scheduler with the same failure
tolerance as the synchronous path, minus the response predecessor
fence that no longer orders anything after publication. Renderer FIFO
still keeps the new session's first command behind the bindings.

createTarget/setAutoAttach share the broader dispatch path and remain
follow-up work.
2026-11-20 02:10:47 +08:00
ldm0 7c7c130d19 refactor(diagnostics): publish only completed error reports 2026-11-20 01:52:30 +08:00
ldm0 936886a80d refactor(diagnostics): initialize one subscription per browser 2026-11-20 01:52:30 +08:00
ldm0 242bcffeca feat(runtime): publish completed exception reports 2026-11-20 01:52:30 +08:00
ldm0 c36b90fad4 refactor(runtime): use one unbounded diagnostics subscription 2026-11-20 01:52:30 +08:00
Noz Wu 31ec48b69d feat(runtime): expose uncanceled runtime failures 2026-11-20 01:52:30 +08:00
ldm0 a679836d3c fix(runtime): preserve diagnostic origin and script request identity 2026-11-20 01:52:30 +08:00
Noz Wu c687399bac feat(runtime): publish exception and script load diagnostics 2026-11-20 01:52:30 +08:00
ldm0 1a770232e5 refactor(devtools): isolate page DOM frontend modules 2026-11-18 19:09:35 +08:00
ldm0 2206f32f40 refactor(devtools): isolate optional runtime modules 2026-11-18 19:09:35 +08:00
ldm0 2c4f149c30 fix(devtools): close optional configuration gates
Compile renderer tests without DevTools and run the standalone consumer against a local fixture. Route Service Worker client notifications through WorkerNavigator in worker realms.
2026-11-18 19:09:35 +08:00
ldm0 3ce8ad6cd8 feat(devtools): make external renderer automation optional 2026-11-18 19:09:35 +08:00
ldm0 5d222fe043 feat(browser): align disabled web security with Chromium instance policy 2026-11-18 00:10:43 +08:00
ldm0 47399e4ec6 fix(files): prepare shared directory selections off the protocol thread 2026-11-16 19:42:47 +08:00
ldm0 ed9ad079c2 refactor(worker): own fetch and XHR loading natively
Give each load a stable native network handle and single-use interception ports. Keep Worker Promise settlement separate from network completion, route observations to Worker targets, and remove the parent request table and continuation messages.

Cover cancellation, streaming, request overrides, authentication, CSP and Service Worker responses. Keep the bucket-deletion test transaction active until retirement instead of racing its normal auto-commit.
2026-11-16 15:23:35 +08:00
ldm0 1a752c0181 fix(webdriver): preserve raw key locations in actions 2026-11-15 16:56:15 +08:00
ldm0 6d5e8580b0 fix(input): preserve keyboard event location through dispatch 2026-11-15 16:56:15 +08:00
ldm0 abcff16028 fix(fetch): limit idle waiting to initial page readiness 2026-11-15 00:48:02 +08:00
ldm0 9247282d21 fix(fetch): complete idle liveness and deadline enforcement 2026-11-15 00:48:02 +08:00
ldm0 03776063e6 feat(fetch): add event-loop idle wait mode
Wait for user timers, native async operations, dedicated workers, WebSockets and receiving MessagePorts using their existing resource owners and Page task sources. Finish a microtask checkpoint before observing exhaustion, drain terminal callbacks, and follow replacement navigations through the shared idle wait driver.

Apply the existing absolute timeout to idle readiness and recheck after automation scripts. Keep internal AbortSignal timeouts and transferable-stream plumbing from independently retaining the loop. Add CLI and native observer regressions.
2026-11-15 00:48:02 +08:00
Noz Wu 3a2dbae84a feat(core): expose renderer output transport sender 2026-11-14 23:49:01 +08:00
ldm0 1fc3848c6c fix(download): stream child-frame attachments with sandbox checks 2026-11-14 23:13:54 +08:00
ldm0 aae86aac05 fix(fetch): apply effective request overrides before fulfillment
Apply accumulated URL, method, upload and scoped-header edits before fulfilling a request. Share RequestOverrides with continuation and centralize pending request snapshot updates, so a later session fulfilling 307/308 retains the effective request body and relative-URL base.
2026-11-14 16:35:43 +08:00
ldm0 6206b093c4 fix(fetch): carry exact interception class sets
Adapt the class-set work from #2704 to native synchronous XHR from #2729. Keep URL, stage and session matching with protocol owners while excluding unrelated resource classes before native routing.
2026-11-14 02:56:32 +08:00
ldm0 dbaf8d0617 fix(xhr): process interception decisions before response body EOF
Expose ordinary controlled hop headers with a cancellable pending body so
response pauses, redirects and initial auth challenges can advance before EOF.
Share native capture with Fetch body reads and scoped IO streams; retire the
original transfer on fail, fulfillment or stream close without Page reentry.

Add body-gated Window/Worker and sync/async regressions and preserve resumed
XHR streaming. Drain two existing protocol fixtures through actual stream EOF.
2026-11-13 22:37:15 +08:00
ldm0 9e357b95e4 feat(xhr): keep network interception live during synchronous sends
Route intercepted Window and dedicated Worker XHR through shared native
request, authentication and response decisions. One-shot pause ports let the
existing protocol/session machinery continue, fail or fulfill a request
without queueing a Page command behind its suspended JavaScript stack.

Publish native network facts across an explicit synchronous-wait scope, preserve
normal asynchronous streaming delivery, and cancel loads before owner
teardown. Remove the synchronous-only URL-rule copy and retain the canonical
protocol matcher, session chains and request identities.

Cover Page task suspension, independent protocol decisions, binary overrides,
CORS preflight, authentication, redirects, streaming, multi-session cleanup,
Worker termination and target close. Await actual callback/command identities
where network acknowledgements no longer imply Page delivery has finished.
2026-11-13 22:37:15 +08:00
ldm0 e8ce829d88 fix(xhr): enforce exact interception URLs for synchronous requests 2026-11-13 22:37:15 +08:00
ldm0 7131157013 refactor(renderer): capture Page window identity before document creation 2026-11-13 22:16:31 +08:00