Repository navigation
Conversation
|
Diffuse report: AARJAR |
|
Benchmark report:
|
CAMOBAP
approved these changes
Oct 31, 2026
e271828-
added a commit
that referenced
this pull request
Nov 3, 2026
* fix(sdk): handle WebView render process crash Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * test(sdk): cover WebView render process crash Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * fix(sdk): don't reuse or retry a WebView whose renderer is gone A dead WebView went through onFailure, so a retry predicate could silently retry on it, and HCaptcha kept the cached verifier, so the next verifyWithHCaptcha() reused the destroyed WebView. Route it through a dedicated onWebViewGone that tears the WebView down and reports the failure without retrying, and let HCaptcha drop the cached verifier. The cold start reuses the config from an earlier setup(config) instead of falling back to the manifest site key. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(sdk): verify again after the render process is gone End to end in headless and dialog mode: once the renderer is gone the failure is reported, and a following verifyWithHCaptcha() gets a token from a fresh WebView instead of reusing the dead one. The renderer death is signalled through the WebView's own client rather than chrome://crash: all WebViews of the app share one renderer, so a real crash would also kill the ones other tests left behind and fire their listeners. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(sdk): recover cleanly when the WebView is gone mid-flow - Dialog: land queued fragment transactions before checking whether the dialog is already shown, and remove a dead dialog synchronously, so a verify from the failure listener shows a fresh dialog and a crash before the show commits leaves nothing on screen. - Client: scope the WebView-gone callback to its setup generation, so a stale WebView sharing the renderer can't clear the replacement verifier or report a second failure. - Compose: start over with a fresh WebView on the next recomposition after the renderer is gone; document retrying via key(). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(sdk): don't touch a destroyed client or WebView afterwards - destroy() cancels the pending token expiration, so a replaced client no longer reports TOKEN_TIMEOUT for its last token. - The dialog skips resetting its WebView in onDestroy() once destroy() released it, which logged "attempted to call on a destroyed WebView". Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(sdk): keep the fields the render-process-gone tests reach by reflection R8 renamed them in the minified UI test build, failing it with NoSuchFieldException. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(sdk): isolate WebView crash recovery callbacks (#292) * fix(sdk): isolate WebView crash recovery callbacks * fix(sdk): retire verifier before reconfiguration --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Co-authored-by: e271828- <e271828-@users.noreply.github.com>
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.
When a renderer exits during a retry, cleanup from an older dialog can clear the replacement dialog's shared preload reference. The replacement then displays an uninitialized WebView. Dialog cleanup now clears that reference only when it owns the WebView.
An in-flight JavaScript bridge callback can also arrive after the failure listener starts a fresh verification. Renderer failure now invalidates the old verifier's callbacks before notifying the app, so a queued token or load event cannot complete the new attempt. The renderer error still reaches the failure listener once.
Adds regressions for both callback orders and queued bridge events. This PR targets #287.
Validation:
:sdk:check :compose-sdk:checkpassed (117 SDK and 2 Compose unit tests); five targeted API 33 Android tests passed, including real renderer termination and dialog recovery.