-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
Jenkins version = 2.164.3(docker jenkins/jenkins:lts)
Jobdsl version = job-dsl-1.74
I'm getting an error "Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait" when I try to use the originPullRequestDiscoveryTrait.
I think it could be fixed by adding the @Symbol to OriginPullRequestDiscoveryTrait.java.] That's what was done for BranchDiscoveryTrait.java.
job-dsl usage
organizationFolder('Org') {
organizations {
github {
repoOwner('Owner')
traits {
originPullRequestDiscoveryTrait()
}}
}
}
Stacktrace...
javaposse.jobdsl.dsl.DslException: Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait, org.jenkinsci.plugins.github_branch_source.OriginPullRequestDiscoveryTrait]]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105)
- duplicates
-
JENKINS-45504 Add @Symbol annotations to traits
-
- Closed
-
[JENKINS-57942] Found multiple extensions which provide method originPullRequestDiscoveryTrait
Description |
Original:
I'm getting an error "Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait" when I try to use the originPullRequestDiscoveryTrait. I think it could be fixed by adding the @Symbol to [OriginPullRequestDiscoveryTrait.java|[https://github.com/jenkinsci/github-branch-source-plugin/blob/master/src/main/java/org/jenkinsci/plugins/github_branch_source/OriginPullRequestDiscoveryTrait.java#L132].] That's what was done for [BranchDiscoveryTrait.java|https://github.com/jenkinsci/github-branch-source-plugin/blob/master/src/main/java/org/jenkinsci/plugins/github_branch_source/BranchDiscoveryTrait.java]. job-dsl usage {quote}{{organizationFolder('Org') {}} {{ organizations {}} {{ github {}} {{ repoOwner('Owner')}} {{ traits {}} {{ originPullRequestDiscoveryTrait()}} {{ }}} {{ }}} {{ }}} {{}}} {quote} Stacktrace... {quote}javaposse.jobdsl.dsl.DslException: Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait, org.jenkinsci.plugins.github_branch_source.OriginPullRequestDiscoveryTrait]] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83) at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105) {quote} |
New:
I'm getting an error "Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait" when I try to use the originPullRequestDiscoveryTrait. I think it could be fixed by adding the @Symbol to [OriginPullRequestDiscoveryTrait.java|#L132].] That's what was done for [BranchDiscoveryTrait.java|https://github.com/jenkinsci/github-branch-source-plugin/blob/master/src/main/java/org/jenkinsci/plugins/github_branch_source/BranchDiscoveryTrait.java]. job-dsl usage {quote}{{organizationFolder('Org') {}} {{ organizations {}} {{ github {}} {{ repoOwner('Owner')}} {{ traits {}} {{ originPullRequestDiscoveryTrait()}} \{{ }}} \{{ }}} \{{ }}} {{}}} {quote} Stacktrace... {quote}javaposse.jobdsl.dsl.DslException: Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait, org.jenkinsci.plugins.github_branch_source.OriginPullRequestDiscoveryTrait]] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83) at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105) {quote} |
Description |
Original:
I'm getting an error "Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait" when I try to use the originPullRequestDiscoveryTrait. I think it could be fixed by adding the @Symbol to [OriginPullRequestDiscoveryTrait.java|#L132].] That's what was done for [BranchDiscoveryTrait.java|https://github.com/jenkinsci/github-branch-source-plugin/blob/master/src/main/java/org/jenkinsci/plugins/github_branch_source/BranchDiscoveryTrait.java]. job-dsl usage {quote}{{organizationFolder('Org') {}} {{ organizations {}} {{ github {}} {{ repoOwner('Owner')}} {{ traits {}} {{ originPullRequestDiscoveryTrait()}} \{{ }}} \{{ }}} \{{ }}} {{}}} {quote} Stacktrace... {quote}javaposse.jobdsl.dsl.DslException: Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait, org.jenkinsci.plugins.github_branch_source.OriginPullRequestDiscoveryTrait]] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83) at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105) {quote} |
New:
I'm getting an error "Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait" when I try to use the originPullRequestDiscoveryTrait. I think it could be fixed by adding the @Symbol to [OriginPullRequestDiscoveryTrait.java|#L132].] That's what was done for [BranchDiscoveryTrait.java|https://github.com/jenkinsci/github-branch-source-plugin/blob/master/src/main/java/org/jenkinsci/plugins/github_branch_source/BranchDiscoveryTrait.java]. job-dsl usage {quote}{{organizationFolder('Org') {}} {{ organizations {}} {{ github {}} {{ repoOwner('Owner')}} {{ traits {}} {{ originPullRequestDiscoveryTrait()}} } } } {{}}} {quote} Stacktrace... {quote}javaposse.jobdsl.dsl.DslException: Found multiple extensions which provide method originPullRequestDiscoveryTrait with arguments []: [[com.cloudbees.jenkins.plugins.bitbucket.OriginPullRequestDiscoveryTrait, org.jenkinsci.plugins.github_branch_source.OriginPullRequestDiscoveryTrait]] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83) at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105) {quote} |
Link |
New:
This issue duplicates |
Resolution | New: Duplicate [ 3 ] | |
Status | Original: Open [ 1 ] | New: Resolved [ 5 ] |
Assignee | New: Paul Borchers [ pm15borc ] |
Assignee | Original: Paul Borchers [ pm15borc ] |
pm15borc
Would you be able to submit a PR for this?