Failed to create CloudFormation change set: Received malformed response
Hi,
When I publish my aws lambda function I have a final error with this:
Uploading to S3. (Bucket: wtbucketlambda Key: WT-serverless-xxxxxx.template) ... Progress: 100% Found existing stack: True CloudFormation change set created ... Waiting for change set to be reviewed Failed to create CloudFormation change set: Received malformed response from transform AWS::Serverless-2016-10-31 Failed to publish AWS Serverless application
Do you know how can I fix it?
It's a big issue because I can't publish my lambda function
Thanks,
My serverless template:
`{ "AWSTemplateFormatVersion" : "2010-09-09", "Transform" : "AWS::Serverless-2016-10-31", "Description" : "Starting template for an AWS Serverless Application.", "Resources" : { "DefaultFunction" : { "Type" : "AWS::Serverless::Function", "Properties": { "Handler": "not_required_for_custom_runtime", "Runtime": "provided", "CodeUri": "", "Description": "Default function", "MemorySize": 256, "Timeout": 30, "Role": null, "Policies": [ "AWSLambdaFullAccess", "AmazonSSMReadOnlyAccess", "AWSLambdaVPCAccessExecutionRole" ], "Events": { "ProxyResource": { "Type": "Api", "Properties": { "Path": "/{proxy+}", "Method": "ANY" } }, "APIWarmingSchedule": { "Type": "Schedule", "Properties": { "Schedule": "rate(5 minutes)", "Input": "{ "Resource": "WarmingLambda", "Body": "5" }" } } } } } }, "Outputs" : { "ApiURL" : { "Description" : "API endpoint URL for Prod environment", "Value" : { "Fn::Sub" : "https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/" } }
} }`
My aws lambda tools default json file
{ "region" : "us-east-1", "profile" : "wetip", "s3-bucket" : "wtbucketlambda", "template" : "serverless.template", "stack-name" : "WT", "configuration" : "Release", "framework" : "netcoreapp2.2", "msbuild-parameters" : "--self-contained true" }
I have the same issue.
My template:
{
"AWSTemplateFormatVersion":"2010-09-09",
"Transform":"AWS::Serverless-2016-10-31",
"Description":"An AWS Serverless Application that uses the ASP.NET Core framework running in Amazon Lambda.",
"Parameters":{
"ShouldCreateBucket":{
"Type":"String",
"AllowedValues":[
"true",
"false"
],
"Description":"If true then the S3 bucket that will be proxied will be created with the CloudFormation stack."
},
"BucketName":{
"Type":"String",
"Description":"Name of S3 bucket that will be proxied. If left blank a name will be generated.",
"MinLength":"0"
}
},
"Conditions":{
"CreateS3Bucket":{
"Fn::Equals":[
{
"Ref":"ShouldCreateBucket"
},
"true"
]
},
"BucketNameGenerated":{
"Fn::Equals":[
{
"Ref":"BucketName"
},
""
]
}
},
"Resources":{
"AspNetCoreFunction":{
"Type":"AWS::Serverless::Function",
"Properties":{
"Handler":"xxx::xxx.LambdaEntryPoint::FunctionHandlerAsync",
"Runtime":"dotnetcore3.1",
"CodeUri":"s3://xxx/xxx/AspNetCoreFunction-CodeUri-637343401555849743-637343401710605189.zip",
"MemorySize":256,
"Timeout":30,
"Role":null,
"Policies":[
"AWSLambdaFullAccess"
],
"Environment":{
"Variables":{
"AppS3Bucket":{
"Fn::If":[
"CreateS3Bucket",
{
"Ref":"Bucket"
},
{
"Ref":"BucketName"
}
]
}
}
},
"Events":{
"ProxyResource":{
"Type":"Api",
"Properties":{
"Path":"/{proxy+}",
"Method":"ANY"
}
},
"RootResource":{
"Type":"Api",
"Properties":{
"Path":"/",
"Method":"ANY"
}
}
}
}
},
"Bucket":{
"Type":"AWS::S3::Bucket",
"Condition":"CreateS3Bucket",
"Properties":{
"BucketName":{
"Fn::If":[
"BucketNameGenerated",
{
"Ref":"AWS::NoValue"
},
{
"Ref":"BucketName"
}
]
}
}
}
},
"Outputs":{
"ApiURL":{
"Description":"API endpoint URL for Prod environment",
"Value":{
"Fn::Sub":"https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/"
}
},
"S3ProxyBucket":{
"Value":{
"Fn::If":[
"CreateS3Bucket",
{
"Ref":"Bucket"
},
{
"Ref":"BucketName"
}
]
}
}
}
}
Having the same issue for the last a few hours. It was working yesterday with the same template. The thing is, that's a template deploying a DynamoDB table. No lambdas. I just saw this thread and wanted to say that this may be a more general issue unrelated to lambda
Same for me for a template that is unchanged and was working previously, so this looks like a regression.
I'm facing the same issue too. However, the aws health check dashboard does not show any indicators for service disruptions in us-east-1. https://status.aws.amazon.com/ Is everyone seeing this issue in us-east-1?
An older thread of similar issue which was due to aws service being down. https://github.com/aws/serverless-application-model/issues/793
This seems to be fixed now !
Hi @dalton5,
Good morning.
Per comment from @NithuPMTR, please verify if this works now for you and confirm if this issue could be closed.
Thanks, Ashish
It works for me now.
Yes it works. You can close. thanks
⚠️COMMENT VISIBILITY WARNING⚠️
Comments on closed issues are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so.
same issue again..
same issue again..
I confirm, same issue when trying to deploy app stack to us-east-1 :/
Can confirm as well
Can confirm as well, same issue
Same issue here
Same issue here us-east-1
Received malformed response from transform AWS::Serverless-2016-10-31
Deploying to us-east-1
Seeing the same issue.
Same here: us-east-1
Same issue here trying to deploy in us-east
same here :(