-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Labels
Description
Description:
sam validate relies on cfn-lint. SAM currently uses 1.20.1. Current version with up to date CloudFormation schema is 1.22.4. Example use case is adding the new PointInTimeRecoverySpecification.RecoveryPeriodInDays property to a DynamoDB table resource. cfn-lint 1.22.4 validates the template. SAM 1.132.0 doesn't, giving the following error message (generated mostly by the out of date cfn-lint):
[[E3002: Resource properties are invalid] (Additional properties are not allowed ('RecoveryPeriodInDays' was unexpected)) matched 151]
Error: Linting failed. At least one linting rule was matched to the provided template.
#7827 Did not resolve the issue.
Steps to reproduce:
Add the following resource to an otherwise valid SAM template:
table:
Type: "AWS::DynamoDB::Table"
Properties:
TableName: "MyTable"
AttributeDefinitions:
- AttributeName: "pk"
AttributeType: "S"
KeySchema:
- AttributeName: "pk"
KeyType: "HASH"
PointInTimeRecoverySpecification:
PointInTimeRecoveryEnabled: true
RecoveryPeriodInDays: 7Run sam validate.
Observed result:
Error message.
Expected result:
Passing validation.
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
{
"version": "1.133.0",
"system": {
"python": "3.11.10",
"os": "macOS-15.3-x86_64-i386-64bit"
},
"additional_dependencies": {
"docker_engine": "Not available",
"aws_cdk": "2.26.0 (build a409d63)",
"terraform": "1.10.5"
},
"available_beta_feature_env_vars": [
"SAM_CLI_BETA_FEATURES",
"SAM_CLI_BETA_BUILD_PERFORMANCE",
"SAM_CLI_BETA_TERRAFORM_SUPPORT",
"SAM_CLI_BETA_RUST_CARGO_LAMBDA"
]
}Reactions are currently unavailable