script: Make file picker selection flow asynchronous#39893
Merged
Conversation
06cf707 to
cdad6c4
Compare
|
🔨 Triggering try run (#18530082150) for Linux (WPT) |
cdad6c4 to
27bbfe4
Compare
|
Test results for linux-wpt from try job (#18530082150): Flaky unexpected result (34)
Stable unexpected results that are known to be intermittent (27)
Stable unexpected results (1)
|
|
|
5c6ae67 to
fde08b8
Compare
|
🔨 Triggering try run (#18589548484) for Linux (WPT) |
|
Test results for linux-wpt from try job (#18589548484): Flaky unexpected result (26)
Stable unexpected results that are known to be intermittent (29)
|
|
✨ Try run (#18589548484) succeeded. |
delan
commented
Oct 20, 2025
| }) | ||
| .collect(); | ||
|
|
||
| // WebDriver expects that if any of the files isn't found we don't select any files. |
Member
Author
There was a problem hiding this comment.
can we link to the spec or similar about this?
delan
commented
Oct 20, 2025
Comment on lines
+179
to
+182
| enum SelectFilesAction { | ||
| Dismiss, | ||
| Submit, | ||
| Continue, |
Member
Author
There was a problem hiding this comment.
thanks for cleaning up the control flow here!
fde08b8 to
6462f62
Compare
Co-authored-by: Martin Robinson <[email protected]> Signed-off-by: delan azabani <[email protected]>
- Fix warnings - Fix FileManager unit test - Fix issues with WebDriver interaction with `<input type=file>` Signed-off-by: Martin Robinson <[email protected]>
Signed-off-by: Martin Robinson <[email protected]>
6462f62 to
22b9d8a
Compare
mrobinson
approved these changes
Oct 20, 2025
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.
Previously the
<input type=file>would wait synchronously for file selectionresults from the embedder. This change moves that synchronous wait to the
FileManagerworker thread. The main benefit is that script is not blocked waitingfor the embedder. The synchronous wait on the worker thread is not a large issue
because it is run from a thread pool, though a later change could also remove
that synchronous wait.
In addition, the API surface for file selection changes a bit as there is now a
dismissmethod which differentiates between selecting no file and not making a choice at
all.
Testing: Covered by exiting WPT, WebDriver conformance, and unit tests.