Repository navigation
Closed
flutter-team-archive/engine
#55708Labels
P1High-priority issues at the top of the work listHigh-priority issues at the top of the work listc: crashStack traces logged to the consoleStack traces logged to the consolec: regressionIt was better in the past than it is nowIt was better in the past than it is nowe: OS-version specificAffects only some versions of the relevant operating systemAffects only some versions of the relevant operating systeme: impellerImpeller rendering backend issues and features requestsImpeller rendering backend issues and features requestsengineflutter/engine related. See also e: labels.flutter/engine related. See also e: labels.needs repro infoAutomated crash report whose cause isn't yet knownAutomated crash report whose cause isn't yet knownteam-engineOwned by Engine teamOwned by Engine teamtriaged-engineTriaged by Engine teamTriaged by Engine team
Description
Steps to reproduce
- Create a new Flutter project by running
flutter create --project-name test -a java <path> - Run the app.
- Click on the FAB multiple times quickly.
Expected results
The app shouldn't crash.
Actual results
The app crashes, and I’ve also tried beta channel, but I get the same result.
Code sample
The one used by flutter create.
Screenshots or Video
Screenshots / Video demonstration
[Upload media here]
Flutter.bug.1.mov
Logs
Logs
Launching lib/main.dart on M2007J17I in profile mode...
Running Gradle task 'assembleProfile'...
✓ Built build/app/outputs/flutter-apk/app-profile.apk (13.5MB)
I/flutter ( 8452): [IMPORTANT:flutter/shell/platform/android/android_context_vk_impeller.cc(68)] Using the Impeller rendering backend (Vulkan).
Debug service listening on ws://127.0.0.1:54252/NPWC8Xd0lQs=/ws
F/ ( 8452): ASurfaceControl not found
F/libc ( 8452): Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 8473 (Binder:8452_2), pid 8452 (xample.test)
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'Xiaomi/gauguininpro/gauguininpro:10/QKQ1.200628.002/V12.0.6.0.QJSINXM:user/release-keys'
Revision: '0'
ABI: 'arm64'
Timestamp: 2024-09-28 13:19:00+0530
pid: 8452, tid: 8473, name: Binder:8452_2 >>> com.example.test <<<
uid: 10292
signal 6 (SIGABRT), code -1 (SI_QUEUE), fault addr --------
Abort message: 'ASurfaceControl not found'
x0 0000000000000000 x1 0000000000002119 x2 0000000000000006 x3 000000704e629fe0
x4 0000008000000000 x5 0000008000000000 x6 0000008000000000 x7 0000000080000000
x8 00000000000000f0 x9 812e8237834b2e47 x10 0000000000000001 x11 0000000000000000
x12 fffffff0fffffbdf x13 0000000000000020 x14 ffffffffffffffff x15 00004a7e6f3f85f3
x16 00000071362048c0 x17 00000071361e0a50 x18 000000704e284000 x19 0000000000002104
x20 0000000000002119 x21 00000000ffffffff x22 0000007042190cb8 x23 000000704e62a7e0
x24 00000070a2179040 x25 0000000000000000 x26 000000702972d380 x27 0000000000000000
x28 0000000000000000 x29 000000704e62a080
sp 000000704e629fc0 lr 00000071361920c4 pc 00000071361920f0
backtrace:
#00 pc 00000000000830f0 /apex/com.android.runtime/lib64/bionic/libc.so (abort+160) (BuildId: efe7913e9debfe2df8d421d91957bb90)
#01 pc 0000000000008a14 /system/lib64/liblog.so (__android_log_assert+328) (BuildId: 1bac0e45e976db77074a6f84e94123a7)
#02 pc 000000000001684c /system/lib64/libandroid.so (ASurfaceTransactionStats_getPreviousReleaseFenceFd+276) (BuildId: 73389f93b4bf4a9c56c711a8980e8f25)
#03 pc 0000000000b93128 /data/app/com.example.test-vS-Ec_9Mq0xv6iClXL9cKA==/lib/arm64/libflutter.so!libflutter.so (offset 0x823000) (BuildId: e5b34fb9d94053c1ffa3738426367d59f0ce61e2)
#04 pc 0000000000000002 <unknown>
Lost connection to device.Flutter Doctor output
Doctor output
[✓] Flutter (Channel master, 3.26.0-1.0.pre.15, on macOS 14.4.1 23E224 darwin-arm64, locale en-US)
[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
[!] Xcode - develop for iOS and macOS (Xcode 15.3)
! CocoaPods 1.12.1 out of date (1.13.0 is recommended).
CocoaPods is a package manager for iOS or macOS platform code.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/to/platform-plugins
To update CocoaPods, see https://guides.cocoapods.org/using/getting-started.html#updating-cocoapods
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.3)
[✓] Android Studio (version 2024.1)
[✓] IntelliJ IDEA Community Edition (version 2022.3)
[✓] VS Code (version 1.91.1)
[✓] Connected device (4 available)
[✓] Network resources
! Doctor found issues in 1 category.Metadata
Metadata
Assignees
Labels
P1High-priority issues at the top of the work listHigh-priority issues at the top of the work listc: crashStack traces logged to the consoleStack traces logged to the consolec: regressionIt was better in the past than it is nowIt was better in the past than it is nowe: OS-version specificAffects only some versions of the relevant operating systemAffects only some versions of the relevant operating systeme: impellerImpeller rendering backend issues and features requestsImpeller rendering backend issues and features requestsengineflutter/engine related. See also e: labels.flutter/engine related. See also e: labels.needs repro infoAutomated crash report whose cause isn't yet knownAutomated crash report whose cause isn't yet knownteam-engineOwned by Engine teamOwned by Engine teamtriaged-engineTriaged by Engine teamTriaged by Engine team
Activity
jonahwilliams commentedon Sep 28, 2024
What kind of device is this running on? ASurfaceControl was added in API 29 (Android 10).
I guess at this point nothing in Android will surprise me, but the version checks we ready have should really be sufficient
iLoveDocs commentedon Sep 28, 2024
@jonahwilliams
The issue is happening on all devices running Android 10. I tested this app on Xiaomi Mi 10i.
Sorry I didn't quite get that. Is there already a fix that I am missing?
I am seeing this crash in my production app, the app goes blank on those devices and Google Play Console reports the same error:




jonahwilliams commentedon Sep 28, 2024
What I mean is that according to the Android documentation ( https://developer.android.com/ndk/reference/group/native-activity#asurfacetransactionstats_getpreviousreleasefencefd ) an Android 10 device must support these functions. We'll have to follow up with Android folks to see if we either misinterpreted the documentation or if there are known devices that shipped incomplete 29 support.
EDIT: fixed method.
huycozy commentedon Sep 30, 2024
Hi @iLoveDocs, I don't have an Android 10 physical device so I can't check this issue on my end in profile mode (I don't see it on Android 10 emulator in debug mode).
Here are some questions, can you help to check these?
iLoveDocs commentedon Oct 1, 2024
@huycozy
iLoveDocs commentedon Oct 1, 2024
On Flutter stable 3.24.3, even when I run the app using
flutter run --enable-impeller --profile, the app doesn’t crash. So, I’m not sure what changes in the later releases are causing the app to crash on Android 10 devices.jonahwilliams commentedon Oct 1, 2024
Like I mentioned before, the cause is the usage of these new APIs that seem to be malfunctioning on your devices. The current state is like I mentioned already, I need to follow up with Android folks to determine if there were devices shipped with incomplete 29 suppprt
huycozy commentedon Oct 2, 2024
Keeping this issue open for further information. Per Google Play Console reports above, this seems to occur on other devices as well, marking this as an OS-specific issue on Android 10, API 29.
4 remaining items
[-]App crashes on Android 10 with the abort message: 'ASurfaceControl not found'.[/-][+][Impeller] ASurfaceTransactionStats_getPreviousReleaseFenceFd missing from certain API 29 devices.[/+]jonahwilliams commentedon Oct 4, 2024
From more investigation, the API is there but we're getting a null surface transaction stats.
[-][Impeller] ASurfaceTransactionStats_getPreviousReleaseFenceFd missing from certain API 29 devices.[/-][+][Impeller] ASurfaceTransactionStats_getPreviousReleaseFenceFd crashing mysteriously on some API 29 devices.[/+]jonahwilliams commentedon Oct 7, 2024
@iLoveDocs before I completely disable SurfaceControl on all of these devices permanently, can you check out master channel and verify that the crashes are still occuring?
[Impeller] disable surface control on API 29. (#55708)
iLoveDocs commentedon Oct 8, 2024
@jonahwilliams I'm sorry, but I’m out of town and won’t be able to check it at the moment. But thanks for fixing the issue quickly.
github-actions commentedon Oct 22, 2024
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.[Impeller] disable surface control on API 29. (flutter-team-archive/e…
Gate SurfaceControl context setting on API 34+ (flutter#196394)