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

在下载完成,准备安装时崩溃 #161

Closed
Joehaivo opened this issue Feb 29, 2024 · 5 comments
Closed

在下载完成,准备安装时崩溃 #161

Joehaivo opened this issue Feb 29, 2024 · 5 comments
Labels
waiting for user response Need more log information

Comments

@Joehaivo
Copy link

AppUpdate parameter
Screenshot DownloadManager configuration

Steps to reproduce

Log or something else
17:26:20.844 ViewRoo...tivity] com.android.tools D updatePointerIcon called with position out of bounds
17:26:20.878 chatty com.android.tools I uid=10053(com.android.tools) identical 2 lines
17:26:20.895 ViewRoo...tivity] com.android.tools D updatePointerIcon called with position out of bounds
17:26:21.689 AppUpda...ctivity com.android.tools D checkPermission: has permission
17:26:21.695 CrashReport com.android.tools D >>> com.azhon.appupdate.view.UpdateDialogActivity onPaused <<<
17:26:21.723 AppUpda...Service com.android.tools D Notification switch status: opened
17:26:21.723 AppUpda...Service com.android.tools D Apk don't exist will start download.
17:26:21.725 CrashReport com.android.tools D >>> com.android.tools.home.MainActivity onResumed <<<
17:26:21.726 PodUtils com.android.tools I systemProperties 2109119DG
17:26:21.726 PodUtils com.android.tools I systemProperties Xiaomi
17:26:21.726 PodUtils com.android.tools I systemProperties lisa_global
17:26:21.875 AppUpda...Manager com.android.tools D checkServerTrusted
17:26:21.885 CrashReport com.android.tools D >>> com.azhon.appupdate.view.UpdateDialogActivity onStop <<<
17:26:21.885 CrashReport com.android.tools D setActivityForeState, hash:4171550 isFore:false
17:26:21.885 eup com.android.tools I jni_setNativeInfo: key is 14
17:26:21.885 eup com.android.tools I Set native info: isAppForeground(true)
17:26:21.888 CrashReport com.android.tools D >>> com.azhon.appupdate.view.UpdateDialogActivity onDestroyed <<<
17:26:21.975 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 290124
17:26:22.019 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 580940
17:26:22.052 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 869708
17:26:22.079 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 1160524
17:26:22.109 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 1449292
17:26:22.143 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 1740108
17:26:22.176 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 2028876
17:26:22.209 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 2317644
17:26:22.229 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 2608460
17:26:22.261 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 2897228
17:26:22.292 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 3188044
17:26:22.319 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 3476672
17:26:22.338 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 3767488
17:26:22.371 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 4056256
17:26:22.399 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 4347072
17:26:22.436 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 4635840
17:26:22.455 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 4926656
17:26:22.494 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 5215424
17:26:22.528 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 5504192
17:26:22.564 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 5795008
17:26:22.566 Notific...Service pid-31036 E Package enqueue rate is 6.025254. Shedding 0|com.android.tools|1011|null|10053. package=com.android.tools
17:26:22.591 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 6083776
17:26:22.617 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 6374592
17:26:22.639 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 6663360
17:26:22.667 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 6954176
17:26:22.684 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 7242944
17:26:22.703 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 7533760
17:26:22.720 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 7822528
17:26:22.738 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 8113344
17:26:22.758 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 8402112
17:26:22.775 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 8690880
17:26:22.785 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 8981696
17:26:22.795 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 9270464
17:26:22.807 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 9561280
17:26:22.822 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 9850048
17:26:22.833 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 10140864
17:26:22.854 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 10429632
17:26:22.873 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 10720448
17:26:22.890 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 11009216
17:26:22.907 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 11300032
17:26:22.919 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 11588800
17:26:22.934 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 11877568
17:26:22.970 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 12168384
17:26:23.022 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 12457152
17:26:23.075 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 12747968
17:26:23.123 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 13036736
17:26:23.176 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 13327552
17:26:23.227 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 13616320
17:26:23.276 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 13907136
17:26:23.325 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 14195904
17:26:23.379 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 14486720
17:26:23.428 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 14775488
17:26:23.479 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 15064256
17:26:23.531 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 15355072
17:26:23.578 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 15643840
17:26:23.631 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 15934656
17:26:23.680 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 16223424
17:26:23.732 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 16514240
17:26:23.783 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 16803008
17:26:23.837 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 17093824
17:26:23.881 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 17382592
17:26:23.935 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 17671360
17:26:23.984 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 17962176
17:26:24.035 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 18250944
17:26:24.086 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 18541760
17:26:24.138 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 18830528
17:26:24.187 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 19121344
17:26:24.238 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 19410112
17:26:24.288 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 19700928
17:26:24.341 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 19989696
17:26:24.391 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 20280512
17:26:24.441 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 20569280
17:26:24.493 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 20858048
17:26:24.539 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 21148864
17:26:24.592 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 21437632
17:26:24.642 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 21728448
17:26:24.693 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 22017216
17:26:24.745 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 22308032
17:26:24.795 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 22596800
17:26:24.845 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 22887616
17:26:24.897 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 23176384
17:26:24.949 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 23467200
17:26:24.995 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 23755968
17:26:25.048 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 24044736
17:26:25.101 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 24335552
17:26:25.149 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 24624320
17:26:25.200 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 24915136
17:26:25.249 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 25203904
17:26:25.303 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 25494720
17:26:25.354 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 25783488
17:26:25.404 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 26074304
17:26:25.455 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 26363072
17:26:25.502 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 26653888
17:26:25.553 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 26942656
17:26:25.604 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 27231424
17:26:25.656 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 27522240
17:26:25.705 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 27811008
17:26:25.759 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 28101824
17:26:25.807 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 28390592
17:26:25.858 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 28681408
17:26:25.909 AppUpda...Service com.android.tools I downloading max: 28969408 --- progress: 28969408
17:26:25.910 AppUpda...Service com.android.tools D apk downloaded to /storage/emulated/0/Android/data/com.android.tools/cache/Tools.apk
17:26:25.920 CrashReport com.android.tools E Java Crash Happen cause by main(2)
17:26:25.954 CrashReport com.android.tools I user log size:0
17:26:25.956 CrashReport com.android.tools I ROM ID: Xiaomi/lisa_global/lisa:11/RKQ1.210503.001/V12.5.5.0.RKOTWXM:user/release-keys/
17:26:25.956 CrashReport com.android.tools D isAppForeground:true
17:26:25.956 CrashReport com.android.tools E stack frame :15, has cause false
17:26:25.958 CrashReport com.android.tools E #++++++++++Record By Bugly++++++++++#
17:26:25.958 CrashReport com.android.tools E # You can use Bugly(http:\bugly.qq.com) to get more Crash Detail!
17:26:25.958 CrashReport com.android.tools E # PKG NAME: com.android.tools
17:26:25.958 CrashReport com.android.tools E # APP VER: 4.0.0.1
17:26:25.958 CrashReport com.android.tools E # SDK VER: 4.1.9.3-4.1.9.3
17:26:25.959 CrashReport com.android.tools E # LAUNCH TIME: 2024-02-29 17:26:17
17:26:25.959 CrashReport com.android.tools E # CRASH TYPE: JAVA_CRASH
17:26:25.959 CrashReport com.android.tools E # CRASH TIME: 2024-02-29 17:26:25
17:26:25.959 CrashReport com.android.tools E # CRASH PROCESS: com.android.tools
17:26:25.959 CrashReport com.android.tools D isAppForeground:true
17:26:25.959 CrashReport com.android.tools E # CRASH FOREGROUND: true
17:26:25.959 CrashReport com.android.tools E # CRASH THREAD: main
17:26:25.959 CrashReport com.android.tools E # REPORT ID: e6807cb4-eae1-422f-8a8c-1b2e315627c3
17:26:25.959 CrashReport com.android.tools D not allow collect device model
17:26:25.960 CrashReport com.android.tools E # CRASH DEVICE: fail UNROOT
17:26:25.960 CrashReport com.android.tools E # RUNTIME AVAIL RAM:7950970880 ROM:30260068352 SD:30260068352
17:26:25.960 CrashReport com.android.tools E # RUNTIME TOTAL RAM:12234551296 ROM:33552089088 SD:33552089088
17:26:25.960 CrashReport com.android.tools E # CRASH STACK:
17:26:25.960 CrashReport com.android.tools E java.lang.NullPointerException
at com.azhon.appupdate.service.DownloadService.done(DownloadService.kt:153)
at com.azhon.appupdate.service.DownloadService$download$1$1.emit(DownloadService.kt:102)
at com.azhon.appupdate.service.DownloadService$download$1$1.emit(DownloadService.kt:98)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt.emitAllImpl$FlowKt__ChannelsKt(Channels.kt:62)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt.access$emitAllImpl$FlowKt__ChannelsKt(Channels.kt:1)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt$emitAllImpl$1.invokeSuspend(Unknown Source:14)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7438)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:935)
Suppressed: kotlinx.coroutines.DiagnosticCoroutineContextException: [CoroutineName(app-update-coroutine), StandaloneCoroutine{Cancelling}@eeaa377, Dispatchers.Main]
17:26:25.960 CrashReport com.android.tools E #++++++++++++++++++++++++++++++++++++++++++#
17:26:25.982 CrashReport com.android.tools D [Database] insert t_cr success.
17:26:25.982 CrashReport com.android.tools D insert t_cr success!
17:26:25.983 CrashReport com.android.tools D maxMemory : 256.000000
17:26:25.983 CrashReport com.android.tools D totalMemory : 27.300941
17:26:25.983 CrashReport com.android.tools D freeMemory : 228.699066
17:26:26.030 CrashReport com.android.tools D [Database] deleted t_lr data 1
17:26:26.043 CrashReport com.android.tools D [Database] insert t_lr success.
17:26:26.044 CrashReportInfo com.android.tools I [crash] a crash occur, handling...
17:26:26.065 CrashReport com.android.tools D [Database] insert t_cr success.
17:26:26.065 CrashReport com.android.tools D insert t_cr success!
17:26:26.065 CrashReport com.android.tools D sla report single event
17:26:26.065 CrashReport com.android.tools D sla batch report event size:1
17:26:26.066 CrashReport com.android.tools D sla convert eventId:e6807cb4-eae1-422f-8a8c-1b2e315627c3 eventType:BuglyJavaCrash, eventTime:1709198785921 success:true cost:0 from:realtime uploadMsg:
17:26:26.066 CrashReport com.android.tools D sla save id:e6807cb4-eae1-422f-8a8c-1b2e315627c3-BuglyJavaCrash time:1709198785921 msg:&app_version=4.0.0.1&app_name=&app_bundle_id=com.android.tools&client_type=android&user_id=unknown&sdk_version=4.1.9.3-4.1.9.3&event_code=BuglyJavaCrash&event_result=1&event_time=2024-02-29 17:26:25:921&event_cost=0&device_id=b572aa6222a2c640b9e35e002de6cbb2&debug=0&param_0=realtime&param_1=e6807cb4-eae1-422f-8a8c-1b2e315627c3&param_2=ext&param_4=a3d9d030ed
17:26:26.080 CrashReport com.android.tools D [Database] insert t_sla success.
17:26:26.080 CrashReport com.android.tools D [AsyncTaskHandler] Post a normal task: com.tencent.bugly.proguard.ag$1
17:26:26.081 CrashReportInfo com.android.tools I [crash] save crash success
17:26:26.081 CrashReport com.android.tools I try to upload right now
17:26:26.081 CrashReport com.android.tools D sla batch report list size:1
17:26:26.083 CrashReport com.android.tools D libInfo null
17:26:26.084 CrashReport com.android.tools D attach pageTracingList
17:26:26.085 CrashReport com.android.tools D get cpu type from so:arm64-v8a
17:26:26.086 CrashReport com.android.tools D pss:77600768 vss:5761875968 javaHeap:7882280
17:26:26.088 CrashReport com.android.tools D java.lang.NullPointerException rid:e6807cb4-eae1-422f-8a8c-1b2e315627c3 sess:9c07323a-9c04-4583-a975-25bb3855a9f6 ls:8s isR:false isF:true isM:false isN:false mc:0 ,null ,isUp:false ,vm:30
17:26:26.099 CrashReport com.android.tools D not allow collect device model
17:26:26.100 CrashReport com.android.tools I Detect if the emulator is unavailable
17:26:26.100 CrashReport com.android.tools I Detect if the device hook is unavailable
17:26:26.103 CrashReport com.android.tools D [UploadManager] Add upload task (pid=14034 | tid=14034)
17:26:26.104 CrashReport com.android.tools D [UploadManager] Execute synchronized upload task (pid=14034 | tid=14034)
17:26:26.105 CrashReport com.android.tools D [Util] Zip 35846 bytes data with type Gzip
17:26:26.124 CrashReport com.android.tools D [Database] deleted t_lr data 1
17:26:26.124 AppUpda...Manager com.android.tools D checkServerTrusted
17:26:26.140 CrashReport com.android.tools D [Database] insert t_lr success.
17:26:26.140 CrashReport com.android.tools D [UploadManager] Uploading(ID:1004) time: 2024-02-29 17:26:26
17:26:26.140 CrashReport com.android.tools D [Upload] Send 5701 bytes
17:26:26.141 CrashReport com.android.tools D [Upload] Upload to https://android.bugly.qq.com/rqd/async?aid=0826c418-b93c-4cf0-9d25-8814c2f53bcf with cmd 830 (pid=14034 | tid=14131).
17:26:26.141 CrashReport com.android.tools D request: https://android.bugly.qq.com/rqd/async?aid=0826c418-b93c-4cf0-9d25-8814c2f53bcf, send: 5701 (pid=14034 | tid=14131)
17:26:26.184 CrashReport com.android.tools D sla batch report result, rspCode:200 rspMsg:
17:26:26.184 CrashReport com.android.tools D sla batch delete list size:1
17:26:26.184 CrashReport com.android.tools D sla batch delete where:_id in ('e6807cb4-eae1-422f-8a8c-1b2e315627c3-BuglyJavaCrash')
17:26:26.187 AppUpda...Manager com.android.tools D checkServerTrusted
17:26:26.230 CrashReport com.android.tools D response code 200
17:26:26.231 CrashReport com.android.tools D [Upload] Received 95 bytes
17:26:26.231 CrashReport com.android.tools D [Upload] Bugly version from headers is: bugly/1.0
17:26:26.231 CrashReport com.android.tools D [Upload] Status from server is 0 (pid=14034 | tid=14131).
17:26:26.231 CrashReport com.android.tools D [Util] Unzip 95 bytes data with type Gzip
17:26:26.231 CrashReport com.android.tools W Not in GZIP format
17:26:26.232 CrashReport com.android.tools D [Upload] Response cmd is: 0, length of sBuffer is: 0
17:26:26.232 CrashReport com.android.tools I [Upload] Success: crash
17:26:26.234 CrashReport com.android.tools D [UploadManager] Local network consume: 89 KB
17:26:26.248 CrashReport com.android.tools D [Database] deleted t_lr data 1
17:26:26.261 CrashReport com.android.tools D [Database] insert t_lr success.
17:26:26.262 CrashReport com.android.tools D [UploadManager] Network total consume: 95 KB
17:26:26.262 CrashReport com.android.tools D sla batch report event size:1
17:26:26.262 CrashReport com.android.tools D sla convert eventId:e6807cb4-eae1-422f-8a8c-1b2e315627c3 eventType:BuglyJavaCrashReport, eventTime:1709198785921 success:true cost:162 from:realtime uploadMsg:
17:26:26.262 CrashReport com.android.tools D sla save id:e6807cb4-eae1-422f-8a8c-1b2e315627c3-BuglyJavaCrashReport time:1709198785921 msg:&app_version=4.0.0.1&app_name=&app_bundle_id=com.android.tools&client_type=android&user_id=unknown&sdk_version=4.1.9.3-4.1.9.3&event_code=BuglyJavaCrashReport&event_result=1&event_time=2024-02-29 17:26:25:921&event_cost=162&device_id=b572aa6222a2c640b9e35e002de6cbb2&debug=0&param_0=realtime&param_1=e6807cb4-eae1-422f-8a8c-1b2e315627c3&param_2=ext&param_4=a3d9d030ed&param_3=successfully uploaded
17:26:26.275 CrashReport com.android.tools D [Database] insert t_sla success.
17:26:26.275 CrashReport com.android.tools D sla batch report list size:1
17:26:26.324 CrashReport com.android.tools D sla batch report result, rspCode:200 rspMsg:
17:26:26.324 CrashReport com.android.tools D sla batch delete list size:1
17:26:26.324 CrashReport com.android.tools D sla batch delete where:_id in ('e6807cb4-eae1-422f-8a8c-1b2e315627c3-BuglyJavaCrashReport')
17:26:26.338 CrashReport com.android.tools D up finish update state true
17:26:26.338 CrashReport com.android.tools D pre uid:e6807cb4-eae1-422f-8a8c-1b2e315627c3 uc:0 re:false me:false
17:26:26.338 CrashReport com.android.tools D set uid:e6807cb4-eae1-422f-8a8c-1b2e315627c3 uc:1 re:true me:false
17:26:26.354 CrashReport com.android.tools D [Database] insert t_cr success.
17:26:26.354 CrashReport com.android.tools D insert t_cr success!
17:26:26.354 CrashReport com.android.tools D update state size 1
--------- beginning of crash
17:26:26.355 CrashReport com.android.tools E sys default last handle start!
17:26:26.358 AndroidRuntime com.android.tools E FATAL EXCEPTION: main
Process: com.android.tools, PID: 14034
java.lang.NullPointerException
at com.azhon.appupdate.service.DownloadService.done(DownloadService.kt:153)
at com.azhon.appupdate.service.DownloadService$download$1$1.emit(DownloadService.kt:102)
at com.azhon.appupdate.service.DownloadService$download$1$1.emit(DownloadService.kt:98)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt.emitAllImpl$FlowKt__ChannelsKt(Channels.kt:62)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt.access$emitAllImpl$FlowKt__ChannelsKt(Channels.kt:1)
at kotlinx.coroutines.flow.FlowKt__ChannelsKt$emitAllImpl$1.invokeSuspend(Unknown Source:14)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7438)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:935)
Suppressed: kotlinx.coroutines.DiagnosticCoroutineContextException: [CoroutineName(app-update-coroutine), StandaloneCoroutine{Cancelling}@eeaa377, Dispatchers.Main]

Software version

  • Android Studio:
  • AppUpdate Version:
  • Device Brand:
  • Device Model:
  • Android Version:
@Joehaivo Joehaivo added the bug Something isn't working label Feb 29, 2024
@azhon
Copy link
Owner

azhon commented Mar 1, 2024

不应该呀,是必现吗?

@Joehaivo
Copy link
Author

Joehaivo commented Mar 1, 2024

解决了,Constant.AUTHORITIES!!, apk 这里的问题,此时它为空,我主动赋值
Constant.AUTHORITIES = "${AppUtils.getAppPackageName()}.fileProvider"
就行了

@azhon
Copy link
Owner

azhon commented Mar 1, 2024

这个值会在调用manager.download()的时候赋值呀!
image

@Joehaivo
Copy link
Author

Joehaivo commented Mar 1, 2024

val updateManager = DownloadManager.Builder(activity).run {
apkUrl(updateResp?.apkUrl ?: "")
apkName("Tools.apk")
smallIcon(R.mipmap.ic_launcher)
apkVersionName(updateResp?.versionName ?: "")
// apkVersionCode(updateResp?.versionCode ?: 39999)
apkSize(ConvertUtils.byte2FitMemorySize(updateResp?.apkSize ?: 0, 1))
apkDescription(updateResp?.updateContent ?: "")
apkMD5(updateResp?.apkMd5 ?: "")
forcedUpgrade(updateResp?.forceUpdate ?: false)
enableLog(true)
jumpInstallPage(true)
showNotification(true)
showNewerToast(true)
showBgdToast(true)
build()
}
Constant.AUTHORITIES = "${AppUtils.getAppPackageName()}.fileProvider"
activity.startActivity()
我看到了,当时在下载完时就是空值
这是我的代码,不加这句 Constant.AUTHORITIES = "${AppUtils.getAppPackageName()}.fileProvider" 必崩溃

@azhon
Copy link
Owner

azhon commented Mar 1, 2024

那你可以断点跟踪一下,看第一次为什么没有赋值成功

@azhon azhon added waiting for user response Need more log information and removed bug Something isn't working labels Mar 28, 2024
@azhon azhon closed this as completed May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting for user response Need more log information
Projects
None yet
Development

No branches or pull requests

2 participants