Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradle 2.2: No signature of method: ShadowJar_Decorated.getManifest() #106

Closed
drazzib opened this issue Nov 3, 2014 · 5 comments
Closed
Labels
Milestone

Comments

@drazzib
Copy link

drazzib commented Nov 3, 2014

Hi !

I'm pursuing my journey to support Gradle 2.2 into Shadow plugin.
Since latest Gradle 2.2-RC2 fixed issue #95, I've been able to run my project build a step further.

Right now, I'm having issue with ShadowJar#getManifest method in ShadowJar :

Caused by: groovy.lang.MissingMethodException: No signature of method: com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar_Decorated.getManifest() is applicable for argument types: () values: []
Possible solutions: getManifest(), getManifest(), getManifest(), setManifest(org.gradle.api.java.archives.Manifest), setManifest(org.gradle.api.java.archives.Manifest), manifest(groovy.lang.Closure)
        at com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar.getManifest(ShadowJar.groovy:42)
        at com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar_Decorated.getManifest(Unknown Source)
        at org.gradle.api.internal.BeanDynamicObject$MetaClassAdapter.getProperty(BeanDynamicObject.java:153)
        at org.gradle.api.internal.BeanDynamicObject.getProperty(BeanDynamicObject.java:107)
        at org.gradle.api.internal.CompositeDynamicObject.getProperty(CompositeDynamicObject.java:78)
        at com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar_Decorated.getProperty(Unknown Source)
        at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.configureShadowTask(ShadowJavaPlugin.groovy:48)
        at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.apply(ShadowJavaPlugin.groovy:35)
        at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.apply(ShadowJavaPlugin.groovy)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.providePlugin(DefaultPluginContainer.java:188)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.addPluginInternal(DefaultPluginContainer.java:137)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.apply(DefaultPluginContainer.java:107)
        at org.gradle.api.plugins.PluginContainer$apply.call(Unknown Source)
        at com.github.jengelman.gradle.plugins.shadow.ShadowPlugin$_apply_closure1.doCall(ShadowPlugin.groovy:14)
        at org.gradle.api.internal.ClosureBackedAction.execute(ClosureBackedAction.java:63)
        at org.gradle.internal.Actions$FilteredAction.execute(Actions.java:203)
        at org.gradle.api.internal.DefaultDomainObjectCollection.all(DefaultDomainObjectCollection.java:110)
        at org.gradle.api.internal.DefaultDomainObjectCollection.all(DefaultDomainObjectCollection.java:115)
        at org.gradle.api.internal.DefaultDomainObjectCollection.withType(DefaultDomainObjectCollection.java:126)
        at org.gradle.api.DomainObjectCollection$withType.call(Unknown Source)
        at com.github.jengelman.gradle.plugins.shadow.ShadowPlugin.apply(ShadowPlugin.groovy:13)
        at com.github.jengelman.gradle.plugins.shadow.ShadowPlugin.apply(ShadowPlugin.groovy)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.providePlugin(DefaultPluginContainer.java:188)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.addPluginInternal(DefaultPluginContainer.java:137)
        at org.gradle.api.internal.plugins.DefaultPluginContainer.apply(DefaultPluginContainer.java:107)
        at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.applyPlugin(DefaultObjectConfigurationAction.java:101)
        ... 60 more

Given that comment for this method is

    // This should really return InheritManifest but cannot due to https://jira.codehaus.org/browse/GROOVY-5418
    // TODO - change return type after upgrade to Gradle 2

I'm assuming there might be something wrong here.

Regards !

@drazzib
Copy link
Author

drazzib commented Nov 3, 2014

As a side note, I've tried to remove this override (ie. remove getManifest method from ShadowJar source code) and it seems to work for my use case.

Cheers,

@stackmagic
Copy link

This worked in gradle-2.1. I just ran into the same problem when switching to gradle 2.2. Seems like the gradle people broke something for shadowJar.

@johnrengelman johnrengelman added this to the 1.1.3 milestone Nov 11, 2014
@berinle
Copy link

berinle commented Nov 11, 2014

Sorry, should have checked open issues before opening a new one ;).

@johnrengelman
Copy link
Collaborator

I'm working on adding support for Gradle 2.2, but I've run into another incompatibility that I haven't figure a workaround yet for. I've reached out to the Gradle team to see if they have any ideas.

@johnrengelman
Copy link
Collaborator

Closed with cbc6327

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants