Logback 0.9.28 will *not* work with SLF4J 1.5.8. It requires SLF4J 1.6+.

Just FYI.

Cheers,
Joern.

On 13.06.2011, at 20:22, Magnus Rundberget wrote:

> Was about to answer, but you beat me to it Eric :-)
> 
> 
> Well this is a typical case of transitive dependencies. Your logback 
> dependency also has a compile dependency to slf4j-api (v 1.6.1)
> Gradle default dependency resolution for duplicates is to use the one with 
> the newest version. (as opposed to maven which would use ?? something rather 
> unknown to most of us).
> 
> 
> cheers
> Magnus
> 
> Date: Mon, 13 Jun 2011 11:17:11 -0700
> From: [email protected]
> To: [email protected]
> Subject: Re: [gradle-user] Why is API version changing? How to control?
> 
> Looks like a transitive dependency issue:
> http://mvnrepository.com/artifact/ch.qos.logback/logback-classic/0.9.28
> 
> You can exclude transitive dependencies as described here:
> http://gradle.org/current/docs/userguide/dependency_management.html#sub:exclude_transitive_dependencies
> [code]
>    compile(group: 'ch.qos.logback', name: 'logback-classic', version: 
> '0.9.28') {
>       exclude group: 'org.slf4j'
>    }
> [/code]
> 
> Then you might need to include the transitive dependencies for your specific 
> version:
> [code]
> slf4jVersion = '1.5.8'
> 
> dependencies {
>    compile(group: 'ch.qos.logback', name: 'logback-classic', version: 
> '0.9.28') {
>       exclude group: 'org.slf4j'
>    }
>    compile "org.slf4j:integration:$slf4jVersion",
>            "org.slf4j:log4j-over-slf4j:$slf4jVersion",
>            "org.slf4j:slf4j-api:$slf4jVersion",
>            "org.slf4j:slf4j-ext:$slf4jVersion"  
> }
> [/code]
> 
> 
> On Mon, Jun 13, 2011 at 11:04 AM, strayph <[email protected]> wrote:
> I understand this is an API/implementation issue, but I don't understand why
> it's happening, or how to control it.
> 
> If I create the following Gradle script:
> apply plugin: 'java'
> apply plugin: 'maven'
> 
> repositories {
>    mavenCentral()
> }
> 
> dependencies {
>    compile group: 'ch.qos.logback', name: 'logback-classic', version:
> '0.9.28'
>    compile group: 'org.slf4j', name: 'slf4j-api', version: '1.5.8'
> }
> 
> Then run 'gradle dependencies', my 'slf4j-api' version is now '1.6.1'.
> How does this happen?
> And how can I keep it at '1.5.8'?
> 
> Strayph
> 
> --
> View this message in context: 
> http://gradle.1045684.n5.nabble.com/Why-is-API-version-changing-How-to-control-tp4485231p4485231.html
> Sent from the gradle-user mailing list archive at Nabble.com.
> 
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
> 
>    http://xircles.codehaus.org/manage_email
> 
> 
> 
> 
> 
> -- 
> Learn from the past. Live in the present. Plan for the future.
> Blog: http://eric-berry.blogspot.com
> jEdit <http://www.jedit.org> - Programmer's Text Editor
> Bazaar <http://bazaar.canonical.com> - Version Control for Humans


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to