feat(selenium-devtools-py): record a dense filmstrip into the trace - #342
Merged
Conversation
Greptile SummaryThe PR adds dense Selenium Python filmstrips to backend-generated trace archives and completes the previously requested lifecycle and retry fixes.
Confidence Score: 5/5The PR appears safe to merge because the previously reported filmstrip lifecycle and retry failures are fixed. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| packages/selenium-devtools-py/src/selenium_devtools/init.py | Enables filmstrip capture and coordinates frame streaming, retry watermarks, and run-state reset; the previously reported retry boundary issues are addressed. |
| packages/selenium-devtools-py/src/selenium_devtools/instrumentation.py | Collects finalized and live recorder buffers and preserves live frames across uninstall before session state is cleared. |
| packages/selenium-devtools-py/src/selenium_devtools/trace_export.py | Streams frame batches defensively without allowing optional filmstrip failures to break the Selenium run. |
| packages/backend/src/baselineStore.ts | Accumulates the new screencast frame stream for subsequent server-side trace export. |
| packages/backend/src/trace-export.ts | Passes non-empty dense filmstrip data into trace generation while preserving sparse fallback behavior. |
| packages/selenium-devtools-py/tests/test_filmstrip.py | Covers batching, live and finalized frame retention, opt-out behavior, retry boundaries, equal timestamps, decimation, and uninstall ordering. |
Sequence Diagram
sequenceDiagram
participant R as Selenium recorder
participant P as Python adapter
participant B as Backend
participant T as Trace exporter
R->>P: Buffered screencast frames
P->>B: screencastFrames batches
B->>B: Accumulate frames in active run
P->>B: traceExport request
B->>T: Export active run with dense filmstrip
T-->>B: trace.zip
B-->>P: Export result
Note over P,B: Failed exports retry from the inclusive timestamp watermark
Reviews (4): Last reviewed commit: "fix(selenium-devtools-py): keep the boun..." | Re-trigger Greptile
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 & why
Type of change
Packages touched
shared(types and contracts)core(framework-agnostic capture/reporting)elements(published element/snapshot API —@wdio/elements)service(WebdriverIO adapter)nightwatch-devtools(Nightwatch adapter)selenium-devtools(Selenium adapter)backend(server)app(UI)script(page-injected runtime)selenium-devtools-pyNotes for reviewers
Screenshots / recordings