unfriendly error

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

unfriendly error

Ittay Dror
While trying to fix the abdera gradle file I mistakenly created a
dependency of a project on itself
project(':extensions:html') {
  dependencies.compile project(':client'), project(':core'),
project(':parser'), project(':extensions:html'), HTML_PARSER
}

The error I got is very unfriendly:
Build aborted anormally.  Run with -s option to get stacktrace. Run with
-d option to get all debug info including stacktrace. Run (additionally)
with -f option to get the full (very verbose) stacktrace
Exception: org.gradle.api.CircularReferenceException: Can't establish
dependency :extensions:html:compile ==> :extensions:html:uploadLibs

I think this should not be an exception but a report about the wrong
dependency, maybe listing the dependencies in the circle and where they
came from.

(and tiny correction: anormally -> abnormally)

--
--
Ittay Dror <[hidden email]>

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

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: unfriendly error

hans_d
Administrator
Hi Ittay,

On Jun 24, 2008, at 9:33 AM, Ittay Dror wrote:

> While trying to fix the abdera gradle file I mistakenly created a
> dependency of a project on itself

This is tiresome. I have attached my file. There had been one other  
problem. The protocol project is empty. Therefore Gradle does not  
generate a jar and the dependency resolution fails. Gradle archives  
have a creatIfEmpty property, but it did not work out for some  
reason. Therefore I have added a src/main/resources/dummy.properties.

My performance optimizations are not submitted yet.

> project(':extensions:html') {
>  dependencies.compile project(':client'), project(':core'),
> project(':parser'), project(':extensions:html'), HTML_PARSER
> }
>
> The error I got is very unfriendly:
> Build aborted anormally.  Run with -s option to get stacktrace. Run  
> with
> -d option to get all debug info including stacktrace. Run  
> (additionally)
> with -f option to get the full (very verbose) stacktrace
> Exception: org.gradle.api.CircularReferenceException: Can't establish
> dependency :extensions:html:compile ==> :extensions:html:uploadLibs
>
> I think this should not be an exception but a report about the wrong
> dependency, maybe listing the dependencies in the circle and where  
> they
> came from.
>
> (and tiny correction: anormally -> abnormally)

thanks: http://jira.codehaus.org/browse/GRADLE-123

- Hans

>
> --
> --
> Ittay Dror <[hidden email]>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>


allprojects{
   usePlugin('java')
   sourceCompatibility = 1.5
   targetCompatibility = 1.5
   group = 'org.apache.abdera'
   version = '1.0'
   dependencies {
      addMavenRepo('http://people.apache.org/repo/m2-incubating- 
repository')
      addMavenStyleRepo('my-incubating', 'http://people.apache.org/ 
repo/m2-incubating-repository')
      testCompile "junit:junit:3.8.2"
   }
}

def ACTIVATION = 'org.apache.geronimo.specs:geronimo-
activation_1.0.2_spec:1.1'
def AXIOM = ['org.apache.ws.commons.axiom:axiom-api:1.2.5',  
'org.apache.ws.commons.axiom:axiom-impl:1.2.5']
def COMMONS = [
   codec: 'commons-codec:commons-codec:1.3',
   collections: 'commons-collections:commons-collections:3.2',
   httpclient: 'commons-httpclient:commons-httpclient:3.1-rc1',
   logging: 'commons-logging:commons-logging:1.0.4'
]
def JAXEN = 'jaxen:jaxen:1.1.1'
def JETTY = ['org.mortbay.jetty:jetty:6.1.5',  
'org.mortbay.jetty:jetty-util:6.1.5']
def SERVLET_API = 'javax.servlet:servlet-api:2.4'
def STAX = ['stax:stax-api:1.0.1', 'org.codehaus.woodstox:wstx-asl:
3.2.1']
def PARSER = 'nu.validator.htmlparser:htmlparser:1.0.5'
def XML_SECURITY = 'xml-security:xmlsec:1.3.0'
def XERCES = 'xerces:xercesImpl:2.8.1'


project(':dependencies:i18n') {
   dependencies.compile ACTIVATION
}

project(':core') {
   dependencies.compile project(':dependencies:i18n'), ACTIVATION,  
COMMONS.codec, COMMONS.logging
}

project(':parser') {
   dependencies.compile project(':core'), project
(':dependencies:i18n'), ACTIVATION, AXIOM, STAX, JAXEN, COMMONS.logging
}

project(':protocol') {
   dependencies.compile project(':core')
}

project(':client') {
   dependencies.compile project(':parser'), project(':protocol'),  
project(':core'), project(':dependencies:i18n'), ACTIVATION,  
COMMONS.httpclient
}

project(':server') {
   dependencies.compile project(':parser'), project(':protocol'),  
SERVLET_API, project(':core'), project(':dependencies:i18n'),  
ACTIVATION, COMMONS.logging
}

project(':security') {
   dependencies.compile project(':server'), project(':client'),  
project(':core'), project(':dependencies:i18n'), XML_SECURITY,  
COMMONS.codec, AXIOM, XERCES
}

project(':spring') {
   dependencies.compile project(':server'),  
'org.springframework:spring-web:2.0.6', 'org.springframework:spring-
beans:2.0.6', 'org.springframework:spring-core:2.0.6',  
'org.springframework:spring-context:2.0.6', SERVLET_API, project
(':core')

}

project(':jcr') {
   dependencies.compile project(':client'), project(':spring'),  
'javax.jcr:jcr:jar:1.0', ['jackrabbit-api', 'jackrabbit-core',  
'jackrabbit-jcr-commons', 'jackrabbit-text-extractors'].collect
{'org.apache.jackrabbit:' + it + ':1.3.1'}

}

project(':extensions:main') {
   dependencies.compile project(':client'),  project(':core'),  
project(':dependencies:i18n'), ACTIVATION
}

project(':extensions:html') {
   dependencies.compile project(':client'), project(':core'), project
(':dependencies:i18n'), project(':parser'), ACTIVATION, AXIOM, PARSER
}

project(':extensions:gdata') {
   dependencies.compile project(':client'), COMMONS.httpclient,  
project(':core'), ACTIVATION
}

project(':extensions:geo') {
   dependencies.compile project(':client'), project(':core')
}

project(':extensions:json') {
   dependencies.compile project(':extensions:main'), project
(':extensions:html'), project(':server'), project(':core'),  
SERVLET_API, project(':dependencies:i18n'), ACTIVATION, project
(':client')
}

project(':extensions:media') {
   dependencies.compile project(':client'),  project(':core'), project
(':dependencies:i18n'), ACTIVATION
}

project(':extensions:opensearch') {
   dependencies.compile project(':client'), project(':core'),  
ACTIVATION, project(':dependencies:i18n')
}

project(':extensions:sharing') {
   dependencies.compile project(':client'), project(':core'), project
(':dependencies:i18n'), ACTIVATION
}

project(':extensions:wsse') {
   dependencies.compile project(':client'), project(':core'),  
COMMONS.httpclient, COMMONS.codec
}

project(':extensions:oauth') {
   dependencies.compile project(':client'), COMMONS.httpclient,  
COMMONS.codec
}

project(':extensions:serializer') {
   dependencies.compile project(':server'), project(':core'), project
(':dependencies:i18n'), ACTIVATION
}

project(':extensions:features') {
   dependencies.compile project(':server'), project(':client'),  
project(':core'), project(':dependencies:i18n'), ACTIVATION
}

project(':examples') {
   dependencies.compile project(':extensions').subprojects, project
(':core'), project(':dependencies:i18n'), project(':protocol'),  
COMMONS.httpclient, project(':client'), project(':parser'), project
(':security'), JETTY, project(':server'), ACTIVATION, JAXEN,  
SERVLET_API, AXIOM
}

--
Hans Dockter
Gradle Project lead
http://www.gradle.org





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

    http://xircles.codehaus.org/manage_email