I have a simple automation; it is running far too frequently and is occasionally erroring, and I'm new enough to this I can't see why.
The automation is triggered when an issue is transitioned to Done. For the parent, if the issue is a particular custom issuetype "Deployment Activity" and its status is not Done, and its subtasks' status(es) are Done, then transition the issue to Accepted.
As it is, this runs every time anything transitions to Done, and the conditional check of the issuetype = "Deployment Activity" does not seem to prevent the automation from checking all subtasks, regardless of the issuetype parent.
Once all the appropriate conditions are met, the correct issues are being transitioned to Accepted, but it feels like there should be a lighter-weight solution. Any suggestions for an automation neophyte?
You note that your rule occasionally erroring. Would you please show an image of the audit log details and describe the symptom/error you observe is happening? Thanks!
Regarding your rule structure question, you could merge most of your tests on the parent into a single JQL statement, and use a JQL branch instead.
Kind regards,
Bill
I've only received this error 3-4 times, and it's always been when evaluating standard story issuetypes:
Branch rule / related issues
Error searching for related issues. This is most likely because the following issues don't have a related issue of the type you specified. Try narrowing your search to only include issues that contain links to related issues:
RACE-9210: "(((key = ) AND (issuetype = "Deployment Activity")) AND (key != RACE-9210)) AND (project in (10060,10061))" - Error in JQL Query: Expecting either a value, list or function but got ')'. You must surround ')' in quotation marks to use it as a value. (line 1, character 10)
I'm hoping the change I've made to further restrict to "Parent Matches" as mentioned below will fix the issue, but I'd like to understand what the error is conveying.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Randy O_Neal , my guess is that the error occurs when there is not a parent issue for the issue that was responsible for triggering the automation.
-pjd
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That would make sense... thanks for the assistance. Thanks all!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Randy O_Neal , try adding an additional condition after your When: component like this:
This will at least stop the automation from running if the parent does not exist or is of a different issue type.
-pjd
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.