I'm getting the error "The role defined for the function cannot be assumed by Lambda" when I'm trying to create a lambda function with create-function command.

aws lambda create-function
  --region us-west-2
  --function-name HelloPython
  --zip-file fileb://hello_python.zip
  --role arn:aws:iam::my-acc-account-id:role/default
  --handler hello_python.my_handler
  --runtime python2.7
  --timeout 15
  --memory-size 512
Most people end up in this error because of giving the wrong Role ARN in CloudFormation while creating the Lambda Function.
Make sure the role is completed first by using "DependsOn" and use the intrinsic function  """{ "Fn::GetAtt" : [ "your-role-logical-name", "Arn" ] }"""
The role defined for the function cannot be assumed by Lambda