【问题标题】:Failed to initialize an instance of org.apache.velocity.runtime.log.CommonsLogLogChute with the current runtime configuration无法使用当前运行时配置初始化 org.apache.velocity.runtime.log.CommonsLogLogChute 的实例
【发布时间】:2016-01-08 10:52:41
【问题描述】:
Error:Execution failed for task ':app:compileDebugJavaWithJavac'.
> org.apache.velocity.exception.VelocityException: Error initializing log: Failed to initialize an instance of org.apache.velocity.runtime.log.CommonsLogLogChute with the current runtime configuration.

将 gradle 上的配置从目标 22 更改为目标 23 时出现错误。 不知道那是什么,有什么想法吗?

相关的build.gradle部分

{
    compileSdkVersion 23
    buildToolsVersion "23.0.1"
    defaultConfig {
        applicationId "com.my.package.app"
        minSdkVersion 14
        targetSdkVersion 23
        versionCode 4
        versionName "1.0"
        multiDexEnabled true
    }

提前感谢任何愿意提供帮助的人

编辑:依赖项

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    provided 'org.roboguice:roboblender:3.+'
    compile 'org.roboguice:roboguice:3.+'
}

更新: 问题与roboguice库有关

【问题讨论】:

  • 你现在用的是哪个android studio和sdk?

标签: android android-studio gradle roboguice


【解决方案1】:

在您的应用级别 gradle 中添加以下提到的值。

android {
useLibrary 'org.apache.http.legacy'
.......
}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2012-06-20
    • 1970-01-01
    • 2018-11-02
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-09-09
    相关资源
    最近更新 更多