Throwing Error Messages: [You can not transition a null issue.] error during change status

I want to change the status of linked issue from resolved to waiting for triage.

 Reopen is a transition in between them. and I am getting action ID 131 of this transtion. using below code

 

com.opensymphony.workflow.loader.StepDescriptor currentStep = workFlow.getLinkedStep(link.destinationObject.getStatus());
// com.opensymphony.workflow.loader.StepDescriptor currentStep = workFlow.getLinkedStatusObjects();
IssueService issueService = ComponentAccessor.getIssueService();
List<ActionDescriptor> actions = currentStep.getActions();

log.error "Size"+actions.size()
for (ActionDescriptor action: actions)
{
log.error "Action name:" +action.getName()
if (action.getName().equals("Reopen"))
{
int a=action.getId();

IssueInputParameters issueInputParameters = new IssueInputParametersImpl();

log.error "Action ID"+ a +"User " +appUser+""+id+""+issueInputParameters;
TransitionValidationResult transitionValidationResult= issueService.validateTransition(appUser,id,10005, issueService.newIssueInputParameters());
if (transitionValidationResult.isValid()) {
IssueResult transitionResult = issueService.transition(appUser, transitionValidationResult);
}
else{

ErrorCollection errorCollection = transitionValidationResult.getErrorCollection();

log.error "Result Check"+errorCollection
// showTransitionErrors(transitionValidationResult);
}

 

but still getting TransitionValidationResult is Invalid. Why it is so? where is the problem.

1 answer

1 accepted

Accepted Answer
0 votes

You don't appear to be giving it an issue to transtion.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Featured Groups

Tuesday tips & tricks: What is the Atlassian Community?

It's officially Tuesday, which means it's officially time for another tip to help you better navigate this space we call the Atlassian Community. 😄 I got a great question from community member, Sa...

133 views 6 8
View post

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