-
Notifications
You must be signed in to change notification settings - Fork 154
crash on using webview #105
Comments
@hsiami Did you tried to test on Android Emulator or Physical device? |
Refer to stack trace from https://stackoverflow.com/questions/47944586/package-not-found-com-android-chrome
This seems not related to my library. But I will keep this issue because crashing might caused by Resource class from my library. /**
* Returns the package id of the given {@code packageName}.
*/
public int getPackageId(Resources resources, String packageName) {
SparseArray<String> packageIdentifiers =
resources.getAssets().getAssignedPackageIdentifiers();
for (int i = 0; i < packageIdentifiers.size(); i++) {
final String name = packageIdentifiers.valueAt(i);
if (packageName.equals(name)) {
return packageIdentifiers.keyAt(i);
}
}
throw new RuntimeException("Package not found: " + packageName);
} |
I tried on both Emulator and physical device |
Without your library app doesn't crash. and with your library app crashes only when I change the locale and then create an instance of WebView. No idea yet? |
for solving webview problem I used this library instead: |
@hsiami Thank you for alternative library suggestion. I will fix this issue soon. In Lingver library, there're some information about WebView issue that might useful for me to solve this issue. |
I also have this problem
|
for solving webview problem I used this library instead: |
It's crashing on webview randomly. |
@akexorcist I can see you have resolved the crash issue (saw in commits) |
@nagesh-kashyap-r still in testing please wait until tomorrow |
1.2.10 is live. please check on your project and don't forget to give me a feedback. |
@akexorcist Thanks!!!! Crash issue is resolved! |
I also get the same issue. Only for the first time. The library is very good. I could change any language on my app. But I got this issue. Hope you fix it soon. Ver 1.2.10 and Android 7.0 |
@akexorcist I have tried the 1.2.10 and I get the error when creating an instance of WebView or just setting it to debug. Do you have any tips ? |
This crash issue is still rising with version |
lingver is better. Thanks |
Note: webview-crash.mp4Let me investigate more about it. |
This issue was fixed in 1.2.11. Please check it out |
i guess u just code locazation,and u just only Override application.getResources but not Override getAssets. |
Since AndroidX AppCompat has per-app language preferences for backward compatibility. Please migrate this library to AndroidX for more stability, compatibility, and longer support from Google team. Thank you for your support |
when I change locale and then use webview app crashes for the first time.
var webview = WebView(this)
The text was updated successfully, but these errors were encountered: