Repository navigation
Conversation
…after release A provider can bind its artifact lookup to the session it prepared, for example to a per-session data center. After release, the runtime fell back to the provider-wide lookup, so a later `artifacts` call asked the wrong endpoint. A released lease now keeps the lookup its preparation bound and passes it the same provider and WebDriver session ids as the active path. A provider without one still uses the runtime-wide lookup. A prepared session can now read the hub's create-session answer through `describeCreatedSession`: the provider's own session id, for a hub whose jobs and media are keyed by an id other than the WebDriver session id, and the model the hub actually allocated. The device keeps its requested name, which commands select it by. An empty id counts as absent. When anything after the hub created the session throws, the allocation deletes that session and runs the provider cleanup before it fails, keeping the original error.
|
Thanks for the contribution. No code problem that must be fixed was found at 3691aca, but the change is not ready yet: CI results and answers about the need for it are still missing. The answers to these questions decide whether the change fits the project:
CI has not run on this commit. The CI, Android, Apple, Linux, Size and Pull Request Body checks are waiting for approval to run for the fork, and the only check run, Proof, was skipped. The change is in No live provider run is required for the bundled providers, because their behavior is unchanged. Not verified here: tests, typecheck and other local checks were not run, and the regression tests were judged by reading. The new hook and bound-lookup routes have no bundled consumer and no live evidence tied to this head. The Sauce Labs API and the full diff of #5123 were not reviewed. Before merge, the questions above need answers, and CI needs to run and pass. |
Summary
A released lease now lists artifacts through the lookup its prepared session bound, with the same provider and WebDriver session ids the active path passes; providers without one keep the runtime-wide lookup. A prepared session can read the hub's create-session answer through
describeCreatedSession: its own provider session id, for hubs that key jobs by another id, and the allocated model, while the device keeps the requested name commands select it by. An empty id counts as absent. If anything after the hub created the session throws, the allocation deletes that session and runs provider cleanup, keeping the original error.Part of #5121. Needed by the Sauce Labs plugin PR; no bundled provider sets the new hook.
Before / after
No observable change for BrowserStack, AWS Device Farm or TestMu AI: none binds a per-session lookup or sets
describeCreatedSession. The new paths are covered by runtime-session tests.Validation
Tested at 3691aca: provider-webdriver unit tests 349 pass; cloud-webdriver provider scenarios 34 pass; typecheck clean. The regression tests fail without the session delete and without the runtime-wide fallback.
CI obligations: full unit, provider-integration, gates.
Risks: none known.
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.