1
0
-1

Hello Support,

I’m trying to sync issue with sub-task from my cloud env. to my on-prem env.

I followed your documentation but still getting error message (using script mode).

The sync of the parent task is working as expected by another connection.

Caused by: javax.script.ScriptException: javax.script.ScriptException: com.exalate.api.exception.IssueTrackerException: Subtask cannot be created: parent issue with remote ID 11911 was not found. Please make sure the parent issue is synchronized before resolving this error.

Incoming script in Jira data center

if(firstSync && replica.parentId){
    issue.typeName     = "Decision" //Make sure to use the right subtask type here.
    def localParent = nodeHelper.getLocalIssueFromRemoteId(replica.parentId.toLong())
    if(localParent){
        issue.parentId = localParent.id
    } else {
       throw new com.exalate.api.exception.IssueTrackerException("Subtask cannot be created: parent issue with remote id " + replica.parentId + " was not found. Please make sure the parent issue is synchronized before resolving this error" )
    }
}

  1. Support

    Hi,

    In order to sync the parent link with a subtask, you need to first sync a parent task, and then only the related subtasks. So if you sync subtasks before the parent task, you will get an error, may you please make sure the parent issue is synchronized first?

    Best regards.

  2. David Antebi

    Hi Support,


    I double checked, the parent task was already synced to the destination server.


    Thanks,

    David

  3. Support

    Hi,

    Please make sure you do this in the below order:

    1-Un-Exalate the subtask

    2-Make sure the parent is synchronized

    3- Synchronize the subtask. 

    Feel free to contact us back for further questions.

    Kind regards.

  4. David Antebi

    Hi Support,


    I did that several times and it didn't help.

    I also tried to create a new parent task → sync it → then created a new sub-task. That didn't work as well.


    Thanks,
    David

  5. Support

    Hi,

    Is there any error message after you tried?

    Best regards.

  6. David Antebi

    Hi Support,

    I received the exact error message as before
    Caused by: javax.script.ScriptException: javax.script.ScriptException: com.exalate.api.exception.IssueTrackerException: Subtask cannot be created: parent issue with remote ID 11911 was not found. Please make sure the parent issue is synchronized before resolving this error.


CommentAdd your comment...