It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Using Power Script to use validator not working

Junianto Kosasih Jul 28, 2017

I am evaluating Power Script to be used in our JIRA. As I am following the sample code for validator (comments required) to transition to another workflow, it does not seem to work. There is no comment provided, but the transition still happens. 

How to get this to work?I have set it up for transition in my workflow. I am using SIL 4.0.6 version.

Thank you.


3 answers

0 votes
Justin Evans Aug 07, 2017

The following sample script worked for me. Are you sure you associated the script as a validator with the intended transition?


Use this script as a workflow transition validator to allow transition only if
a comment has been supplied.

string errorMsg = "You must enter a comment!";
if(!hasInput("comment")) {
  return false, "comment", errorMsg;



0 votes
Junianto Kosasih Aug 11, 2017

Hi Justin,

Thank you for the reply. I have followed the instruction and put the transition as part of the validator.

If you see my workflow below, the 'check_for_comment' transition from 'BACKLOG' to 'IN PROGRESS', I have validator set. I could see from your answer that it works for me. I am trying to figure out what do I miss. Could you please give me some pointers/information?

Thank you.


0 votes
Jonathan Muse Jan 09, 2018

Hi @Junianto Kosasih, I see this question is pretty old. Are you still having problems with this?

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Marketplace Apps & Integrations

Webinar invitation: Generate custom Jira Cloud PDF reports and exports

Jira may be a staple part of your workday, but your colleagues, customers, business partners or an auditor might need information presented in a different format, that is easy to access and read. And...

60 views 0 1
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you