Qihoo360 / RePlugin

RePlugin - A flexible, stable, easy-to-use Android Plug-in Framework
Apache License 2.0
7.27k stars 1.53k forks source link

Cannot cast object 'property(interface org.gradle.api.file.Directory, fixed(class org.gradle.api.internal.file.DefaultFilePropertyFactory$FixedDirectory, /Users/zhaozy/Working/RePlugin-dev/replugin-sample/host/app/build/intermediates/merged_assets/debug/out))' with class 'org.gradle.api.internal.file.DefaultFilePropertyFactory$DefaultDirectoryVar' to class 'java.io.File' #853

Open canwen2003 opened 5 years ago

canwen2003 commented 5 years ago

问题详细描述 Detailed description of the problem

运行报错: Cannot cast object 'property(interface org.gradle.api.file.Directory, fixed(class org.gradle.api.internal.file.DefaultFilePropertyFactory$FixedDirectory, RePlugin-dev/replugin-sample/host/app/build/intermediates/merged_assets/debug/out))' with class 'org.gradle.api.internal.file.DefaultFilePropertyFactory$DefaultDirectoryVar' to class 'java.io.File'

//tools classpath 'com.android.tools.build:gradle:3.4.2'

复现问题步骤 Steps to reproduce the problem

编译sample/host后直接运行报错: //tools 设置 classpath 'com.android.tools.build:gradle:3.4.2'

如何设置成 classpath 'com.android.tools.build:gradle:3.1.1' ,就没有问题了

其它重要信息 Other important information

replugin-host-lib/gradle 2.3.2: rePlugin-plugin-lib/gradle 2.3.2:

Android API Version: Android 手机型号&ROM(Phone model & ROM):

Logcat上下文 Logcat context

AbertLi commented 5 years ago

就是 replugin-host-lib / gradle 2.3.2: rePlugin-plugin-lib / gradle 2.3.2: 使用有问题引起的。

hanlyjiang commented 4 years ago

看起来v2.3.3版本修复了 -> https://github.com/Qihoo360/RePlugin/releases/tag/v2.3.3