Meituan-Dianping / Robust

Robust is an Android HotFix solution with high compatibility and high stability. Robust can fix bugs immediately without a reboot.
Apache License 2.0
4.42k stars 807 forks source link

补丁打包一直失败!已经参考了教程以及网友的很多流程,不知道哪里出问题了。未开启混淆. #363

Closed FanChael closed 4 years ago

FanChael commented 4 years ago

================autoPatch start================ autopatch read all class file cost 0.03 second check all class cost 0.15 second, class count: 1416 addPatchMethodAndModifiedClass pint methodmap key is com.skl.hotfixtest.FileUtil.copyFilesFromAssets(android.content.Context,java.lang.String,java.lang.String,java.lang.String) value is 1 key is com.skl.hotfixtest.MainActivity.onCreate(android.os.Bundle) value is 2 key is com.skl.hotfixtest.MainActivity.getFuction(android.view.View) value is 3 key is com.skl.hotfixtest.MainActivity$1.fetchPatchList(android.content.Context) value is 4 key is com.skl.hotfixtest.MainActivity$2.onPatchListFetched(boolean,boolean,java.util.List) value is 5 key is com.skl.hotfixtest.MainActivity$2.onPatchFetched(boolean,boolean,com.meituan.robust.Patch) value is 6 key is com.skl.hotfixtest.MainActivity$2.onPatchApplied(boolean,com.meituan.robust.Patch) value is 7 key is com.skl.hotfixtest.MainActivity$2.logNotify(java.lang.String,java.lang.String) value is 8 key is com.skl.hotfixtest.MainActivity$2.exceptionNotify(java.lang.Throwable,java.lang.String) value is 9 key is com.skl.hotfixtest.SystemUtils.getCacheDirectory(android.content.Context,java.lang.String) value is 10 key is com.skl.hotfixtest.SystemUtils.getExternalCacheDirectory(android.content.Context,java.lang.String) value is 11 key is com.skl.hotfixtest.SystemUtils.getInternalCacheDirectory(android.content.Context,java.lang.String) value is 12

FAILURE: Build failed with an exception.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0. Use '--warning-mode all' to show the individual deprecation warnings. See https://docs.gradle.org/5.1.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 1s 20 actionable tasks: 2 executed, 18 up-to-date 14:08:50: Task execution finished 'assembleRelease'.

FanChael commented 4 years ago

AS 3.4.1

classpath 'com.android.tools.build:gradle:3.4.1' classpath 'com.meituan.robust:gradle-plugin:0.4.90' classpath 'com.meituan.robust:auto-patch-plugin:0.4.90'

FanChael commented 4 years ago

package com.skl.hotfixtest;

import com.meituan.robust.patch.annotaion.Add; import com.meituan.robust.patch.annotaion.Modify;

public class NeedFixFunction { /**