Repository navigation
fix: handle V8 termination, link labels and PermissionStatus events - #1476
lanyue-llk wants to merge 2 commits into
Conversation
Spider Bench A/B✅ All benchmark browser service runs completed; results are informational. Public HEAD: 184 / 240 rows; 38 / 48 sites produced rows; 10 unexpected empty sites. ✅ Deterministic fixture contract is clean. Common ancestor Public 48-site run · informational
Public-site content, timing, and memory are noisy. This single A/B run reports evidence only; site outcome counts explain missing rows without treating them as a deterministic regression. CPU and memory timelinesThese are bounded 40-point views of the same complete process-tree samples used by the HTML report. CPU uses 100% per occupied logical core; memory lines are RSS first and PSS second when complete PSS samples are available. Basexychart-beta
title "Base CPU"
x-axis "Elapsed seconds" [1.539, 2.541, 4.044, 5.045, 6.546, 7.547, 9.05, 10.052, 11.554, 12.555, 14.057, 15.058, 16.561, 17.563, 19.065, 20.066, 21.568, 23.07, 24.072, 25.073, 25.574, 26.576, 28.076, 29.077, 30.578, 31.58, 33.082, 34.082, 35.584, 36.586, 38.089, 39.089, 39.589, 40.59, 41.592, 42.093, 43.094, 44.096]
y-axis "CPU percent" 0 --> 500
line [65.81, 133.68, 147.64, 117.79, 143.84, 175.78, 179.69, 159.72, 133.85, 167.75, 59.9, 2, 115.86, 83.82, 67.91, 45.94, 75.9, 123.84, 151.75, 101.89, 115.71, 101.79, 132.04, 115.87, 109.88, 141.73, 113.82, 124.04, 73.91, 149.74, 107.76, 23.99, 0, 109.98, 93.77, 201.54, 65.96, 127.75]
xychart-beta
title "Base memory: RSS then PSS"
x-axis "Elapsed seconds" [0.037, 1.539, 2.541, 4.044, 5.045, 6.546, 7.547, 9.05, 10.052, 11.554, 12.555, 14.057, 15.058, 16.561, 17.563, 19.065, 20.066, 21.568, 23.07, 24.072, 25.073, 25.574, 26.576, 28.076, 29.077, 30.578, 31.58, 33.082, 34.082, 35.584, 36.586, 38.089, 39.089, 39.589, 40.59, 41.592, 42.093, 43.094, 44.096, 45.587]
y-axis "Memory MiB" 0 --> 500
line [12.18, 94.16, 123.48, 132.15, 156.83, 168.18, 159.98, 196.46, 192.07, 177.83, 179.79, 174.36, 151.94, 183.77, 202.8, 149.76, 156.2, 182.32, 165.58, 152.21, 276.63, 249.08, 220.16, 158.97, 154.53, 203.28, 176.29, 157.34, 151.59, 164.68, 202.05, 178.12, 163.8, 163.8, 185.47, 187.4, 193.96, 164.11, 190.8, 0]
line [9.2, 90.8, 120.08, 128.89, 153.97, 164.82, 156.57, 192.6, 189.97, 173.78, 176.73, 171, 148.51, 180.48, 199.39, 146.33, 152.77, 178.95, 162.08, 148.64, 273.46, 244.98, 216.62, 155.33, 151.32, 199.36, 172.56, 153.63, 147.83, 161.04, 198.65, 174.42, 160.1, 160.1, 181.78, 184.18, 190.52, 160.4, 187.14, 0]
HEADxychart-beta
title "HEAD CPU"
x-axis "Elapsed seconds" [1.547, 3.05, 4.051, 4.552, 5.553, 6.054, 7.556, 9.057, 10.559, 12.06, 14.062, 15.565, 17.065, 18.567, 20.069, 21.57, 23.072, 24.074, 24.575, 26.076, 27.578, 29.087, 30.601, 32.103, 33.605, 35.111, 36.613, 38.116, 39.616, 41.619, 43.119, 44.621, 46.123, 47.626, 49.128, 50.63, 52.13, 53.632]
y-axis "CPU percent" 0 --> 200
line [65.82, 131.79, 141.93, 117.85, 155.92, 165.9, 155.83, 93.97, 158, 57.95, 63.96, 143.7, 39.97, 91.91, 57.91, 37.97, 2, 0, 5.99, 51.99, 41.93, 93.76, 136.43, 109.88, 101.91, 149.6, 167.77, 127.71, 40.02, 127.8, 28, 133.79, 95.87, 0, 3.99, 139.8, 133.97, 133.83]
xychart-beta
title "HEAD memory: RSS then PSS"
x-axis "Elapsed seconds" [0.045, 1.547, 3.05, 4.051, 4.552, 5.553, 6.054, 7.556, 9.057, 10.559, 12.06, 14.062, 15.565, 17.065, 18.567, 20.069, 21.57, 23.072, 24.074, 24.575, 26.076, 27.578, 29.087, 30.601, 32.103, 33.605, 35.111, 36.613, 38.116, 39.616, 41.619, 43.119, 44.621, 46.123, 47.626, 49.128, 50.63, 52.13, 53.632, 55.084]
y-axis "Memory MiB" 0 --> 500
line [12.18, 93.79, 130.94, 161.61, 127.44, 155.17, 164.85, 175.02, 163.02, 168.81, 168.5, 166.54, 166.43, 143.97, 169.56, 195.38, 142.42, 140.29, 140.29, 140.28, 149.34, 166.88, 148.48, 162.91, 292.89, 209.1, 166.55, 163.31, 169.08, 150.14, 160.47, 151.15, 211.66, 169.63, 172.04, 158.54, 183.06, 150.63, 183.82, 0]
line [9.26, 90.61, 127.93, 158.37, 124.14, 151.85, 161.79, 171.75, 159.69, 165.56, 165.5, 163.16, 163, 140.62, 166.59, 192.13, 139.12, 137.04, 136.99, 137.01, 146.21, 163.64, 145.49, 159.73, 289.69, 205.82, 163.34, 160.14, 165.8, 146.72, 157.35, 147.76, 208.55, 166.24, 168.65, 155.15, 179.44, 147.21, 180.35, 0]
Deterministic fixture · required contractThe fixture exercises 15 routes: 8 are expected to emit rows and 7 intentionally exercise empty, loading, or timeout behavior.
Full HTML, JSON, CSV, logs, and page snapshots: workflow run and full The public-web A/B is informational. The exact HEAD fixture contract runs as a separate required CI check; timing and public-site content deltas remain non-blocking. |
CI Regression ReportSource CI run · source state at render:
Release regression — ✅ HEAD/base failures 0/0; raw binary 0.00%Package and image size
Startup latency and PSS
Concurrency matrix
Frontend differential — ❌ 1,019/1,020 cases matched; 1 issues
First failing cases
Agent episodes · Moli vs Chromium — ✅ 8/8 Moli episodes passed; 0 failures
Runtime and CDP session contracts — ✅ 26 contract cases; 0 failures
CDP smoke — ✅ 52/52 groups passed; 621 scenariosWorkers: 4 · cumulative group time: 139.26 s · failed groups: 0
WebMainBench · 545 pages — ✅ 545/545 completed; 0 unexpected failures
Frozen HTML · Linux · Diagnostics: All artifact fields are parsed by the trusted default-branch renderer; missing or invalid inputs remain visible as unavailable. |
Sequential Navigation Soak A/B✅ HEAD completed the 200-navigation resilience and memory observation. One browser process, one target, and one CDP session navigate CSDN → SegmentFault → Huaban → example.com repeatedly. This run issued 200 Common ancestor Session resilience
A public-page failure is reported separately from an unrecoverable session. The soak requires all navigation attempts, zero failed recovery, zero lifecycle/network ordering violations, and complete resource evidence. Process-tree memory
HEAD memory by 50-navigation quarter
Raw reports and per-navigation boundary samples: workflow run and full Public-site timing and memory are observational. Use the A/B deltas and trend shape as evidence, not as a deterministic performance threshold. |
|
Superseded cleanly by two scoped PRs:
No unique code remains in this mixed PR. |
Watchdog termination can make a captured WeakMap call return no value after V8 resets the isolate's termination flag. Wrap construction, get and set in local TryCatch scopes, recognize
has_terminated(), rethrow termination and propagate the absent cross-origin Window/Location surface. Ordinary intrinsic failures still panic. Tests cover interrupted construction and insertion, recovery, observer identity and an ordinary throwing intrinsic.The HTML-to-Markdown converter uses an empty anchor's own nonblank
aria-labelwhen it has no descendant content. Visible inline and block descendants remain primary, including code blocks, headings, lists and tables; ancestor and sibling labels are never borrowed.PermissionStatusnow inheritsEventTargetand has per-instance listener storage, as required by the Permissions IDL. Tests cover listener removal, once, target identity, instance isolation and the illegal constructor.This branch contains only these fixes on main. It does not import the content/navigation stack. Office document MIME classification is already fixed on main and was validated without duplicating that change.
Validation on ARM64 Linux with
rust:1.96.1-bookworm:cargo fmt --alland final format check passed.cargo clippy --workspace --all-targets --all-features -- -D warningspassed before the final TryCatch refinement;cargo clippy -p moli-renderer-v8 --lib --all-features -- -D warningspassed again on the final renderer code.Initial selected nextest tests: 7 passed (3 cross-origin cache tests, PermissionStatus events, link-label regression, binary response headers and document MIME classification).
The same link-label regression failed against unmodified main (
[](/report)instead of[Open report](/report)). The first termination tests also exposed the insufficient isolate-flag check and passed after the TryCatch correction.Additional link regressions: 3 passed, with the block-descendant regression first failing on the prior implementation. Package clippy passed for all moli-html2md targets.
Full workspace nextest did not reach test execution: building the renderer test binary was killed by the kernel at about 7.39 GiB resident anonymous memory plus 1.75 GiB swap in the original 8 GiB ARM environment. Validation was then explicitly narrowed to the affected functional tests. No CI result is claimed.