Error while migrating instances

Hi All,

I am getting below error while migrating instances from one process definition to another as part of deployment. It fails that incidents are not migration. I can see there are few failedjobs in camunda database. please help me with incident migration script.

Failed to migrate instances :

org.camunda.bpm.engine.migration.MigratingProcessInstanceValidationException: ENGINE-23004 Cannot migrate process instance ‘c29ad55b-38e0-11ed-bff0-3441
Cannot migrate transition instance ‘c29ad55b-38e0-11ed-bff0-34415d90ed8c’:
There is no migration instruction for this instance’s activity

Below is the code which is related to migration plan and the execution.

public void migrateInflightInstances(String sourcePDId, String targetPDId){
MigrationPlan migrationPlan = runtimeService

    ProcessInstanceQuery processInstanceQuery = runtimeService