Error running groovy script runner

Hello, this question is for Jamie Echlin or for groovy community:

When I' trying to run a script the following error appeared:

2013-02-28 00:17:47,478 ajp-127.0.0.1-8101-6 ERROR user 17x32515x1 1r787tl 68.164.136.210 /secure/WorkflowUIDispatcher.jspa [onresolve.jira.groovy.GroovyRunner] The script failed : javax.script.ScriptException: javax.script.ScriptException: groovy.lang.MissingPropertyException: No such property: inversion for class: com.onresolve.jira.groovy.canned.workflow.postfunctionspackage.Script26
2013-02-28 00:17:47,478 ajp-127.0.0.1-8101-6 ERROR user 17x32515x1 1r787tl 68.164.136.210 /secure/WorkflowUIDispatcher.jspa [onresolve.jira.groovy.GroovyFunctionPlugin] Error executing post-function
javax.script.ScriptException: javax.script.ScriptException: groovy.lang.MissingPropertyException: No such property: inversion for class: com.onresolve.jira.groovy.canned.workflow.postfunctionspackage.Script26

This is for just one particular script, which its first line has to import the package.

This is my first lines of the script

package com.onresolve.jira.groovy.canned.workflow.postfunctionspackage <-- This the line that may cause the problem


import com.atlassian.jira.ComponentManager
import com.atlassian.jira.issue.MutableIssue
import com.atlassian.crowd.embedded.api.User
import org.ofbiz.core.entity.GenericValue
import org.apache.log4j.Category

// Defninition of the component manager classes
def componentManager
def customFieldManager
def parentIssueFactory
def jiraAuthenticationContext
def parentIssueManager
def subtaskManager

The specification are the following

JIRA 5.0.6

groovyscript 2.0.6

Thanks

2 answers

1 accepted

2 votes
Henning Tietgens Community Champion Feb 27, 2013

I don't think the package is the problem. Is there some reference to "inversion" in your code? There is the problem the error message is pointing to.

Henning

Hi Henning:

I don't think that there is any inversion in my code

Henning Tietgens Community Champion Mar 03, 2013

I'm referring to this part of the error message "MissingPropertyException: No such property: inversion for class: com.onresolve.jira.groovy.canned.workflow.postfunctionspackage.Script26". This error says, you try to access a property "inversion" in your code. For my adapted post functions, the first line is

package com.onresolve.jira.groovy.canned.workflow.postfunctions

and this works without a problem.

Question: If I put one groovy script in one transition and then another script in another transtition, does it affect the inversion?

Henning Tietgens Community Champion Mar 11, 2013

Sorry, I don't know about what "inversion" you're talking. It's not a property I know of, it's only a word I see in your error message.

That's fine. thanks

However, if I set a groovy script in a transition. And then set another script in another transition does it affect the second script by running this type of error?

No that wil be fine.

0 vote

"Hello, this question is for Jamie Echlin"

Ha! I like it Jamie get some special questions addressed just to him :-) .. should make that a tag!

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

164 views 1 17
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you