Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

onReceivedError is overloaded #242

Closed
svantepolk opened this issue Aug 30, 2022 · 1 comment
Closed

onReceivedError is overloaded #242

svantepolk opened this issue Aug 30, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@svantepolk
Copy link

Turbo has made a choice to funnel all errors into one callback and one datapoint, despite the datatype referring to 3 different things like it's a C union. It could be an HTTP status, a WebViewClient error code, or Turbo's JS error.

Splitting out the HTTP status codes isn't too difficult by looking at numbers over 299, but in the case of the latter, it actually collides with an existing WebViewClient error code. This makes it difficult to figure out whether the 'turbo didn't load' error actually occurred, or if some other "Generic error" occurred.


https://developer.android.com/reference/android/webkit/WebViewClient#ERROR_UNKNOWN

@jayohms
Copy link
Collaborator

jayohms commented Feb 28, 2024

There's now a comprehensive solution in #317 with custom error types.

@jayohms jayohms closed this as completed Feb 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

2 participants