TFS4JIRA | The summary is invalid because it contains newline characters.

 Problem

Items can't be synchronized from Azure DevOps / TFS to Jira because their Title system field contains newline characters.

The most common error is usually related to the /n newline character. Still, other newline characters in the Title system Azure DevOps field can stop the synchronization to Jira.

Scripting executions that automatically create workitems in Azure DevOps can cause this issue.

e.g. Log errors:

ERROR Initial.InitialSynchronizationTfsToJiraService - SpartezSoftware.Synchronizer.Exceptions.SynchronizationException: Error creating Jira issue from work item #116412 of Bug type which is in Closed state ---> System.Exception: Error creating Jira issue from work item #116412 of Bug type which is in Closed state ---> System.Net.Http.HttpRequestException: Request failed - BadRequest () - Errors: { "summary": "The summary is invalid because it contains newline characters."
SpartezSoftware.Synchronizer.Exceptions.SynchronizationException: Error creating Jira issue from work item #33495 of Task type which is in Done state ---> System.Exception: Error creating Jira issue from work item #33495 of Task type which is in Done state ---> System.Net.Http.HttpRequestException: Request failed - BadRequest (Bad Request) - Errors: { "summary": "The summary is invalid because it contains newline characters." }

 Solution

  1. Ensure that the 'Title' Azure field is mapped to the 'Summary’ Jira field.

  2. Check if there are or were any plugins/scripts filling the ‘Title’ Azure field.

  3. Copy and paste the title for the workitem again as plain text (no format).