Error: error updating Lambda Event Source Mapping InvalidParameterValueException: Please add Lambda as a Trusted Entity

Error: error updating Lambda Event Source Mapping (98nsf70d-8754-49df-bcf1-a815d89v65ef): InvalidParameterValueException: Please add Lambda as a Trusted Entity for arn:aws:iam::093647246597:role/iamrole-CPG-central-cpg-AWSLambdaExecutionRole { RespMetadata: { StatusCode: 400, RequestID: “875sdf0-4er9-41qf-afbf-ea11sn3417f7” }, Message_: “Please add Lambda as a Trusted Entity for arn:aws:iam::093647246597:role/iamrole-CPG-central-cpg-AWSLambdaExecutionRole”, Type: “User” }

with aws_lambda_event_source_mapping.cpgCompanyTrigger, on lambda.tf line 443, in resource “aws_lambda_event_source_mapping” “cpgCompanyTrigger”: 443: resource “aws_lambda_event_source_mapping” “cpgCompanyTrigger” {

we have 2 lambdas and used to have same IAM roles for both of them, but now we have two separate policy’s for both the lambdas and the previous roles are deleted, even thought we removed the IAM role we are getting error for the removed policy