Skip to content

[Bug]: Error while running TfsTestPlansAndSuitesMigrationProcessor System.NullReferenceException: Object reference not set to an instance of an object #2463

Description

@Lakshminarayana316

Version

  • I confirm that I am using the latest version

Source Version

Azure DevOps Server 2022

Target Version

Azure DevOps Service

Relevant configuration

{
  "Serilog": {
    "MinimumLevel": "Information"
  },
  "MigrationTools": {
    "Version": "16.0",
    "Endpoints": {
      "Source": {
        "EndpointType": "TfsTeamProjectEndpoint",
        "Collection": "https://ss12.adr.com/NordicCollection/",
        "Project": "D_SUPPORT",
        "Authentication": {
          "AuthenticationMode": "AccessToken",
          "NetworkCredentials": null,
          "AccessToken": ""
        },
        "ReflectedWorkItemIdField": "ReflectedWorkItemId",
        "AllowCrossProjectLinking": false,
        "LanguageMaps": {
          "AreaPath": "Area",
          "IterationPath": "Iteration"
        },
        "EndpointEnrichers": null
      },
      "Target": {
        "EndpointType": "TfsTeamProjectEndpoint",
        "Collection": "https://dev.azure.com/THansaTest",
        "Project": "TEAM_MASTER",
        "Authentication": {
          "AuthenticationMode": "AccessToken",
          "NetworkCredentials": null,
          "AccessToken": ""
        },
        "ReflectedWorkItemIdField": "ReflectedWorkItemId",
        "AllowCrossProjectLinking": false,
        "LanguageMaps": {
          "AreaPath": "Area",
          "IterationPath": "Iteration"
        },
        "EndpointEnrichers": null
      }
    },
    "Processors": [
      {
        "ProcessorType": ""TfsTestPlansAndSuitesMigrationProcessor",",
        "Enabled": true,
        "UpdateCreatedDate": false,
        "UpdateCreatedBy": true,
      "TestPlanQueryBit": "SELECT [System.Id],[System.Title] From WorkItems WHERE [System.WorkItemType] ='Test Plan',AND [System.AreaPath] = 'OnlineTE\\DigiKomtom'",
	"AreaMaps": "OnlineTE\\DigiKomtom",
        "FixHtmlAttachmentLinks": true,
        "WorkItemCreateRetryLimit": 5,
        "FilterWorkItemsThatAlreadyExistInTarget": false,
        "PauseAfterEachWorkItem": false,
        "AttachRevisionHistory": true,
        "GenerateMigrationComment": true,
        "WorkItemIDs": null,
        "MaxGracefulFailures": 0,
        "SkipRevisionWithInvalidIterationPath": false,
        "SkipRevisionWithInvalidAreaPath": false,
        "Enrichers": null,
        "SourceName": "Source",
        "TargetName": "Target",
        "RefName": ""
      }
    ],
	
    "CommonTools": {
      "FieldMappingTool": {
        "Enabled": false,
        "FieldMaps": []
      },
	   "TfsGitRepositoryTool": {
        "Enabled": false,
        "Mappings": null
      }
    }
  }
}

Relevant log output

[23:37:11 INF] [16.0.4] Loading 1 Work Items
[23:37:13 FTL] [16.0.4] Error while running TfsTestPlansAndSuitesMigrationProcessor
System.NullReferenceException: Object reference not set to an instance of an object.
   at Microsoft.TeamFoundation.TestManagement.Client.TestSuiteEntry.SetPointAssignments(Guid owner, List`1 configs)
   at Microsoft.TeamFoundation.TestManagement.Client.TestSuiteHelper.ServerAddCasesToSuite(TestSuite parent, IEnumerable`1 entries, Int32 toIndex)
   at Microsoft.TeamFoundation.TestManagement.Client.TestSuite.OnInsertCases(Int32 index, IEnumerable`1 cases, Boolean ignoreDuplicates)
   at Microsoft.TeamFoundation.TestManagement.Client.TestSuiteEntryCollection.InsertCases(Int32 index, IEnumerable`1 cases)
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.AddChildTestCases(ITestSuiteBase source, ITestSuiteBase target, ITestPlan targetPlan) in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 182
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.ProcessTestSuite(ITestSuiteBase sourceSuite, ITestSuiteBase targetParent, ITestPlan targetPlan) in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 1021
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.ProcessTestSuite(ITestSuiteBase sourceSuite, ITestSuiteBase targetParent, ITestPlan targetPlan) in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 1028
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.ProcessTestSuite(ITestSuiteBase sourceSuite, ITestSuiteBase targetParent, ITestPlan targetPlan) in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 1028
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.ProcessTestPlan(ITestPlan sourcePlan) in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 894
   at MigrationTools.Processors.TfsTestPlansAndSuitesMigrationProcessor.InternalExecute() in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools.Clients.TfsObjectModel\Processors\TfsTestPlansAndSuitesMigrationProcessor.cs:line 113
   at MigrationTools.Processors.Infrastructure.Processor.Execute() in D:\a\azure-devops-migration-tools\azure-devops-migration-tools\src\MigrationTools\Processors\Infrastructure\Processor.cs:line 99

What happened?

A bug happened!

Migration Stopped with an error message. and also put filtered with TestPlanQueryBit but that is also not working .Kindly check and help on this issue .

Debug in Visual Studio

  • Visual Studio Debug

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions