-
-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Crash SkSurface::getCanvas in android 10(Q) #9067
Comments
The versions mentioned in the issue for the following packages differ from the latest versions on npm:
Can you verify that the issue still exists after upgrading to the latest versions of these packages? |
happens to me aswell, works fine on android 9, 7.1.1, but crashes on android 10 disabling hardware acceleration fixes it for me. |
Can you provide a more info about your Android Device model and repro code? Can you repro the issue if you change the animation using |
adding it to the first stack fixed the crash for me |
@sergeykimaia can you mention your device model please? if it's a device specific issue, we could add a conditional for that model |
@satya164 i ran it on an emulator Pixel_2_API_29 |
are you using react-native-webview? |
@satya164 yes |
can you also try adding |
@satya164 crash no longer happens. |
thanks! I'll add the workaround to troubleshooting docs and talk to webview maintainers to figure something out to avoid it. |
@sergeykimaia can you check what version of |
@WoLewicki |
@sergeykimaia can you check your |
@WoLewicki checked, haven't used it anywhere. |
Ok, thank you. |
I face the same crash on android 9 and 10 when I navigate from screen with webview. @satya164 do you need a repo to reproduce this bug?
I use this workaround to hide a webview before animation starts because we need
|
I got the same behavior but in a slightly different setup. Posting here in case it helps someone else. Note that my code is basically copied from the Formidable's Autoheight WebView example & I'm using Environment
Things I tried
const window = useWindowDimensions();
const { autoheightWebshellProps } = useAutoheight({
webshellProps: {
// ... props
} ,
// THIS IS WHAT MATTERS. It works even if you set it to '1' but you will
// get a small screen flash so try to set it to a reasonable number.
// One way to fix that is to set a fixed `width` below if it's possible or
// set resetHeightOnViewportWidthChange to true.
// See: https://formidable-webview.github.io/webshell/docs/api/interfaces/autoheightparams
initialHeight: window.height,
});
return (
<ScrollView
{...scrollViewProps}
>
<WebShell {...autoheightWebshellProps} />
</ScrollView>
); This option solved all of the issues. Again, no need to set |
Hello @satya164 Setting |
Hey! This issue is closed and isn't watched by the core team. You are welcome to discuss the issue with others in this thread, but if you think this issue is still valid and needs to be tracked, please open a new issue with a repro. |
This enables a workaround for a crash in combination with react-navigation. See react-navigation/react-navigation#9067 (comment)
It seems the fix |
I did this and it didn't crash. |
App have been crash in android 10. Errors bellow.
============Error===============================
OS Version: Android 10 (QP1A.190711.020.T720XXU1CTI1)
Report Version: 104
Exception Type: Unknown (SIGSEGV)
Application Specific Information:
Segfault
Thread 0 Crashed:
0 libhwui.so 0x77964783c4 SkSurface::getCanvas
1 libhwui.so 0x77963dd258 + 513621742168
2 libhwui.so 0x77965cf900 SkCanvas::onDrawDrawable
3 libhwui.so 0x779644ebf0 + 513622207472
4 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
5 libhwui.so 0x779644ebf0 + 513622207472
6 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
7 libhwui.so 0x779644ebf0 + 513622207472
8 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
9 libhwui.so 0x779644ebf0 + 513622207472
10 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
11 libhwui.so 0x779644ebf0 + 513622207472
12 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
13 libhwui.so 0x779644ebf0 + 513622207472
14 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
15 libhwui.so 0x779644ebf0 + 513622207472
16 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
17 libhwui.so 0x779644ebf0 + 513622207472
18 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
19 libhwui.so 0x779644ebf0 + 513622207472
20 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
21 libhwui.so 0x779644ebf0 + 513622207472
22 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
23 libhwui.so 0x779644ebf0 + 513622207472
24 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
25 libhwui.so 0x779644ebf0 + 513622207472
26 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
27 libhwui.so 0x779644ebf0 + 513622207472
28 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
29 libhwui.so 0x779644ebf0 + 513622207472
30 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
31 libhwui.so 0x779644ebf0 + 513622207472
32 libhwui.so 0x77965cf89c SkCanvas::onDrawDrawable
33 libhwui.so 0x7796454bd4 + 513622232020
34 libhwui.so 0x77964545e8 + 513622230504
35 libhwui.so 0x779647aaec + 513622387436
36 libhwui.so 0x7796477ed0 + 513622376144
37 libhwui.so 0x7796477b3c + 513622375228
38 libhwui.so 0x77964d42e4 + 513622754020
39 libhwui.so 0x77964d3450 + 513622750288
40 libhwui.so 0x77964dea24 + 513622796836
41 libhwui.so 0x77964de70c + 513622796044
42 libutils.so 0x77969dc628 android::Thread::_threadLoop
43 libc.so 0x77944c1f24 + 513589124900
44 libc.so 0x77944600cc + 513588723916
45 0x0
Your Environment
ps: After I force using version worked and no crash! version bellow
The text was updated successfully, but these errors were encountered: