FlutterJNI.nativeSurfaceDestroyed
&
SIGSEGV
我在我的flutter应用中面临崩溃,日志指出了
libflutter.so
和
FlutterJNI.nativeSurfaceDestroyed
🔹崩溃日志1。
SIGSEGV
&libflutter.so
FlutterJNI.nativeSurfaceDestroyed
2。 Input dispatching timed out (No focused window)
#03 pc 0x000000000046e7ac /data/app/~~fKb_7A3RSZsyRZdpityG3w==/com.app.testApp-fYVYtg6ltGYh2XGl35QxzA==/split_config.arm64_v8a.apk!libflutter.so
#04 pc 0x0000000000482464 /data/app/~~fKb_7A3RSZsyRZdpityG3w==/com.app.testApp-fYVYtg6ltGYh2XGl35QxzA==/split_config.arm64_v8a.apk!libflutter.so
#05 pc 0x00000000007c814c /data/app/~~fKb_7A3RSZsyRZdpityG3w==/com.app.testApp-fYVYtg6ltGYh2XGl35QxzA==/split_config.arm64_v8a.apk!libflutter.so
#06 pc 0x0000000000466be8 /data/app/~~fKb_7A3RSZsyRZdpityG3w==/com.app.testApp-fYVYtg6ltGYh2XGl35QxzA==/split_config.arm64_v8a.apk!libflutter.so
#07 pc 0x0000000000469300 /data/app/~~fKb_7A3RSZsyRZdpityG3w==/com.app.testApp-fYVYtg6ltGYh2XGl35QxzA==/split_config.arm64_v8a.apk!libflutter.so
at io.flutter.embedding.engine.FlutterJNI.nativeSurfaceDestroyed (Native method)
at io.flutter.embedding.engine.FlutterJNI.onSurfaceDestroyed (FlutterJNI.java:667)
at io.flutter.embedding.engine.renderer.FlutterRenderer.stopRenderingToSurface (FlutterRenderer.java:1125)
at io.flutter.embedding.android.FlutterSurfaceView.disconnectSurfaceFromRenderer (FlutterSurfaceView.java:303)
at io.flutter.embedding.android.FlutterSurfaceView.access$400 (FlutterSurfaceView.java:36)
at io.flutter.embedding.android.FlutterSurfaceView$1.surfaceDestroyed (FlutterSurfaceView.java:78)
at android.view.SurfaceView.notifySurfaceDestroyed (SurfaceView.java:1943)
at android.view.SurfaceView.updateSurface (SurfaceView.java:1191)
at android.view.SurfaceView.onWindowVisibilityChanged (SurfaceView.java:343)
at android.view.View.dispatchWindowVisibilityChanged (View.java:14927)
at android.view.ViewGroup.dispatchWindowVisibilityChanged (ViewGroup.java:1625)
at android.view.ViewGroup.dispatchWindowVisibilityChanged (ViewGroup.java:1625)
at android.view.ViewGroup.dispatchWindowVisibilityChanged (ViewGroup.java:1625)
at android.view.ViewRootImpl.performTraversals (ViewRootImpl.java:2844)
SIGSEGV (Segmentation Fault) in libflutter.so
Build.gradle.ktspc 0x00000000007bf548 /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#11 pc 0x00000000007beee8 /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#12 pc 0x00000000007c02a4 /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#13 pc 0x00000000007bfdac /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#14 pc 0x00000000007cc35c /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#15 pc 0x00000000004811ac /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#16 pc 0x0000000000484ce0 /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#17 pc 0x0000000000018024 /system/lib64/libutils.so (android::Looper::pollInner(int)+1064)
#18 pc 0x0000000000017b98 /system/lib64/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+116)
#19 pc 0x0000000000018598 /system/lib64/libandroid.so (ALooper_pollOnce+104)
#20 pc 0x0000000000484dec /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#21 pc 0x0000000000482ef0 /data/app/~~app.testApprNfba4VBBO2u9sIA==/com.radha.radhe_krishna-rOmGvGDsSf2vWoA-E6LYGg==/split_config.arm64_v8a.apk!libflutter.so (BuildId: 3535a404fab93d565fa72d50842926306c89a4de)
#22 pc 0x0000000000482d24 /data/app/~~app.testApp
任何帮助将不胜感激!提前致谢。 🚀
我们在我们的crasslytics上发生了一些类似的崩溃,但到目前为止,零是零的。
也是,据我所知,还有一个同样的堆栈。还没有找到其他解决方案,这些解决方案仅将颤动更新为最新的补丁版本,该版本截至今天。说,这里只有我的建议才是更新颤音。要么最新的补丁发行版(
PS D:\flutter projects\app> flutter doctor -v
[√] Flutter (Channel stable, 3.27.0, on Microsoft Windows [Version 10.0.19045.5487], locale en-IN)
• Flutter version 3.27.0 on channel stable at D:\Flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 8495dee1fd (9 weeks ago), 2024-12-10 14:23:39 -0800
• Engine revision 83bacfc525
• Dart version 3.6.0
• DevTools version 2.40.2
)或最新的
import java.util.Properties
import java.io.FileInputStream
plugins {
id("com.android.application")
id("kotlin-android")
id("dev.flutter.flutter-gradle-plugin")
}
val keystorePropertiesFile = rootProject.file("key.properties")
val keystoreProperties = Properties()
if (keystorePropertiesFile.exists()) {
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
}
android {
namespace = "com.app.testApp"
compileSdk = 34
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
defaultConfig {
applicationId = "com.app.testApp"
minSdk = 23
targetSdk = 34
versionCode = flutter.versionCode
versionName = flutter.versionName
multiDexEnabled = true
ndk {
abiFilters.addAll(listOf("armeabi-v7a", "arm64-v8a", "x86_64"))
}
}
configurations.all {
resolutionStrategy {
// Force specific versions to avoid conflicts
force("com.google.android.play:core-common:2.0.3")
force("com.google.android.play:app-update:2.1.0")
force("com.google.android.play:asset-delivery:2.1.0")
force("com.google.android.play:review:2.0.1")
force("com.google.android.play:review-ktx:2.0.1")
}
}
signingConfigs {
create("release") {
keyAlias = keystoreProperties.getProperty("keyAlias")
keyPassword = keystoreProperties.getProperty("keyPassword")
storeFile = keystoreProperties.getProperty("storeFile")?.let { file(it) }
storePassword = keystoreProperties.getProperty("storePassword")
}
}
buildTypes {
getByName("release") {
signingConfig = signingConfigs.getByName("release")
// isMinifyEnabled = true
// isShrinkResources = true
ndk {
abiFilters.addAll(listOf("armeabi-v7a", "arm64-v8a", "x86_64"))
}
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
getByName("debug") {
isDebuggable = true
}
}
lint {
checkReleaseBuilds = false
}
}
dependencies {
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.8.22")
implementation("androidx.multidex:multidex:2.0.1")
// Instead of using core:1.10.3, use the modular dependencies
implementation("com.google.android.play:core-common:2.0.3")
implementation("com.google.android.play:app-update:2.1.0") {
exclude(group = "com.google.android.play", module = "core")
}
implementation("com.google.android.play:asset-delivery:2.1.0") {
exclude(group = "com.google.android.play", module = "core")
}
implementation("com.google.android.play:review:2.0.1") {
exclude(group = "com.google.android.play", module = "core")
}
implementation("com.google.android.play:review-ktx:2.0.1") {
exclude(group = "com.google.android.play", module = "core-ktx")
}
}
flutter {
source = "../.."
}