Unable to transition JIRA items from Upsource

I have enabled "Enable JIRA iterations workflow" in Upsource's settings page, and have provided the proper transition names:

 

When I raise a concern for a review, nothing happens. I have verified that my transition names are correct in JIRA:

I have also verified that these transition names are correct by going to "rest/api/2/issue/{{IssueID}}/transitions" and inspecting the JSON.

I have also tried tracing the logs in the upsource directory that is on my server. I noticed that I get the following "Bad Request" error as soon as I raise a concern on a review:

 

[2017-05-02 10:24:02,000] WARN command processor-1 .issueTracker.jira.JiraRestAPI - JIRA[{{MyURL}}/rest/api/2/issue/{{IssueID}}/transitions]: failed to do transition 691
com.jetbrains.upsource.UpsourceException: Bad Request
at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.lambda$doTransition$5(JiraRestAPI.java:202)
at com.jetbrains.upsource.integration.issueTracker.api.IssueTrackerRestLogger.logAction(IssueTrackerRestLogger.java:46)
at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.doTransition(JiraRestAPI.java:199)
at com.jetbrains.upsource.integration.issueTracker.jira.JiraConnectionProvider.applyTransition(JiraConnectionProvider.java:273)
at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.b(IssueTrackerManagerImpl.java:333)
at com.jetbrains.upsource.backend.server.core.db.ProjectHolder.with2(ProjectHolder.kt:103)
at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.a(IssueTrackerManagerImpl.java:325)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at com.jetbrains.upsource.util.NamedDaemonThreadFactory.a(NamedDaemonThreadFactory.java:34)
at java.lang.Thread.run(Thread.java:745)

==> ./upsource-frontend/warn.log <==
[2017-05-02 10:24:02,000] WARN command processor-1 .issueTracker.jira.JiraRestAPI - JIRA[{{MyURL}}/rest/api/2/issue/{{IssueID}}/transitions]: failed to do transition 691
com.jetbrains.upsource.UpsourceException: Bad Request
at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.lambda$doTransition$5(JiraRestAPI.java:202)
at com.jetbrains.upsource.integration.issueTracker.api.IssueTrackerRestLogger.logAction(IssueTrackerRestLogger.java:46)
at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.doTransition(JiraRestAPI.java:199)
at com.jetbrains.upsource.integration.issueTracker.jira.JiraConnectionProvider.applyTransition(JiraConnectionProvider.java:273)
at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.b(IssueTrackerManagerImpl.java:333)
at com.jetbrains.upsource.backend.server.core.db.ProjectHolder.with2(ProjectHolder.kt:103)
at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.a(IssueTrackerManagerImpl.java:325)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at com.jetbrains.upsource.util.NamedDaemonThreadFactory.a(NamedDaemonThreadFactory.java:34)
at java.lang.Thread.run(Thread.java:745)

==> ./upsource-frontend/upsource-frontend-stderr.log <==
[2017-05-02 10:24:02,004] [Upsource Frontend Error] [2017-05-02 10:24:02,000] WARN command processor-1 .issueTracker.jira.JiraRestAPI - JIRA[URL/rest/api/2/issue/CM-4758/transitions]: failed to do transition 691
[2017-05-02 10:24:02,006] [Upsource Frontend Error] com.jetbrains.upsource.UpsourceException: Bad Request
[2017-05-02 10:24:02,006] [Upsource Frontend Error] at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.lambda$doTransition$5(JiraRestAPI.java:202)
[2017-05-02 10:24:02,006] [Upsource Frontend Error] at com.jetbrains.upsource.integration.issueTracker.api.IssueTrackerRestLogger.logAction(IssueTrackerRestLogger.java:46)
[2017-05-02 10:24:02,006] [Upsource Frontend Error] at com.jetbrains.upsource.integration.issueTracker.jira.JiraRestAPI.doTransition(JiraRestAPI.java:199)
[2017-05-02 10:24:02,006] [Upsource Frontend Error] at com.jetbrains.upsource.integration.issueTracker.jira.JiraConnectionProvider.applyTransition(JiraConnectionProvider.java:273)
[2017-05-02 10:24:02,006] [Upsource Frontend Error] at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.b(IssueTrackerManagerImpl.java:333)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at com.jetbrains.upsource.backend.server.core.db.ProjectHolder.with2(ProjectHolder.kt:103)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at com.jetbrains.upsource.backend.server.issueTracker.IssueTrackerManagerImpl.a(IssueTrackerManagerImpl.java:325)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
[2017-05-02 10:24:02,007] [Upsource Frontend Error] at com.jetbrains.upsource.util.NamedDaemonThreadFactory.a(NamedDaemonThreadFactory.java:34)
[2017-05-02 10:24:02,008] [Upsource Frontend Error] at java.lang.Thread.run(Thread.java:745)

 

 

 

Keep in mind that transition 691 is the ID of my "Back to Development" transition. How can I fix this?

5 comments
Comment actions Permalink

Could you please specify your Jira version?

0
Comment actions Permalink

My Jira version is v7.2.4.

0
Comment actions Permalink

Ok, could you please post the following json on a jira API under the same user account that is specified in Upsource project settings?

POST rest/api/2/issue/{{IssueID}}/transitions

{ “transition”: { “id”: “691” } }

0
Comment actions Permalink

I did a manual post using Postman, I got:

{"errorMessages":["Time Spent is required."],"errors":{}}

 

I see what might be happening now, in our Jira, "Time Spent" is a required input, so that every user has to log their time before transitioning the item.

 

Is there any way I can supply "1 minutes" for the TimeSpent in the JSON?

0
Comment actions Permalink

Unfortunately no. I see you've already subscribed on corresponding request https://youtrack.jetbrains.com/issue/UP-8550 not much I can add here.

0

Please sign in to leave a comment.