Search code examples
androidandroid-studiogradleroboguice

Failed to initialize an instance of org.apache.velocity.runtime.log.CommonsLogLogChute with the current runtime configuration


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.

Error appearing when changing configuration on gradle from target 22 to target 23. No idea what's that, any ideas?

relevant build.gradle part

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

Thanks in advance to anyone that will try to help

EDIT: Dependencies

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

UPDATE: The problem is connected to the roboguice library


Solution

  • Add the below mentioned value in your app level gradle.

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