You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is more of a question than an issue, but I was wondering if it is possible to use the RestApiScriptRunner to execute a dsl configuration containing calls to a "auto generated" dsl?
I have a use case where a seed job tries to create a jenkins job containing a slack notifier:
Caused by: javaposse.jobdsl.dsl.DslScriptException: (script, line 45) No signature of method: javaposse.jobdsl.dsl.helpers.publisher.PublisherContext.slackNotifier() is applicable for argument types: (script$_run_closure1_closure4_closure10_closure11_closure12) values: [script$_run_closure1_closure4_closure10_closure11_closure12@76884e4b]
Possible solutions: stashNotifier(), stashNotifier(groovy.lang.Closure)
at javaposse.jobdsl.dsl.DslScriptLoader.runScriptEngine(DslScriptLoader.groovy:135)
at javaposse.jobdsl.dsl.DslScriptLoader.runScriptsWithClassLoader_closure1(DslScriptLoader.groovy:78)
at groovy.lang.Closure.call(Closure.java:423)
at groovy.lang.Closure.call(Closure.java:439)
at javaposse.jobdsl.dsl.DslScriptLoader.runScriptsWithClassLoader(DslScriptLoader.groovy:68)
at javaposse.jobdsl.dsl.DslScriptLoader.runScripts(DslScriptLoader.groovy:44)
at javaposse.jobdsl.dsl.DslScriptLoader.runScript(DslScriptLoader.groovy:58)
at javaposse.jobdsl.dsl.DslScriptLoader.runDslEngine(DslScriptLoader.groovy:182)
at com.dslexample.JobScriptsSpec.test script #file.name(JobScriptsSpec.groovy:24)
Caused by: groovy.lang.MissingMethodException: No signature of method: javaposse.jobdsl.dsl.helpers.publisher.PublisherContext.slackNotifier() is applicable for argument types: (script$_run_closure1_closure4_closure10_closure11_closure12) values: [script$_run_closure1_closure4_closure10_closure11_closure12@76884e4b]
Possible solutions: stashNotifier(), stashNotifier(groovy.lang.Closure)
at javaposse.jobdsl.dsl.AbstractExtensibleContext.methodMissing(AbstractExtensibleContext.groovy:19)
at script.run_closure1_closure4_closure10_closure11(script:45)
at script.run_closure1_closure4_closure10_closure11(script)
at javaposse.jobdsl.dsl.ContextHelper.executeInContext(ContextHelper.groovy:16)
at javaposse.jobdsl.dsl.Job.publishers(Job.groovy:640)
at script.run_closure1_closure4_closure10(script:42)
at script.run_closure1_closure4_closure10(script)
The root cause seems to be that the slack plugin uses the automatically generated dsl feature, thus the 'slackNotifier' method is not present when executing the script using the rest runner.
The text was updated successfully, but these errors were encountered:
I think I encountered something very similar, I have code that works well under Jenkins but it fails with a similar groovy.lang.MissingMethodException: No signature of method.
This is more of a question than an issue, but I was wondering if it is possible to use the RestApiScriptRunner to execute a dsl configuration containing calls to a "auto generated" dsl?
I have a use case where a seed job tries to create a jenkins job containing a slack notifier:
I get the following exception:
The root cause seems to be that the slack plugin uses the automatically generated dsl feature, thus the 'slackNotifier' method is not present when executing the script using the rest runner.
The text was updated successfully, but these errors were encountered: