Repository navigation
Add a browser events conformance scenario - #258
adityareddy-dev wants to merge 3 commits into
Conversation
Pull request dashboard statusWaiting on reviewers · refreshed 2026-10-17 01:49 UTC Review the latest changes. Status above doesn't look right?
|
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The launcher, scenarios, generated coverage, tests, documentation, and CI integration are consistent and complete.
Review effort: Balanced
Findings: None
What changed in this PR
Adds browser event conformance coverage using headless Chrome and an OTLP/HTTP relay.
Changes:
- Adds reusable browser launching, event synchronization, and OTLP relay support.
- Adds errors, console, and web-vitals scenarios.
- Integrates browser scenarios into CI and documentation.
| File | Description |
|---|---|
README.md |
Lists the browser domain. |
.github/workflows/runner.yml |
Builds and tests browser scenarios. |
tools/js/README.md |
Documents browser scenario support. |
tools/js/browser-launcher/index.js |
Implements browser execution and OTLP relay. |
tools/js/browser-launcher/page.js |
Configures browser log collection. |
tools/js/browser-launcher/package.json |
Declares launcher dependencies. |
tools/js/browser-launcher/test/index.test.js |
Tests page serving and relaying. |
scenarios/browser/README.md |
Documents browser coverage. |
scenarios/browser/js/README.md |
Documents JavaScript scenarios. |
scenarios/browser/js/package.json |
Defines the browser workspace. |
scenarios/browser/js/package-lock.json |
Locks browser dependencies. |
scenarios/browser/js/.npmrc |
Configures local package installation. |
scenarios/browser/js/.prettierignore |
Excludes generated artifacts. |
scenarios/browser/js/chromium/scenarios/package.json |
Defines workload package metadata. |
scenarios/browser/js/chromium/scenarios/errors.js |
Generates unhandled errors. |
scenarios/browser/js/chromium/scenarios/console.js |
Generates console events. |
scenarios/browser/js/chromium/scenarios/web-vitals.js |
Generates page content for web vitals. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/package.json |
Declares instrumentation dependencies. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/run.js |
Selects and launches scenario pages. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/pages/errors.js |
Configures errors instrumentation. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/pages/console.js |
Configures console instrumentation. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/pages/web-vitals.js |
Configures web-vitals instrumentation. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/conformance.yaml |
Declares conformance scenarios. |
scenarios/browser/js/chromium/opentelemetry-browser-instrumentation/data.json |
Records generated coverage. |
Files not reviewed (1)
- scenarios/browser/js/package-lock.json: Generated file
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
A few things I wasn't sure about and would change if you prefer. The scenarios declare The path is The browser isn't pinned. #162 adds What it reports right now:
The workflows here are waiting on approval to run. The same commit ran green in my fork, adityareddy-dev#1 |
|
Nudge on this one, it adds the browser events scenarios and every upstream check passed on |
|
@jaydeluca could you take a look at the browser events scenarios? Checks and CLA passed. The main question is whether to share the launcher with the Fetch scenarios. |
This is a proof of concept. Jay suggested trying browser instrumentation here while I was researching it for the ecosystem explorer (open-telemetry/opentelemetry-ecosystem-explorer#1187). It adds a
browserdomain with three scenarios for@opentelemetry/browser-instrumentation0.8.1 (errors, console, web-vitals). Each one opens a page in the Chrome already on the machine, and the page's OTLP exports go through its own origin to the runner's HTTP bridge, since the bridge doesn't answer CORS.It covers events only and sits beside #162 and #163, which cover the older fetch and XHR span packages with their own browser runner. The earlier Windows and fork Ubuntu runs produced the committed
data.json. On October 15 I reran all three scenarios on macOS with Weaver 0.26.1 and registry v1.44.0, and the coverage matched again. Each scenario reports warnings, including the missingbrowser.consoleevent and method attribute in that registry. The web-vitals scenario waits for one event, it does not establish coverage of every web vital.Validation on October 15:
npm ci, the six launcher unit tests, browser workspace formatting, and all threeotel-conformance ... --report-onlyscenarios passed. This remains a proof of concept with an unpinned browser and the HTTP runner registry.