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

插件与zoom meeting SDK不兼容,执行minifyDebugWithR8时报错:Cannot constrain type: INT for value: v10 by constraint: OBJECT #30

Open
yue001 opened this issue May 13, 2023 · 3 comments

Comments

@yue001
Copy link

yue001 commented May 13, 2023

近期产品中集成的 zoom meeting SDK 需要升级,升级到新版 5.14.5,执行minifyDebugWithR8时报错(神策插件版本3.4.1,神策SDK版本6.0.1):
Cannot constrain type: @nullable com.zipow.videobox.login.model.UserAccount {} for value: v14 by constraint: INT

尝试将 zoom meeting SDK 降级到5.14.2仍然不行,升级神策插件到3.5.4、3.5.2,神策SDK版本升到6.6.3、6.5.3,运行报错:
Cannot constrain type: INT for value: v10 by constraint: OBJECT

从编译日志看,跟神策不相关,但屏蔽调神策插件和SDK就一切正常,不清楚是否神策插件动态hook并修改三方类导致的问题;

相关日志见:

Execution failed for task ':sample:minifyDebugWithR8'.
> com.android.tools.r8.CompilationFailedException: Compilation failed to complete, position: Lcom/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment;onResume()V, origin: /Users/dser001/Downloads/zoom-sdk-android-5.14.5.13410/mobilertc-android-studio/sample/build/intermediates/transforms/sensorsAnalyticsAutoTrack/debug/83.jar:com/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment.class
.....
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':sample:minifyDebugWithR8'.
  at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1(ExecuteActionsTaskExecuter.java:188)
  at org.gradle.internal.Try$Failure.ifSuccessfulOrElse(Try.java:282)
  at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:186)
  at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:174)
  at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:109)
  at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46)
  at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:51)
  .............
Caused by: org.gradle.internal.UncheckedException: com.android.tools.r8.CompilationFailedException: Compilation failed to complete, position: Lcom/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment;onResume()V, origin: /Users/dser001/Downloads/zoom-sdk-android-5.14.5.13410/mobilertc-android-studio/sample/build/intermediates/transforms/sensorsAnalyticsAutoTrack/debug/83.jar:com/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment.class
  at org.gradle.internal.UncheckedException.throwAsUncheckedException(UncheckedException.java:68)
  at org.gradle.internal.UncheckedException.throwAsUncheckedException(UncheckedException.java:41)
  at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:107)
........
Caused by: com.android.tools.r8.CompilationFailedException: Compilation failed to complete, position: Lcom/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment;onResume()V, origin: /Users/dser001/Downloads/zoom-sdk-android-5.14.5.13410/mobilertc-android-studio/sample/build/intermediates/transforms/sensorsAnalyticsAutoTrack/debug/83.jar:com/zipow/videobox/fragment/MMCustomizeComposeShortcutsFragment.class
  at Version.fakeStackEntry(Version_3.0.73.java:0)
  at com.android.tools.r8.utils.w.a(SourceFile:68)
  at com.android.tools.r8.utils.w.a(SourceFile:28)
  at com.android.tools.r8.utils.w.a(SourceFile:27)
  at com.android.tools.r8.R8.a(R8.java:29)
  at com.android.tools.r8.R8.run(R8.java:3)
  at com.android.builder.dexing.R8Tool.runR8(r8Tool.kt:301)
  at com.android.build.gradle.internal.tasks.R8Task$Companion.shrink(R8Task.kt:592)
  at com.android.build.gradle.internal.tasks.R8Task.doTaskAction(R8Task.kt:443)
  at com.android.build.gradle.internal.tasks.NonIncrementalTask$taskAction$$inlined$recordTaskAction$1.invoke(BaseTask.kt:63)
  at com.android.build.gradle.internal.tasks.Blocks.recordSpan(Blocks.java:51)
  at com.android.build.gradle.internal.tasks.NonIncrementalTask.taskAction(NonIncrementalTask.kt:94)
  at jdk.internal.reflect.GeneratedMethodAccessor731.invoke(Unknown Source)
  at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:104)
  ... 118 more
Caused by: com.android.tools.r8.internal.b: Cannot constrain type: INT for value: v10 by constraint: OBJECT
  at com.android.tools.r8.internal.UA.a(SourceFile:14)
  at com.android.tools.r8.internal.UA.a(SourceFile:22)
@GvcZhang
Copy link

image
请尝试使用这个方法再验证一下。

@yue001
Copy link
Author

yue001 commented May 15, 2023

image 请尝试使用这个方法再验证一下。

感谢关注,试了下添加 sensorsAnalytics.isHookOnMethodEnter=true 也不行,同样的错误;

@yue001
Copy link
Author

yue001 commented May 15, 2023

在 app build.gradle android 节点下添加 sensorsAnalytics.disableJar=true 可以成功运行了;感谢群里SDK值班的同学🍺

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants