Questions for Confluence license has expired.

Please purchase a new license to continue using Questions for Confluence.

When I try to exalate a closed issue on Github I receive a "- 422 Validation Failed" error

 
1
0
-1

When I try to update Github Closed Issues from Jira, I receive an error "- 422 Validation Failed". How do I solve this?

    CommentAdd your comment...

    1 answer

    1.  
      1
      0
      -1

      Github does not allow updating issues with status closed.

      As a workaround, please use the following script on your Github Incoming Script:

      import scala.Option
      import com.exalate.services.utils.FutureUtils
      
      if(issue.status.name.equalsIgnoreCase("closed")) {
          def none = Option.empty()
          def state = Option.apply("Open")
          def applyIssue = new services.node.values.ApplyIssue(none, issue.summary, none, none, none, state, none)
          
          def issue = FutureUtils.resultInf(nodeHelper.githubClient.updateIssue("{owner}/{repo}", Integer.valueOf(issue.key), applyIssue))
      }
      
      if(replica.status.name.equalsIgnoreCase("Done")) {
          issue.status = "Closed"
      } else {
          issue.status = "Open"
      }
        CommentAdd your comment...