Bug #113477

测试 Test-ST #113421: V4.0功能与专项测试

测试 Test-ST #113422: V4.0专项--AF专项--monkey测试

【AF】【EVT2】【Monkey】Monkey测试8小时,出现CRASH: com.android.settings(14)

Added by CD Test赵飞 over 2 years ago. Updated over 2 years ago.

Status:CLOSEDStart date:2022-11-01
Priority:NormalDue date:2022-11-08
Assignee:CD Test赵飞% Done:

100%

Category:CD-FW
Target version:VX1_MCE_FSE_V3.0_update_20221130
Need_Info:-- Found Version:FlatBuild_HH_VX1_MCE_FSE.M.D.user.01.00.X101.202210290232
Resolution:FIXED Degrated:No
Severity:Normal Verified Version:
Reproducibility:Frequently Fixed Version:2022-11-04
Test Type:Monkey Test Root cause:设定相关Activity被销毁,但是fragment没有,导致获取getActivity或getContext为空。添加Activity销毁时移除fragment的动作,同时优化fragment启动的操作

Description

执行命令:
1. adb shell
2. monkey --ignore-crashes --ignore-timeouts --ignore-security-exceptions --monitor-native-crashes --ignore-native-crashes -s 20 --throttle 200 --pct-touch 30 --pct-motion 15 --pct-nav 15 --pct-majornav 15 --pct-syskeys 5 --pct-appswitch 5 --pct-anyevent 5 --ignore-crashes -v -v -v 180000 2>/sdcard/error.txt 1>/sdcard/info.txt

错误日志:

// CRASH: com.android.settings (pid 7297)
// Short Msg: java.lang.ClassCastException
// Long Msg: java.lang.ClassCastException: com.android.settings.notification.history.NotificationHistoryActivity cannot be cast to android.app.Activity
// Build Label: TC/figure_CN/figure:12/SKQ1.220201.001/1242:user/test-keys
// Build Changelist: 1242
// Build Time: 1666977142000
// java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.android.settings/com.android.settings.notification.history.NotificationHistoryActivity}: java.lang.ClassCastException: com.android.settings.notification.history.NotificationHistoryActivity cannot be cast to android.app.Activity
//     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3546)
//     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3793)
//     at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103)
//     at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
//     at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
//     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2211)
//     at android.os.Handler.dispatchMessage(Handler.java:106)
//     at android.os.Looper.loopOnce(Looper.java:201)
//     at android.os.Looper.loop(Looper.java:288)
//     at android.app.ActivityThread.main(ActivityThread.java:7880)
//     at java.lang.reflect.Method.invoke(Native Method)
//     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
//     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1009)
// Caused by: java.lang.ClassCastException: com.android.settings.notification.history.NotificationHistoryActivity cannot be cast to android.app.Activity
//     at android.app.AppComponentFactory.instantiateActivity(AppComponentFactory.java:95)
//     at androidx.core.app.CoreComponentFactory.instantiateActivity(CoreComponentFactory.java:45)
//     at android.app.Instrumentation.newActivity(Instrumentation.java:1274)
//     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3533)
//     ... 12 more
// 

error.txt Magnifier (106 KB) CD Test赵飞, 2022-11-01 15:13

info.txt Magnifier (3.72 MB) CD Test赵飞, 2022-11-01 15:13

History

#1 Updated by CD FW 曹覃刚 over 2 years ago

  • Status changed from New to RESOLVED
  • % Done changed from 0 to 100
  • Resolution changed from -- to FIXED
  • Degrated changed from -- to No
  • Fixed Version set to 2022-11-04
  • Root cause set to 设定相关Activity被销毁,但是fragment没有,导致获取getActivity或getContext为空。添加Activity销毁时移除fragment的动作,同时优化fragment启动的操作

#2 Updated by CD Test赵飞 over 2 years ago

  • Assignee changed from CD FW 曹覃刚 to CD Test赵飞
  • % Done changed from 100 to 70

11月4号的DB版本未复现此问题
Monkey问题,再跟踪2个版本

#3 Updated by CD Test赵飞 over 2 years ago

11月5号的DB版本未复现此问题
Monkey问题,再跟踪1个版本

#4 Updated by CD Test赵飞 over 2 years ago

  • Status changed from RESOLVED to VERIFIED
  • % Done changed from 70 to 80

11月8号的Release版本未复现此问题
已跟踪3个版本未复现,关闭此问题

#5 Updated by CD Test赵飞 over 2 years ago

  • Status changed from VERIFIED to CLOSED

#6 Updated by CD Test赵飞 over 2 years ago

  • % Done changed from 80 to 100

Also available in: Atom PDF