Hello,
I am working on an automation rule that will auto set the approver for specific requests. I had this working at my previous company but for some reason I can't get it working at my new one. I have the workflow set to "Include Approval Step" and the rule is Trigger "When:Work item created" -> Request Type equal "specific app" -> Then: Edit work items fields Approvers and Request participants.
I keep getting the error message:
Hi Levi - Welcome to the Atlassian Community!
Make sure those fields are on the Create and Edit screens.
@Bill Sheboy @John Funk I verified that the fields were in the Create and Edit screens and added the Re-Fetch Work From Item Data action and now it says it succeeds but it fails to actually add the approver and requested participant. The audit just says " The following work items did not match the condition:" I know it something staring me straight in the face but i'm at a loss.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Levi Stone -- Welcome to the Atlassian Community!
Yes, and...to the suggestion from @John Funk
The Work Item Created trigger has a timing problem where it can start a rule so quickly some data may not be available yet; the work item could even be in an unstable state, leading to strange errors.
I recommend always adding the Re-fetch Work Item Data action immediately after this specific trigger. That will slow the rule slightly, reloading the data before the steps proceed. Doing this will confirm if the cause is timing or something else.
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please post images of your current, complete rule and the audit log details showing the rule execution. Those will provide context to help explain what is happening. Thanks!
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.
@Bill Sheboy thank you for taking sometime to look at this.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Your original question indicated the trigger was Work Item Created, and that is why I suggested adding the re-fetch action.
Now your rule is using a Manual Trigger. Did you change the trigger for testing purposes?
The audit log shows that work item, SUP-17, does not match the Request Type of "Mother Earth Access Request". What value is currently selected for the field?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Bill Sheboy my apologies I uploaded the wrong picture. I had a manual one for testing and it fails the same way. Here is the none manual trigger one.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried this with a rule in a JSM project and the field condition with Request Type worked as expected.
Do you perhaps have multiple request types with similar names and the wrong one is being checked for a match?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I don't and I even deleted the old one and created a new one from scratch and getting the exact same error that the work item fields didn't match the condition.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Next thing to try: glitched rule.
Rules which have been updated / published multiple times (or where the site configurations have changed) can get broken in the supporting JSON.
The primary way to check for this "glitching" is to:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I actually did try that already because i did experience that in the past and still exact same error. I'm stumped why its not seeing the fields.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
At this point, I recommend working with your Site Admin to ping the Atlassian Support team to ask for their input. They may see something we are missing.
You appear to be on a paid license and so your admin can do that here: https://support.atlassian.com/contact/#/
When you hear back from them, please post what you learn. Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Levi Stone ,
Welcome to the community!
For the request types you're automation is running on can you see the Request participants and Approvers field on the layout / issue view? I would make sure those two fields are on the screen
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.