Skip to content

"The role defined for the function cannot be assumed by Lambda" error after upgrading to 1.55.0 #6876

@jg-synth

Description

@jg-synth

Bug Report

Description

  1. What did you do?

    I upgraded to serverless@1.55.0 and deployed the latest version of an existing application. Note that this was a re-release (i.e. the same version had been released previously using serverless@1.54.0).

    $ yarn global add serverless@1.55.0
    $ serverless deploy --stage dev
    
  2. What happened?

    Whilst the CloudFormation stack updates, the following error occurs.

    The role defined for the function cannot be assumed by Lambda. (Service: AWSLambdaInternal; Status Code: 400; Error Code: InvalidParameterValueException; Request ID: b63d4eb3-3e38-4d75-a90d-2b23ec1b9606)
    
  3. What should've happened?

    The deployment should have completed successfully.

  4. What's the content of your serverless.yml file?

    app: enact-services
    custom:
    wsgi:
        app: main.app
        packRequirements: false
    pythonRequirements:
        dockerizePip: non-linux
    functions:
    api:
        events:
        - http:
            cors: true
            method: ANY
            path: / # The base path.
        - http:
            cors: true
            method: ANY
            path: /{any+} # All other paths.
        handler: wsgi_handler.handler
    org: <redacted>
    plugins:
    - serverless-python-requirements
    - serverless-wsgi
    provider:
    cfnRole: arn:aws:iam::<redacted>:role/ServerlessCloudFormation
    iamRoleStatements: <redacted>  
    name: aws
    region: eu-west-1
    runtime: python3.7
    service: python-rest-api
    
  5. What's the output you get when you use the SLS_DEBUG=* environment variable (e.g. SLS_DEBUG=* serverless deploy)

     Serverless: Load command config
     Serverless: Load command config:credentials
     Serverless: Load command config:tabcompletion
     Serverless: Load command config:tabcompletion:install
     Serverless: Load command config:tabcompletion:uninstall
     Serverless: Load command create
     Serverless: Load command install
     Serverless: Load command package
     Serverless: Load command deploy
     Serverless: Load command deploy:function
     Serverless: Load command deploy:list
     Serverless: Load command deploy:list:functions
     Serverless: Load command invoke
     Serverless: Load command invoke:local
     Serverless: Load command info
     Serverless: Load command logs
     Serverless: Load command metrics
     Serverless: Load command print
     Serverless: Load command remove
     Serverless: Load command rollback
     Serverless: Load command rollback:function
     Serverless: Load command slstats
     Serverless: Load command plugin
     Serverless: Load command plugin
     Serverless: Load command plugin:install
     Serverless: Load command plugin
     Serverless: Load command plugin:uninstall
     Serverless: Load command plugin
     Serverless: Load command plugin:list
     Serverless: Load command plugin
     Serverless: Load command plugin:search
     Serverless: Load command config
     Serverless: Load command config:credentials
     Serverless: Load command rollback
     Serverless: Load command rollback:function
     Serverless: Load command requirements
     Serverless: Load command requirements:clean
     Serverless: Load command requirements:install
     Serverless: Load command requirements:cleanCache
     Serverless: Load command wsgi
     Serverless: Load command wsgi:serve
     Serverless: Load command wsgi:install
     Serverless: Load command wsgi:clean
     Serverless: Load command wsgi:command
     Serverless: Load command wsgi:command:local
     Serverless: Load command wsgi:exec
     Serverless: Load command wsgi:exec:local
     Serverless: Load command wsgi:manage
     Serverless: Load command wsgi:manage:local
     Serverless: Load command wsgi:flask
     Serverless: Load command wsgi:flask:local
     Serverless: Load command login
     Serverless: Load command logout
     Serverless: Load command generate-event
     Serverless: Load command test
     Serverless: Load command dashboard
     platform-sdk fetching: POST https://api.serverless.com/core/tenants/jdgillespie91/applications/enact-services/profileValue
     Serverless: Invoke deploy
     Serverless: Invoke package
     Serverless: Invoke aws:common:validate
     Serverless: Invoke aws:common:cleanupTempDir
     Serverless: Generated requirements from /home/jake/workspace/<redacted>/services/python-rest-api/requirements.txt in /home/jake/workspace/<redacted>/services/python-rest-api/.serverless/requirements.txt...
     Serverless: Using static cache of requirements found at /home/jake/.cache/serverless-python-requirements/d9b5683b17a71dd984418857d31a4475179531d117e58b548328d556b240ba69_slspyc ...
     Serverless: Using Python specified in "runtime": python3.7
     Serverless: Packaging Python WSGI handler...
     platform-sdk fetching: GET https://api.serverless.com/core/tenants/jdgillespie91/applications/enact-services
     platform-sdk fetching: GET https://api.serverless.com/core/meta
     Serverless: Packaging service...
     Serverless: Excluding development dependencies...
     Serverless: Injecting required Python packages to package...
     Serverless: Installing dependencies for custom CloudFormation resources...
     Serverless: Invoke aws:package:finalize
     Serverless: [AWS sts 200 0.357s 0 retries] getCallerIdentity({})
     platform-sdk fetching: POST https://api.serverless.com/malt/destinations/create
     Serverless: Invoke aws:common:moveArtifactsToPackage
     Serverless: Invoke aws:common:validate
     Serverless: Safeguards Processing...
     Serverless: Safeguards Results:
    
     Summary --------------------------------------------------
    
     running - allowed-runtimes
     passed - allowed-runtimes
     running - allowed-regions
     passed - allowed-regions
     running - no-secret-env-vars
     passed - no-secret-env-vars
     running - require-cfn-role
     passed - require-cfn-role
     running - framework-version
     passed - framework-version
     running - no-unsafe-wildcard-iam-permissions
     passed - no-unsafe-wildcard-iam-permissions
     running - allowed-stages
     passed - allowed-stages
    
     Serverless: Safeguards Summary: 7 passed, 0 warnings, 0 errors
     Serverless: Invoke aws:deploy:deploy
     Serverless: [AWS cloudformation 200 0.122s 0 retries] describeStacks({ StackName: 'python-rest-api-dev' })
     Serverless: [AWS cloudformation 200 0.099s 0 retries] describeStackResource({ StackName: 'python-rest-api-dev',
     LogicalResourceId: 'ServerlessDeploymentBucket' })
     Serverless: [AWS s3 200 0.148s 0 retries] listObjectsV2({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Prefix: 'serverless/python-rest-api/dev' })
     Serverless: [AWS s3 200 0.086s 0 retries] headObject({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571844466535-2019-10-23T15:27:46.535Z/custom-resources.zip' })
     Serverless: [AWS s3 200 0.098s 0 retries] headObject({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571844466535-2019-10-23T15:27:46.535Z/python-rest-api.zip' })
     Serverless: [AWS s3 200 0.077s 0 retries] headObject({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571844466535-2019-10-23T15:27:46.535Z/compiled-cloudformation-template.json' })
     Serverless: [AWS lambda 200 0.127s 0 retries] getFunction({ FunctionName: 'python-rest-api-dev-api' })
     Serverless: [AWS sts 200 0.345s 0 retries] getCallerIdentity({})
     Serverless: Uploading CloudFormation file to S3...
     Serverless: [AWS s3 200 0.236s 0 retries] putObject({ Body:
     <Buffer 7b 22 41 57 53 54 65 6d 70 6c 61 74 65 46 6f 72 6d 61 74 56 65 72 73 69 6f 6e 22 3a 22 32 30 31 30 2d 30 39 2d 30 39 22 2c 22 44 65 73 63 72 69 70 74 ... >,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/compiled-cloudformation-template.json',
     ContentType: 'application/json',
     Metadata:
     { filesha256: '14H2rR59C3ZaTCSFhRhavT7ZFxAFRjXKyqCS/OTayFI=' } })
     Serverless: Uploading artifacts...
     Serverless: Uploading service python-rest-api.zip file to S3 (57.04 MB)...
     Serverless: [AWS s3 200 0.116s 0 retries] createMultipartUpload({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     ContentType: 'application/zip',
     Metadata:
     { filesha256: 'vbki9d4ggYLpOp0ODl8f+UY6S2xFEu8kGU8gyKzHy7A=' } })
     Serverless: [AWS s3 200 1.993s 0 retries] uploadPart({ Body:
     <Buffer f2 c1 cc 1f 06 97 1b 75 39 f9 d9 4e b9 5e a0 ad bc 5f 7e 04 41 69 0c 91 c6 30 79 0c 64 f2 07 65 b5 e3 3a da 9a 1d 37 72 b6 31 fe ee 08 e7 27 ef ce d8 ... >,
     ContentLength: 5242880,
     PartNumber: 2,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.001s 0 retries] uploadPart({ Body:
     <Buffer e0 92 4f 58 79 7e d2 6e 40 f1 70 92 b4 e5 fe c7 bf 0e 6e 59 5c 6d b5 fc 41 49 7e c8 03 2f 34 13 1e db aa 6c b6 e1 34 54 56 5a b7 c0 3b 83 95 94 69 15 ... >,
     ContentLength: 5242880,
     PartNumber: 3,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.105s 0 retries] uploadPart({ Body:
     <Buffer 50 4b 03 04 0a 00 00 00 08 00 00 00 21 00 43 bf a6 a3 04 00 00 00 02 00 00 00 26 00 00 00 2e 6d 79 70 79 5f 63 61 63 68 65 2f 33 2e 37 2f 40 70 6c 75 ... >,
     ContentLength: 5242880,
     PartNumber: 1,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.192s 0 retries] uploadPart({ Body:
     <Buffer f6 a2 3a 18 e6 a8 c7 c7 cd 9f 15 79 61 2b fe b5 0e 0c e5 86 62 e6 3f 26 27 8d 47 f9 77 fc 76 d8 f9 e8 30 3a 2e 56 6b 57 d1 97 bc 85 de c2 dd 51 a3 ac ... >,
     ContentLength: 5242880,
     PartNumber: 4,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 1.678s 0 retries] uploadPart({ Body:
     <Buffer bd f8 ba 7c 5f 37 6c f1 40 ae 8d 38 1b e5 4b 8f bc 87 96 36 61 3b 52 b4 bc 98 5a be df 80 ad cd cd aa f7 72 78 8a f9 0e 4d 11 3e 37 4a 9d 6e aa 6d 51 ... >,
     ContentLength: 5242880,
     PartNumber: 5,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.001s 0 retries] uploadPart({ Body:
     <Buffer d2 1e 1e 17 d5 60 87 9f 60 0c 76 07 3c 21 bd fd d6 8d 20 21 2c 5f 9b 2e 01 03 1d f7 e7 a3 89 2c a7 44 13 d1 64 cb 87 3b 1d 7d ac 46 f3 15 ad 47 2c 11 ... >,
     ContentLength: 5242880,
     PartNumber: 6,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.066s 0 retries] uploadPart({ Body:
     <Buffer 35 9c 7b 9c 13 05 40 b7 97 71 fb 10 0e 4c 2f 6d cf c4 1f 71 63 2f c3 de 28 b4 ef 30 6f 96 e6 a7 d4 11 74 bc 37 8f 33 1a bf 34 cc d5 78 f6 d6 5e d8 71 ... >,
     ContentLength: 5242880,
     PartNumber: 7,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 2.005s 0 retries] uploadPart({ Body:
     <Buffer 7c a3 64 20 88 b8 7e 36 28 59 0b 22 ae 9f 6f 95 dc 01 91 47 f3 ef 94 14 fb c3 be 84 fa bd 25 c6 69 52 49 63 b2 ed 51 5d 63 b2 e5 51 03 31 f6 10 f3 c9 ... >,
     ContentLength: 5242880,
     PartNumber: 8,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 1.046s 0 retries] uploadPart({ Body:
     <Buffer 63 0d 9a df 65 8c 16 df 6b a5 38 47 15 8b fa 09 5d de 30 9b c5 3a 26 90 d8 48 42 53 a3 38 0c 51 b1 06 86 02 19 99 7c a0 51 1c fa 02 5c 9b bb 1d 00 07 ... >,
     ContentLength: 2135453,
     PartNumber: 12,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 1.671s 0 retries] uploadPart({ Body:
     <Buffer a6 6b 24 59 07 e7 64 0c 48 45 c9 3e 85 c6 ff 12 b5 7e d0 ef 93 22 94 ea 2b a9 c8 a1 61 71 06 0e bb b3 6a c2 ee c7 0e a7 52 51 35 38 ec cb e4 9e 8d 22 ... >,
     ContentLength: 5242880,
     PartNumber: 9,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 1.426s 0 retries] uploadPart({ Body:
     <Buffer cb 7f e3 4b 83 82 05 35 30 a8 e1 44 c0 33 9c b2 ec 4b 98 dd 10 3f 9a 65 ef 46 97 dc 98 ad 51 da 96 92 60 b0 2b 29 09 ae ce 75 20 02 0f c7 e7 5a 35 b5 ... >,
     ContentLength: 5242880,
     PartNumber: 10,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 1.602s 0 retries] uploadPart({ Body:
     <Buffer a4 8b 09 80 77 08 b2 0e cf e8 e4 35 cc 80 0e f3 79 10 1f 74 18 87 3f c6 53 b0 5a 4f 20 47 76 79 49 bc 1f 8e 8f 61 75 be 5d 32 a1 08 f8 ad 53 fc 76 69 ... >,
     ContentLength: 5242880,
     PartNumber: 11,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: [AWS s3 200 0.143s 0 retries] completeMultipartUpload({ MultipartUpload:
     { Parts:
         [ { ETag: '"b94387b98dc7171f83d1254da0c47a06"', PartNumber: 1 },
             { ETag: '"f515b7a4e069fbc8ba3dc863d9bafec8"', PartNumber: 2 },
             { ETag: '"d0b5203f889cefa8fe8a934c28375d4c"', PartNumber: 3 },
             { ETag: '"a297d55ebb042e785b706288387453ac"', PartNumber: 4 },
             { ETag: '"c18b5634d9d801ea0e1badbcdf003da9"', PartNumber: 5 },
             { ETag: '"b401f68e1cb50070dbc0534e66cfb738"', PartNumber: 6 },
             { ETag: '"54d6d5c47c6be0faa11fb7865d18d29a"', PartNumber: 7 },
             { ETag: '"5b2185f85b30fcd7dde7b19632e2127c"', PartNumber: 8 },
             { ETag: '"9f6a20263c9c1e25885b2f1a9122e1fe"', PartNumber: 9 },
             { ETag: '"192219b898fc46f66a5145a9f5dce567"', PartNumber: 10 },
             { ETag: '"b053cd3bf45674fdf91a32b1d8847a98"', PartNumber: 11 },
             { ETag: '"cba6a28f821e7fe8df553cfc30fb4b94"', PartNumber: 12 },
             [length]: 12 ] },
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/python-rest-api.zip',
     UploadId:
     'KeUQGiGdAMrhMRNJmzJhW9JTDjQ.i4bLRXN38VdMTCRVmpy8oTjFHJD8aJ2Z3QuMt9QY5BJiV_EMyHCkCSereAN5GZiQ5xCf08SaGwPRhAch2EG5jvVphtmRlqUIKPhu' })
     Serverless: Uploading custom CloudFormation resources...
     Serverless: [AWS s3 200 0.12s 0 retries] createMultipartUpload({ Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/custom-resources.zip',
     ContentType: 'application/zip',
     Metadata:
     { filesha256: 'NGRC1OkjyOb6NZEmbuSO+/2BE0e7Xs33kHBOJqSFoT4=' } })
     Serverless: [AWS s3 200 0.283s 0 retries] uploadPart({ Body:
     <Buffer f7 49 1f 69 76 3a 02 92 43 4e be 9f 7d 09 61 b5 45 05 c6 30 d7 82 af 0e d7 22 df a6 39 88 74 e2 d8 aa d6 48 40 1a 0d 83 bd 91 71 40 1b 15 8d 5b 56 24 ... >,
     ContentLength: 733949,
     PartNumber: 2,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/custom-resources.zip',
     UploadId:
     'XTRJRadNxPm7yUsZfOK5DPrpPzesgKlfQO7Tw_DZHAwOrhYXAX471DPvtgcbaG5Wo8SNFftmQpaE70nZbGQMY6ZsXFM0S4NIdRY_3lLbj5v7zYL8aZK9LlIq5m0dXGLK' })
     Serverless: [AWS s3 200 0.946s 0 retries] uploadPart({ Body:
     <Buffer 50 4b 03 04 14 00 08 00 08 00 88 7d 57 4f 00 00 00 00 00 00 00 00 00 00 00 00 09 00 00 00 52 45 41 44 4d 45 2e 6d 64 8d cd c1 09 80 30 0c 46 e1 7b a7 ... >,
     ContentLength: 5242880,
     PartNumber: 1,
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/custom-resources.zip',
     UploadId:
     'XTRJRadNxPm7yUsZfOK5DPrpPzesgKlfQO7Tw_DZHAwOrhYXAX471DPvtgcbaG5Wo8SNFftmQpaE70nZbGQMY6ZsXFM0S4NIdRY_3lLbj5v7zYL8aZK9LlIq5m0dXGLK' })
     Serverless: [AWS s3 200 0.146s 0 retries] completeMultipartUpload({ MultipartUpload:
     { Parts:
         [ { ETag: '"410f979cb24ca0cbdb0593a4f1f0a986"', PartNumber: 1 },
             { ETag: '"82e36c8a957406f77bd264fa53c80944"', PartNumber: 2 },
             [length]: 2 ] },
     Bucket:
     'python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb',
     Key:
     'serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/custom-resources.zip',
     UploadId:
     'XTRJRadNxPm7yUsZfOK5DPrpPzesgKlfQO7Tw_DZHAwOrhYXAX471DPvtgcbaG5Wo8SNFftmQpaE70nZbGQMY6ZsXFM0S4NIdRY_3lLbj5v7zYL8aZK9LlIq5m0dXGLK' })
     Serverless: Validating template...
     Serverless: [AWS cloudformation 200 0.373s 0 retries] validateTemplate({ TemplateURL:
     'https://s3.amazonaws.com/python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb/serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/compiled-cloudformation-template.json' })
     Serverless: Updating Stack...
     Serverless: [AWS cloudformation 200 0.415s 0 retries] updateStack({ StackName: 'python-rest-api-dev',
     Capabilities: [ 'CAPABILITY_IAM', 'CAPABILITY_NAMED_IAM', [length]: 2 ],
     Parameters: [ [length]: 0 ],
     TemplateURL:
     'https://s3.amazonaws.com/python-rest-api-dev-serverlessdeploymentbucket-1skkoq13ljotb/serverless/python-rest-api/dev/1571845455510-2019-10-23T15:44:15.510Z/compiled-cloudformation-template.json',
     Tags: [ { Key: 'STAGE', Value: 'dev' }, [length]: 1 ],
     RoleARN: 'arn:aws:iam::<redacted>:role/ServerlessCloudFormation' })
     Serverless: Checking Stack update progress...
     Serverless: [AWS cloudformation 200 0.222s 0 retries] describeStackEvents({ StackName:
     'arn:aws:cloudformation:eu-west-1:<redacted>:stack/python-rest-api-dev/f1c3db20-ea87-11e9-b3b3-0ade9df0c35e' })
     ....
     Serverless: Operation failed!
     Serverless: View the full error output: https://eu-west-1.console.aws.amazon.com/cloudformation/home?region=eu-west-1#/stack/detail?stackId=arn%3Aaws%3Acloudformation%3Aeu-west-1%3A<redacted>%3Astack%2Fpython-rest-api-dev%2Ff1c3db20-ea87-11e9-b3b3-0ade9df0c35e
     Serverless: Publishing service to the Serverless Dashboard...
     Serverless: [AWS sts 200 0.362s 0 retries] getCallerIdentity({})
     Serverless: [AWS cloudformation 200 0.103s 0 retries] describeStacks({ StackName: 'python-rest-api-dev' })
     platform-sdk fetching: POST https://api.serverless.com/core/tenants/jdgillespie91/applications/enact-services/services/python-rest-api/stages/dev/regions/eu-west-1/deployments
     Serverless: Successfully published your service to the Serverless Dashboard: https://dashboard.serverless.com/tenants/jdgillespie91/applications/enact-services/services/python-rest-api/stage/dev/region/eu-west-1
     
     Serverless Error ---------------------------------------
     
     ServerlessError: An error occurred: CustomDashresourceDashapigwDashcwDashroleLambdaFunction - The role defined for the function cannot be assumed by Lambda. (Service: AWSLambdaInternal; Status Code: 400; Error Code: InvalidParameterValueException; Request ID: f3603229-2ffd-4f7f-b441-e3153321cf75).
         at provider.request.then.data (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/monitorStack.js:122:33)
     From previous event:
         at AwsDeploy.monitorStack (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/monitorStack.js:28:12)
         at provider.request.then.cfData (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/updateStack.js:103:28)
     From previous event:
         at AwsDeploy.update (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/updateStack.js:103:8)
     From previous event:
         at AwsDeploy.BbPromise.bind.then (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/updateStack.js:117:35)
     From previous event:
         at AwsDeploy.updateStack (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/lib/updateStack.js:113:33)
     From previous event:
         at AwsDeploy.BbPromise.bind.then (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/deploy/index.js:127:39)
     From previous event:
         at Object.aws:deploy:deploy:updateStack [as hook] (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/deploy/index.js:123:30)
         at BbPromise.reduce (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:489:55)
     From previous event:
         at PluginManager.invoke (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:489:22)
         at PluginManager.spawn (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:509:17)
         at AwsDeploy.BbPromise.bind.then (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/deploy/index.js:93:48)
     From previous event:
         at Object.deploy:deploy [as hook] (/home/jake/.config/yarn/global/node_modules/serverless/lib/plugins/aws/deploy/index.js:89:30)
         at BbPromise.reduce (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:489:55)
     From previous event:
         at PluginManager.invoke (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:489:22)
         at getHooks.reduce.then (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:524:24)
     From previous event:
         at PluginManager.run (/home/jake/.config/yarn/global/node_modules/serverless/lib/classes/PluginManager.js:524:8)
         at variables.populateService.then (/home/jake/.config/yarn/global/node_modules/serverless/lib/Serverless.js:115:33)
         at runCallback (timers.js:705:18)
         at tryOnImmediate (timers.js:676:5)
         at processImmediate (timers.js:658:5)
         at process.topLevelDomainCallback (domain.js:126:23)
     From previous event:
         at Serverless.run (/home/jake/.config/yarn/global/node_modules/serverless/lib/Serverless.js:102:74)
         at serverless.init.then (/home/jake/.config/yarn/global/node_modules/serverless/bin/serverless.js:72:30)
         at /home/jake/.config/yarn/global/node_modules/serverless/node_modules/fs-extra/node_modules/graceful-fs/graceful-fs.js:136:16
         at /home/jake/.config/yarn/global/node_modules/serverless/node_modules/graceful-fs/graceful-fs.js:111:16
         at /home/jake/.config/yarn/global/node_modules/graceful-fs/graceful-fs.js:57:14
         at /home/jake/.config/yarn/global/node_modules/serverless/node_modules/graceful-fs/graceful-fs.js:45:10
         at FSReqWrap.args [as oncomplete] (fs.js:140:20)
     From previous event:
         at initializeErrorReporter.then (/home/jake/.config/yarn/global/node_modules/serverless/bin/serverless.js:72:8)
         at runCallback (timers.js:705:18)
         at tryOnImmediate (timers.js:676:5)
         at processImmediate (timers.js:658:5)
         at process.topLevelDomainCallback (domain.js:126:23)
     From previous event:
         at Object.<anonymous> (/home/jake/.config/yarn/global/node_modules/serverless/bin/serverless.js:61:4)
         at Module._compile (internal/modules/cjs/loader.js:778:30)
         at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
         at Module.load (internal/modules/cjs/loader.js:653:32)
         at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
         at Function.Module._load (internal/modules/cjs/loader.js:585:3)
         at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
         at startup (internal/bootstrap/node.js:283:19)
         at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)
     
     Get Support --------------------------------------------
         Docs:          docs.serverless.com
         Bugs:          github.com/serverless/serverless/issues
         Issues:        forum.serverless.com
     
     Your Environment Information ---------------------------
         Operating System:          linux
         Node Version:              10.16.3
         Framework Version:         1.55.0
         Plugin Version:            3.1.2
         SDK Version:               2.1.2
         Components Core Version:   1.1.2
         Components CLI Version:    1.4.0
    

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions