### Team
- [X] I've assigned a team label to this issue
### Severity
Bl…ocking one customer at present
### Version
2021.3.8705
### Latest Version
I could reproduce the problem in the latest build
### What happened?
If a release has a commit message that links to a Jira Issue, after exporting the project then attempting to import the project to another instance, you receive a 'Found unmapped Ids in document' error.
### Reproduction
Reproduced locally. Please feel free to discuss with me, so you can see on my setup.
### Error and Stacktrace
```
Task ID: ServerTasks-1282
Related IDs: Spaces-1
Task status: Failed
Task queued: Wednesday, 24 November 2021 1:16:17 PM +01:00
Task started: Wednesday, 24 November 2021 1:16:18 PM +01:00
Task completed: Wednesday, 24 November 2021 1:16:22 PM +01:00
Task duration: 4 seconds
Server version: 2021.3.8705
Server node: WIN-TGVTF4S58PJ
| Failed: Project import
13:16:19 Info | Starting import
13:16:19 Info | Extracting exported files
13:16:19 Info | Extraction complete
13:16:19 Info | Extracting exported files
13:16:19 Info | Extraction complete
13:16:19 Info | Validating export package
13:16:20 Info | Validation complete
13:16:20 Info | Upgrading export set...
13:16:20 Info | Export set upgraded.
13:16:22 Verbose | Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",.
| Reference path: Project 'Deploy a package' => Release '4.0.14'
| Octopus.ImportExport.DocumentSources.BreadcrumbedException: Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",.
| Reference path: Project 'Deploy a package' => Release '4.0.14'
| ---> Octopus.ImportExport.BentoIdException: Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",
| at Octopus.ImportExport.DocumentSources.DocumentSourceBase`2.AssertIdsHaveBeenFixed(Object document) in ./source/Octopus.ImportExport/DocumentSources/DocumentSourceBase.cs:line 24
| at Octopus.ImportExport.DocumentSources.DocumentSourceBase`2.Insert(TModel model, IRawWriteQueryExecutor writeQueryExecutor, InsertOptions insertOptions) in ./source/Octopus.ImportExport/DocumentSources/DocumentSourceBase.cs:line 30
| at Octopus.ImportExport.DocumentSources.ProjectReleaseDocumentSource.<>c__DisplayClass11_3.<ImportDocuments>b__4(ImportExportBreadcrumb`1 breadcrumb) in ./source/Octopus.ImportExport/DocumentSources/ProjectReleaseDocumentSource.cs:line 130
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.<>c__DisplayClass6_0`1.<WithinChildBreadcrumb>b__0() in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 41
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WrapExceptions[TReturn](ImportExportBreadcrumb breadcrumb, Func`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 58
| --- End of inner exception stack trace ---
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WrapExceptions[TReturn](ImportExportBreadcrumb breadcrumb, Func`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 69
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WithinChildBreadcrumb[TChildModel](String documentName, Action`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership, Boolean forceExceptionsToBeWarnings) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 39
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WithinChildBreadcrumb[TChildModel](TChildModel document, Action`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership, Boolean forceExceptionsToBeWarnings) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 33
| at Octopus.ImportExport.DocumentSources.ProjectReleaseDocumentSource.<>c__DisplayClass11_0.<ImportDocuments>b__0(ITaskLog taskLog) in ./source/Octopus.ImportExport/DocumentSources/ProjectReleaseDocumentSource.cs:line 112
| at Octopus.ImportExport.DocumentSources.ImportExportContext.WithinProjectChildLogContext[TModel](ProjectId projectId, Action`1 logCallback) in ./source/Octopus.ImportExport/DocumentSources/ImportExportContext.cs:line 131
| at Octopus.ImportExport.DocumentSources.ProjectReleaseDocumentSource.ImportDocuments(ImportContext context, ProjectId importedProjectId, ProjectId targetProjectId, ImportExportBreadcrumb`1 importBreadcrumb) in ./source/Octopus.ImportExport/DocumentSources/ProjectReleaseDocumentSource.cs:line 104
| at Octopus.ImportExport.DocumentSources.ProjectDocumentSource.<>c__DisplayClass15_0.<ImportDocumentThatDirectlyDependOnProject>b__1(ImportExportBreadcrumb`1 breadcrumb) in ./source/Octopus.ImportExport/DocumentSources/ProjectDocumentSource.cs:line 181
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.<>c__DisplayClass6_0`1.<WithinChildBreadcrumb>b__0() in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 41
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WrapExceptions[TReturn](ImportExportBreadcrumb breadcrumb, Func`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 58
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WithinChildBreadcrumb[TChildModel](String documentName, Action`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership, Boolean forceExceptionsToBeWarnings) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 39
| at Octopus.ImportExport.DocumentSources.ImportExportBreadcrumb.WithinChildBreadcrumb[TChildModel](TChildModel document, Action`1 action, ITaskLog taskLog, LoggingBlockOwnership loggingBlockOwnership, Boolean forceExceptionsToBeWarnings) in ./source/Octopus.ImportExport/DocumentSources/ImportExportBreadcrumb.cs:line 33
| at Octopus.ImportExport.DocumentSources.ProjectDocumentSource.<>c__DisplayClass15_0.<ImportDocumentThatDirectlyDependOnProject>b__0(ITaskLog taskLog) in ./source/Octopus.ImportExport/DocumentSources/ProjectDocumentSource.cs:line 172
| at Octopus.ImportExport.DocumentSources.ImportExportContext.WithinLogContext[TModel](String id, Action`1 logCallback) in ./source/Octopus.ImportExport/DocumentSources/ImportExportContext.cs:line 102
| at Octopus.ImportExport.DocumentSources.ImportExportContext.WithinProjectLogContext(ProjectId projectId, Action`1 logCallback) in ./source/Octopus.ImportExport/DocumentSources/ImportExportContext.cs:line 118
| at Octopus.ImportExport.DocumentSources.ProjectDocumentSource.ImportDocumentThatDirectlyDependOnProject(ImportContext context, ImportedDocumentMapping`2 importedProject, Project model, RootImportExportBreadcrumb rootBreadcrumb) in ./source/Octopus.ImportExport/DocumentSources/ProjectDocumentSource.cs:line 170
| at Octopus.ImportExport.DocumentSources.ProjectDocumentSource.ImportDocuments(ImportContext context) in ./source/Octopus.ImportExport/DocumentSources/ProjectDocumentSource.cs:line 98
| at Octopus.ImportExport.Import.Importer.<>c__DisplayClass12_0.<<Import>b__0>d.MoveNext() in ./source/Octopus.ImportExport/Import/IImporter.cs:line 94
| --- End of stack trace from previous location ---
| at Octopus.Server.Infrastructure.Orchestration.UnitsOfWork.UnitOfWorkExecutor.<>c__DisplayClass3_0`1.<<Execute>b__0>d.MoveNext() in ./source/Octopus.Server/Infrastructure/Orchestration/UnitsOfWork/UnitOfWorkExecutor.cs:line 61
| --- End of stack trace from previous location ---
| at Octopus.Core.Infrastructure.UnitsOfWork.UnitOfWorkExtensionMethods.DoAsync(IUnitOfWork unitOfWork, Func`1 action, CancellationToken cancellationToken, String name) in ./source/Octopus.Core/Infrastructure/UnitsOfWork/UnitOfWorkExtensionMethods.cs:line 73
| at Octopus.Core.Infrastructure.UnitsOfWork.UnitOfWorkExtensionMethods.DoAsync(IUnitOfWork unitOfWork, Func`1 action, CancellationToken cancellationToken, String name) in ./source/Octopus.Core/Infrastructure/UnitsOfWork/UnitOfWorkExtensionMethods.cs:line 73
| at Octopus.Server.Infrastructure.Orchestration.UnitsOfWork.UnitOfWorkExecutor.Execute[T](Func`3 action, CancellationToken cancellationToken, String name) in ./source/Octopus.Server/Infrastructure/Orchestration/UnitsOfWork/UnitOfWorkExecutor.cs:line 62
| at Nito.AsyncEx.Synchronous.TaskExtensions.WaitAndUnwrapException(Task task)
| at Octopus.Core.Extensions.TaskExtensionMethods.AsSync(Task task) in ./source/Octopus.Core/Extensions/TaskExtensionMethods.cs:line 17
| at Octopus.ImportExport.Import.Importer.Import(ImportTaskArguments taskArguments, ITaskLog taskLog) in ./source/Octopus.ImportExport/Import/IImporter.cs:line 87
| Octopus.Server version 2021.3.8705 (2021.3.8705)
13:16:22 Fatal | Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",.
| Reference path: Project 'Deploy a package' => Release '4.0.14'
|
| Failed: Projects
|
| Failed: Deploy a package
13:16:20 Info | Created new 'Deploy a package'(Projects-141)
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process with 1 step
13:16:20 Info | Created variable set values (added: 0)
13:16:20 Info | Imported deployment settings
13:16:22 Fatal | Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",.
| Reference path: Project 'Deploy a package' => Release '4.0.14'
|
| Success: Channels
13:16:20 Info | Created 'Default'
|
| Failed: Releases
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-3-45N8Z) with 1 step for release '0.0.1'
13:16:20 Info | Created project variable set snapshot (variableset-Projects-141-s-0-2XKXW) with 0 variables for release '0.0.1'
13:16:20 Info | Created new '0.0.1'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-4-5U4CZ) with 1 step for release '1.1.202'
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.202'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-5-GCSV5) with 1 step for release '1.1.203'
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.203'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-6-MXY85) with 1 step for release '1.1.204'
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.204'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-7-Z4U3D) with 1 step for release '1.1.205'
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.205'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-7-Z4U3D
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.206'
13:16:20 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:20 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-8-5FUBT) with 1 step for release '1.1.207'
13:16:20 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:20 Info | Created new '1.1.207'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.226'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.228'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.230'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.232'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.233'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-8-5FUBT
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.234'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-12-L3UZW) with 1 step for release '1.1.235'
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.235'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.236'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.237'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '1.1.238'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '3.0.0'
13:16:21 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:21 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:21 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:21 Info | Created new '3.0.1'
13:16:21 Verbose | Created task 'Deploy'
13:16:22 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:22 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:22 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:22 Info | Created new '3.0.2'
13:16:22 Verbose | Created task 'Deploy'
13:16:22 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:22 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:22 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:22 Info | Created new '4.0.10'
13:16:22 Verbose | Created task 'Deploy'
13:16:22 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:22 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:22 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:22 Info | Created new '4.0.11'
13:16:22 Verbose | Created task 'Deploy'
13:16:22 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:22 Verbose | Reusing matching deployment process snapshot deploymentprocess-Projects-141-s-12-L3UZW
13:16:22 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:22 Info | Created new '4.0.12'
13:16:22 Verbose | Created task 'Deploy'
13:16:22 Verbose | Created task 'Deploy'
13:16:22 Verbose | Processing action 'Deploy a Package' (Octopus.TentaclePackage)
13:16:22 Info | Created deployment process snapshot (deploymentprocess-Projects-141-s-13-6MCWU) with 1 step for release '4.0.14'
13:16:22 Verbose | Reusing matching project variable snapshot variableset-Projects-141-s-0-2XKXW
13:16:22 Fatal | Found unmapped Ids in document '4.0.14' (Octopus.Core.Model.Projects.Release):
| "Id": "JIR-1-D4C63A85E7894C5D8C20D9297FEA1A43",.
| Reference path: Project 'Deploy a package' => Release '4.0.14'
|
| Success: Project Groups
13:16:20 Info | Matched existing 'Default Project Group' (ProjectGroups-1)
|
| Success: Lifecycles
13:16:20 Info | Created new 'Cowboy Hat' (Lifecycles-2)
|
| Success: Deployment Environments
13:16:20 Info | Created new 'Production' (Environments-41)
|
| Success: Library Variable Sets
|
| Success: Feeds
13:16:20 Info | Matched existing 'Octopus Server (built-in)' (feeds-builtin)
13:16:20 Info | Created new 'Github Feed (DaneFalvo)' (Feeds-1021)
|
| Success: Tenants
|
```
### More Information
https://help.octopus.com/t/while-import-old-package-jira-issues-are-not-getting-linked/27376
### Workaround
_No response_