From 8a911d5e08bda3ac8763c8c4b2af1f53ad760e49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sun, 21 Mar 2021 12:39:00 +0100 Subject: [PATCH 01/10] Run '2to3 -n -w --no-diffs .' --- examples/ApiGateway.py | 2 +- examples/ApplicationAutoScalingSample.py | 2 +- examples/ApplicationELB.py | 2 +- examples/ApplicationLB_FixedActions.py | 2 +- .../AuroraServerlessRDS_SecretsManager.py | 2 +- examples/Autoscaling.py | 2 +- examples/AutoscalingHTTPRequests.py | 2 +- examples/Backup.py | 2 +- examples/Batch.py | 2 +- examples/CertificateManagerSample.py | 2 +- examples/ClassExtensions.py | 2 +- examples/CloudFormation_Init_ConfigSet.py | 2 +- examples/CloudFront_Distribution_S3.py | 2 +- .../CloudFront_StreamingDistribution_S3.py | 2 +- examples/CloudTrail.py | 2 +- examples/CloudWatchEventsSample.py | 2 +- examples/CodeBuild.py | 2 +- examples/CodeDeploy.py | 2 +- examples/CodePipeline.py | 2 +- examples/CustomResource.py | 6 +- examples/Dlm.py | 2 +- examples/DynamoDB_Table.py | 2 +- ...ith_GSI_And_NonKeyAttributes_Projection.py | 2 +- ...ynamoDB_Table_With_GlobalSecondaryIndex.py | 2 +- examples/DynamoDB_Tables_OnDemand.py | 2 +- examples/EC2Conditions.py | 6 +- examples/EC2InstanceSample.py | 2 +- examples/EC2_Remove_Ephemeral_Drive.py | 2 +- examples/ECRSample.py | 2 +- examples/ECSCluster.py | 2 +- examples/ECSFargate.py | 2 +- examples/EFS.py | 2 +- examples/ELBSample.py | 2 +- examples/EMR_Cluster.py | 2 +- examples/ElastiCacheRedis.py | 2 +- examples/ElasticBeanstalk_Nodejs_Sample.py | 2 +- examples/ElasticsearchDomain.py | 2 +- examples/Firehose_with_Redshift.py | 2 +- examples/IAM_Policies_SNS_Publish_To_SQS.py | 2 +- examples/IAM_Roles_and_InstanceProfiles.py | 2 +- examples/IAM_Users_Groups_and_Policies.py | 2 +- examples/IAM_Users_snippet.py | 2 +- examples/IoTAnalytics.py | 2 +- examples/IoTSample.py | 2 +- examples/Kinesis_Stream.py | 2 +- examples/Lambda.py | 46 +- examples/Metadata.py | 2 +- examples/MskCluster.py | 2 +- examples/NatGateway.py | 2 +- examples/NetworkLB.py | 2 +- examples/OpenStack_AutoScaling.py | 2 +- examples/OpenStack_Server.py | 2 +- examples/OpsWorksSnippet.py | 2 +- examples/RDS_Snapshot_On_Delete.py | 2 +- examples/RDS_VPC.py | 2 +- examples/RDS_with_DBParameterGroup.py | 2 +- examples/Redshift.py | 2 +- examples/RedshiftClusterInVpc.py | 2 +- examples/Route53_A.py | 2 +- examples/Route53_CNAME.py | 2 +- examples/Route53_RoundRobin.py | 2 +- examples/S3_Bucket.py | 2 +- .../S3_Bucket_With_AccelerateConfiguration.py | 2 +- ...ket_With_Versioning_And_Lifecycle_Rules.py | 2 +- ...S3_Website_Bucket_With_Retain_On_Delete.py | 2 +- examples/SQSDLQ.py | 2 +- examples/SQSEncrypt.py | 2 +- examples/SQS_With_CloudWatch_Alarms.py | 2 +- examples/SSMExample.py | 2 +- examples/Secretsmanager.py | 2 +- examples/Secretsmanager_Rds.py | 2 +- examples/Serverless_Api_Backend.py | 2 +- examples/Serverless_Deployment_Preference.py | 2 +- examples/Serverless_S3_Processor.py | 2 +- ...tance_With_Multiple_Dynamic_IPAddresses.py | 2 +- examples/VPC_With_VPN_Connection.py | 2 +- examples/VPC_single_instance_in_subnet.py | 2 +- examples/VpnEndpoint.py | 2 +- examples/WAF_Common_Attacks_Sample.py | 2 +- .../WAF_Regional_Common_Attacks_Sample.py | 2 +- examples/WaitObject.py | 2 +- scripts/gen.py | 2 +- setup.py | 4 +- tests/test_appsync.py | 2 +- tests/test_basic.py | 12 +- tests/test_cloudwatch.py | 4 +- tests/test_codebuild.py | 6 +- tests/test_codecommit.py | 4 +- tests/test_dict.py | 10 +- tests/test_examples.py | 6 +- tests/test_examples_template_generator.py | 4 +- tests/test_int_type.py | 2 +- tests/test_rds.py | 32 +- tests/test_template_generator.py | 10 +- troposphere/__init__.py | 59 +- troposphere/accessanalyzer.py | 14 +- troposphere/acmpca.py | 102 +-- troposphere/amazonmq.py | 86 +-- troposphere/amplify.py | 64 +- troposphere/analytics.py | 66 +- troposphere/apigateway.py | 228 +++--- troposphere/apigatewayv2.py | 166 ++--- troposphere/appconfig.py | 52 +- troposphere/appflow.py | 242 +++--- troposphere/applicationautoscaling.py | 48 +- troposphere/applicationinsights.py | 48 +- troposphere/appmesh.py | 158 ++-- troposphere/appstream.py | 100 +-- troposphere/appsync.py | 136 ++-- troposphere/ask.py | 16 +- troposphere/athena.py | 24 +- troposphere/auditmanager.py | 24 +- troposphere/autoscaling.py | 144 ++-- troposphere/autoscalingplans.py | 34 +- troposphere/awslambda.py | 126 ++-- troposphere/backup.py | 32 +- troposphere/batch.py | 100 +-- troposphere/budgets.py | 22 +- troposphere/cassandra.py | 10 +- troposphere/ce.py | 26 +- troposphere/certificatemanager.py | 16 +- troposphere/chatbot.py | 12 +- troposphere/cloud9.py | 14 +- troposphere/cloudformation.py | 108 +-- troposphere/cloudfront.py | 146 ++-- troposphere/cloudtrail.py | 20 +- troposphere/cloudwatch.py | 76 +- troposphere/codeartifact.py | 16 +- troposphere/codebuild.py | 114 +-- troposphere/codecommit.py | 22 +- troposphere/codedeploy.py | 68 +- troposphere/codeguruprofiler.py | 8 +- troposphere/codegurureviewer.py | 8 +- troposphere/codepipeline.py | 80 +- troposphere/codestar.py | 14 +- troposphere/codestarconnections.py | 4 +- troposphere/codestarnotifications.py | 14 +- troposphere/cognito.py | 240 +++--- troposphere/config.py | 134 ++-- troposphere/databrew.py | 258 +++---- troposphere/datapipeline.py | 28 +- troposphere/datasync.py | 110 +-- troposphere/dax.py | 32 +- troposphere/detective.py | 8 +- troposphere/devopsguru.py | 4 +- troposphere/directoryservice.py | 22 +- troposphere/dlm.py | 22 +- troposphere/dms.py | 176 ++--- troposphere/docdb.py | 48 +- troposphere/dynamodb.py | 20 +- troposphere/ec2.py | 698 +++++++++--------- troposphere/ecr.py | 14 +- troposphere/ecs.py | 206 +++--- troposphere/efs.py | 36 +- troposphere/eks.py | 70 +- troposphere/elasticache.py | 118 +-- troposphere/elasticbeanstalk.py | 54 +- troposphere/elasticloadbalancing.py | 26 +- troposphere/elasticloadbalancingv2.py | 128 ++-- troposphere/elasticsearch.py | 32 +- troposphere/emr.py | 176 ++--- troposphere/emrcontainers.py | 8 +- troposphere/events.py | 104 +-- troposphere/eventschemas.py | 22 +- troposphere/firehose.py | 112 +-- troposphere/fis.py | 8 +- troposphere/fms.py | 14 +- troposphere/fsx.py | 46 +- troposphere/gamelift.py | 118 +-- troposphere/globalaccelerator.py | 14 +- troposphere/glue.py | 270 +++---- troposphere/greengrass.py | 138 ++-- troposphere/greengrassv2.py | 30 +- troposphere/groundstation.py | 38 +- troposphere/guardduty.py | 46 +- troposphere/iam.py | 74 +- troposphere/imagebuilder.py | 108 +-- troposphere/inspector.py | 10 +- troposphere/iot.py | 294 ++++---- troposphere/iot1click.py | 10 +- troposphere/iotanalytics.py | 126 ++-- troposphere/iotevents.py | 52 +- troposphere/iotsitewise.py | 94 +-- troposphere/iotwireless.py | 82 +- troposphere/ivs.py | 12 +- troposphere/kendra.py | 204 ++--- troposphere/kinesis.py | 10 +- troposphere/kinesisanalyticsv2.py | 80 +- troposphere/kms.py | 8 +- troposphere/lakeformation.py | 22 +- troposphere/licensemanager.py | 44 +- troposphere/logs.py | 32 +- troposphere/lookoutvision.py | 2 +- troposphere/macie.py | 14 +- troposphere/managedblockchain.py | 32 +- troposphere/mediaconnect.py | 96 +-- troposphere/mediaconvert.py | 26 +- troposphere/medialive.py | 86 +-- troposphere/mediapackage.py | 68 +- troposphere/mediastore.py | 18 +- troposphere/msk.py | 30 +- troposphere/neptune.py | 56 +- troposphere/networkfirewall.py | 60 +- troposphere/networkmanager.py | 60 +- troposphere/openstack/heat.py | 10 +- troposphere/openstack/neutron.py | 102 +-- troposphere/openstack/nova.py | 64 +- troposphere/opsworks.py | 210 +++--- troposphere/pinpoint.py | 268 +++---- troposphere/pinpointemail.py | 34 +- troposphere/policies.py | 6 +- troposphere/qldb.py | 16 +- troposphere/quicksight.py | 114 +-- troposphere/ram.py | 6 +- troposphere/rds.py | 214 +++--- troposphere/redshift.py | 62 +- troposphere/resourcegroups.py | 12 +- troposphere/robomaker.py | 44 +- troposphere/route53.py | 110 +-- troposphere/s3.py | 166 ++--- troposphere/s3objectlambda.py | 10 +- troposphere/s3outposts.py | 24 +- troposphere/sagemaker.py | 338 ++++----- troposphere/secretsmanager.py | 42 +- troposphere/serverless.py | 182 ++--- troposphere/servicecatalog.py | 166 ++--- troposphere/servicecatalogappregistry.py | 18 +- troposphere/servicediscovery.py | 36 +- troposphere/ses.py | 84 +-- troposphere/sns.py | 18 +- troposphere/sqs.py | 6 +- troposphere/ssm.py | 144 ++-- troposphere/sso.py | 30 +- troposphere/stepfunctions.py | 20 +- troposphere/synthetics.py | 26 +- troposphere/template_generator.py | 22 +- troposphere/timestream.py | 8 +- troposphere/transfer.py | 42 +- troposphere/utils.py | 2 +- troposphere/validators.py | 2 +- troposphere/waf.py | 48 +- troposphere/wafregional.py | 68 +- troposphere/wafv2.py | 74 +- troposphere/workspaces.py | 14 +- 244 files changed, 5739 insertions(+), 5740 deletions(-) diff --git a/examples/ApiGateway.py b/examples/ApiGateway.py index ddad9163a..30c60bd5e 100644 --- a/examples/ApiGateway.py +++ b/examples/ApiGateway.py @@ -187,4 +187,4 @@ ), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ApplicationAutoScalingSample.py b/examples/ApplicationAutoScalingSample.py index afd6db91e..e6df2336e 100644 --- a/examples/ApplicationAutoScalingSample.py +++ b/examples/ApplicationAutoScalingSample.py @@ -42,4 +42,4 @@ t.add_resource(scalable_target) t.add_resource(scaling_policy) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ApplicationELB.py b/examples/ApplicationELB.py index d2a0434dc..b4868ce34 100644 --- a/examples/ApplicationELB.py +++ b/examples/ApplicationELB.py @@ -206,7 +206,7 @@ def main(): Value=Join("", ["http://", GetAtt(ApplicationElasticLB, "DNSName")]) )) - print(template.to_json()) + print((template.to_json())) if __name__ == '__main__': diff --git a/examples/ApplicationLB_FixedActions.py b/examples/ApplicationLB_FixedActions.py index b19078bc8..6e43127df 100644 --- a/examples/ApplicationLB_FixedActions.py +++ b/examples/ApplicationLB_FixedActions.py @@ -158,7 +158,7 @@ def main(): ] ) - print(template.to_json()) + print((template.to_json())) if __name__ == '__main__': diff --git a/examples/AuroraServerlessRDS_SecretsManager.py b/examples/AuroraServerlessRDS_SecretsManager.py index 65585d8bd..28553839b 100644 --- a/examples/AuroraServerlessRDS_SecretsManager.py +++ b/examples/AuroraServerlessRDS_SecretsManager.py @@ -129,4 +129,4 @@ ]) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Autoscaling.py b/examples/Autoscaling.py index b9114d685..b751d935a 100644 --- a/examples/Autoscaling.py +++ b/examples/Autoscaling.py @@ -241,4 +241,4 @@ ) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/AutoscalingHTTPRequests.py b/examples/AutoscalingHTTPRequests.py index 04071f78a..90e8ce1aa 100644 --- a/examples/AutoscalingHTTPRequests.py +++ b/examples/AutoscalingHTTPRequests.py @@ -270,4 +270,4 @@ AlarmActions=[Ref(ScalePolicy)] )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Backup.py b/examples/Backup.py index 7a00dbfb9..6db14b7f5 100644 --- a/examples/Backup.py +++ b/examples/Backup.py @@ -94,4 +94,4 @@ ) ) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/Batch.py b/examples/Batch.py index 49b8b68f5..7eda0bdc6 100644 --- a/examples/Batch.py +++ b/examples/Batch.py @@ -118,4 +118,4 @@ Output('ExampleJobQueue', Value=Ref(ExampleJobQueue)) ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CertificateManagerSample.py b/examples/CertificateManagerSample.py index b91bae335..a9403f397 100644 --- a/examples/CertificateManagerSample.py +++ b/examples/CertificateManagerSample.py @@ -22,4 +22,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ClassExtensions.py b/examples/ClassExtensions.py index 6a12e27fe..5e9549870 100644 --- a/examples/ClassExtensions.py +++ b/examples/ClassExtensions.py @@ -22,4 +22,4 @@ class ProcessingInstance(TrustyInstance): template.add_resource(FrontendInstance('jones1')) template.add_resource(ProcessingInstance('williams1', InstanceType="m2.large")) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/CloudFormation_Init_ConfigSet.py b/examples/CloudFormation_Init_ConfigSet.py index 507d9987d..76b13fe6e 100644 --- a/examples/CloudFormation_Init_ConfigSet.py +++ b/examples/CloudFormation_Init_ConfigSet.py @@ -94,4 +94,4 @@ Value=GetAtt(ec2_instance, 'PublicIp') )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CloudFront_Distribution_S3.py b/examples/CloudFront_Distribution_S3.py index 17b1849f1..6cb19d7fb 100644 --- a/examples/CloudFront_Distribution_S3.py +++ b/examples/CloudFront_Distribution_S3.py @@ -49,4 +49,4 @@ Value=Join("", ["http://", GetAtt(myDistribution, "DomainName")])), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CloudFront_StreamingDistribution_S3.py b/examples/CloudFront_StreamingDistribution_S3.py index d00e0dc33..c7ac513bc 100644 --- a/examples/CloudFront_StreamingDistribution_S3.py +++ b/examples/CloudFront_StreamingDistribution_S3.py @@ -45,4 +45,4 @@ Value=Join("", ["http://", GetAtt(myDistribution, "DomainName")])), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CloudTrail.py b/examples/CloudTrail.py index 850e5ce2d..2d83a60a1 100644 --- a/examples/CloudTrail.py +++ b/examples/CloudTrail.py @@ -93,4 +93,4 @@ DependsOn=["BucketPolicy", "TopicPolicy"], )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CloudWatchEventsSample.py b/examples/CloudWatchEventsSample.py index 5ff52f2be..c05387c06 100644 --- a/examples/CloudWatchEventsSample.py +++ b/examples/CloudWatchEventsSample.py @@ -64,4 +64,4 @@ SourceArn=GetAtt(rule, 'Arn') )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CodeBuild.py b/examples/CodeBuild.py index 02a351a12..e3114e15d 100644 --- a/examples/CodeBuild.py +++ b/examples/CodeBuild.py @@ -29,4 +29,4 @@ ) template.add_resource(project) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/CodeDeploy.py b/examples/CodeDeploy.py index 5c5fd86b4..acb2fdcb3 100644 --- a/examples/CodeDeploy.py +++ b/examples/CodeDeploy.py @@ -93,4 +93,4 @@ ) template.add_resource(deployment_group_on_premises) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/CodePipeline.py b/examples/CodePipeline.py index e13743f03..7e83d37d5 100644 --- a/examples/CodePipeline.py +++ b/examples/CodePipeline.py @@ -112,4 +112,4 @@ )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/CustomResource.py b/examples/CustomResource.py index e447d038f..49c82fa2d 100644 --- a/examples/CustomResource.py +++ b/examples/CustomResource.py @@ -6,8 +6,8 @@ class CustomPlacementGroup(AWSCustomObject): resource_type = "Custom::PlacementGroup" props = { - 'ServiceToken': (basestring, True), - 'PlacementGroupName': (basestring, True) + 'ServiceToken': (str, True), + 'PlacementGroupName': (str, True) } @@ -28,4 +28,4 @@ class CustomPlacementGroup(AWSCustomObject): PlacementGroupName="ExampleClusterGroup", )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Dlm.py b/examples/Dlm.py index b2155d074..ab92226d3 100644 --- a/examples/Dlm.py +++ b/examples/Dlm.py @@ -55,4 +55,4 @@ ) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/DynamoDB_Table.py b/examples/DynamoDB_Table.py index 22be0a4e6..05be42fc4 100755 --- a/examples/DynamoDB_Table.py +++ b/examples/DynamoDB_Table.py @@ -78,4 +78,4 @@ Description="Table name of the newly create DynamoDB table", )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py b/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py index b19f4584e..77eff562d 100644 --- a/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py +++ b/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py @@ -173,4 +173,4 @@ )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py b/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py index ec4ee37b4..e319aff6f 100644 --- a/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py +++ b/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py @@ -162,4 +162,4 @@ )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/DynamoDB_Tables_OnDemand.py b/examples/DynamoDB_Tables_OnDemand.py index 291116d63..1ea910c30 100644 --- a/examples/DynamoDB_Tables_OnDemand.py +++ b/examples/DynamoDB_Tables_OnDemand.py @@ -226,4 +226,4 @@ )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/EC2Conditions.py b/examples/EC2Conditions.py index c79164258..c36892815 100644 --- a/examples/EC2Conditions.py +++ b/examples/EC2Conditions.py @@ -1,4 +1,4 @@ -from __future__ import print_function + from troposphere import ( Template, Parameter, Ref, Condition, Equals, And, Or, Not, If @@ -88,11 +88,11 @@ t = Template() -for p in parameters.values(): +for p in list(parameters.values()): t.add_parameter(p) for k in conditions: t.add_condition(k, conditions[k]) -for r in resources.values(): +for r in list(resources.values()): t.add_resource(r) print(t.to_json()) diff --git a/examples/EC2InstanceSample.py b/examples/EC2InstanceSample.py index 8c8b9b3e5..a73f1d857 100644 --- a/examples/EC2InstanceSample.py +++ b/examples/EC2InstanceSample.py @@ -67,4 +67,4 @@ ), ]) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/EC2_Remove_Ephemeral_Drive.py b/examples/EC2_Remove_Ephemeral_Drive.py index 28dba5546..989cea119 100644 --- a/examples/EC2_Remove_Ephemeral_Drive.py +++ b/examples/EC2_Remove_Ephemeral_Drive.py @@ -79,4 +79,4 @@ ), ]) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/ECRSample.py b/examples/ECRSample.py index 53d627417..fb87b7b3d 100644 --- a/examples/ECRSample.py +++ b/examples/ECRSample.py @@ -36,4 +36,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ECSCluster.py b/examples/ECSCluster.py index 0dbffdb5e..874f1b9ca 100644 --- a/examples/ECSCluster.py +++ b/examples/ECSCluster.py @@ -170,4 +170,4 @@ }]} )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ECSFargate.py b/examples/ECSFargate.py index f416add47..69f865d48 100644 --- a/examples/ECSFargate.py +++ b/examples/ECSFargate.py @@ -46,4 +46,4 @@ ) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/EFS.py b/examples/EFS.py index f8117d9d8..0dfbb2403 100644 --- a/examples/EFS.py +++ b/examples/EFS.py @@ -128,4 +128,4 @@ # for example: # mount us-west-1a.fs-abcd1234.efs.us-west-1.amazonaws.com: /path -print(template.to_json()) +print((template.to_json())) diff --git a/examples/ELBSample.py b/examples/ELBSample.py index 5bbfa9894..7ac04256c 100644 --- a/examples/ELBSample.py +++ b/examples/ELBSample.py @@ -129,7 +129,7 @@ def main(): Value=Join("", ["http://", GetAtt(elasticLB, "DNSName")]) )) - print(template.to_json()) + print((template.to_json())) if __name__ == '__main__': diff --git a/examples/EMR_Cluster.py b/examples/EMR_Cluster.py index 28684aa1b..c9ce0e4ea 100644 --- a/examples/EMR_Cluster.py +++ b/examples/EMR_Cluster.py @@ -274,4 +274,4 @@ def generate_rules(rules_name): JobFlowId=Ref(cluster) )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/ElastiCacheRedis.py b/examples/ElastiCacheRedis.py index f9690e2c3..1a3e32fda 100755 --- a/examples/ElastiCacheRedis.py +++ b/examples/ElastiCacheRedis.py @@ -6,7 +6,7 @@ In addition to troposphere, this script requires awacs (Amazon Web Access Control Subsystem) """ -from __future__ import absolute_import, division, print_function + import troposphere.ec2 as ec2 import troposphere.elasticache as elasticache diff --git a/examples/ElasticBeanstalk_Nodejs_Sample.py b/examples/ElasticBeanstalk_Nodejs_Sample.py index c38ac086f..14742f775 100644 --- a/examples/ElasticBeanstalk_Nodejs_Sample.py +++ b/examples/ElasticBeanstalk_Nodejs_Sample.py @@ -159,4 +159,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/ElasticsearchDomain.py b/examples/ElasticsearchDomain.py index 232688ba3..a64dc09c1 100644 --- a/examples/ElasticsearchDomain.py +++ b/examples/ElasticsearchDomain.py @@ -43,4 +43,4 @@ ) )) -print(templ.to_json()) +print((templ.to_json())) diff --git a/examples/Firehose_with_Redshift.py b/examples/Firehose_with_Redshift.py index b75abdb17..6ecf6ee71 100644 --- a/examples/Firehose_with_Redshift.py +++ b/examples/Firehose_with_Redshift.py @@ -56,4 +56,4 @@ ) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IAM_Policies_SNS_Publish_To_SQS.py b/examples/IAM_Policies_SNS_Publish_To_SQS.py index 5ee789891..66749bb8a 100644 --- a/examples/IAM_Policies_SNS_Publish_To_SQS.py +++ b/examples/IAM_Policies_SNS_Publish_To_SQS.py @@ -48,4 +48,4 @@ } )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IAM_Roles_and_InstanceProfiles.py b/examples/IAM_Roles_and_InstanceProfiles.py index 0a1ab8cc8..c3177d715 100644 --- a/examples/IAM_Roles_and_InstanceProfiles.py +++ b/examples/IAM_Roles_and_InstanceProfiles.py @@ -29,4 +29,4 @@ Roles=[Ref(cfnrole)] )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IAM_Users_Groups_and_Policies.py b/examples/IAM_Users_Groups_and_Policies.py index 15e7f31d6..8acf7c7a8 100644 --- a/examples/IAM_Users_Groups_and_Policies.py +++ b/examples/IAM_Users_Groups_and_Policies.py @@ -67,4 +67,4 @@ Description="AWSSecretKey of new user", )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IAM_Users_snippet.py b/examples/IAM_Users_snippet.py index b994f27d6..d08687788 100644 --- a/examples/IAM_Users_snippet.py +++ b/examples/IAM_Users_snippet.py @@ -53,4 +53,4 @@ ] )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IoTAnalytics.py b/examples/IoTAnalytics.py index c9d46437a..13916e2f1 100644 --- a/examples/IoTAnalytics.py +++ b/examples/IoTAnalytics.py @@ -123,4 +123,4 @@ t.add_resource(datastore) t.add_resource(dataset) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/IoTSample.py b/examples/IoTSample.py index 7bf78e053..b8a8149f0 100644 --- a/examples/IoTSample.py +++ b/examples/IoTSample.py @@ -79,4 +79,4 @@ t.add_resource(thing_principal) t.add_resource(topic_rule) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Kinesis_Stream.py b/examples/Kinesis_Stream.py index 9c13466e4..0fb72cb25 100644 --- a/examples/Kinesis_Stream.py +++ b/examples/Kinesis_Stream.py @@ -20,4 +20,4 @@ ), ]) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/Lambda.py b/examples/Lambda.py index f6a2f57ef..36e67f4d9 100644 --- a/examples/Lambda.py +++ b/examples/Lambda.py @@ -49,31 +49,31 @@ )) t.add_mapping("AWSInstanceType2Arch", - {u'm1.small': {u'Arch': u'PV64'}, - u't2.micro': {u'Arch': u'HVM64'}} + {'m1.small': {'Arch': 'PV64'}, + 't2.micro': {'Arch': 'HVM64'}} ) t.add_mapping("AWSRegionArch2AMI", - {u'ap-northeast-1': {u'HVM64': u'ami-cbf90ecb', - u'PV64': u'ami-27f90e27'}, - u'ap-southeast-1': {u'HVM64': u'ami-68d8e93a', - u'PV64': u'ami-acd9e8fe'}, - u'ap-southeast-2': {u'HVM64': u'ami-fd9cecc7', - u'PV64': u'ami-ff9cecc5'}, - u'cn-north-1': {u'HVM64': u'ami-f239abcb', - u'PV64': u'ami-fa39abc3'}, - u'eu-central-1': {u'HVM64': u'ami-a8221fb5', - u'PV64': u'ami-ac221fb1'}, - u'eu-west-1': {u'HVM64': u'ami-a10897d6', - u'PV64': u'ami-bf0897c8'}, - u'sa-east-1': {u'HVM64': u'ami-b52890a8', - u'PV64': u'ami-bb2890a6'}, - u'us-east-1': {u'HVM64': u'ami-1ecae776', - u'PV64': u'ami-1ccae774'}, - u'us-west-1': {u'HVM64': u'ami-d114f295', - u'PV64': u'ami-d514f291'}, - u'us-west-2': {u'HVM64': u'ami-e7527ed7', - u'PV64': u'ami-ff527ecf'}} + {'ap-northeast-1': {'HVM64': 'ami-cbf90ecb', + 'PV64': 'ami-27f90e27'}, + 'ap-southeast-1': {'HVM64': 'ami-68d8e93a', + 'PV64': 'ami-acd9e8fe'}, + 'ap-southeast-2': {'HVM64': 'ami-fd9cecc7', + 'PV64': 'ami-ff9cecc5'}, + 'cn-north-1': {'HVM64': 'ami-f239abcb', + 'PV64': 'ami-fa39abc3'}, + 'eu-central-1': {'HVM64': 'ami-a8221fb5', + 'PV64': 'ami-ac221fb1'}, + 'eu-west-1': {'HVM64': 'ami-a10897d6', + 'PV64': 'ami-bf0897c8'}, + 'sa-east-1': {'HVM64': 'ami-b52890a8', + 'PV64': 'ami-bb2890a6'}, + 'us-east-1': {'HVM64': 'ami-1ecae776', + 'PV64': 'ami-1ccae774'}, + 'us-west-1': {'HVM64': 'ami-d114f295', + 'PV64': 'ami-d514f291'}, + 'us-west-2': {'HVM64': 'ami-e7527ed7', + 'PV64': 'ami-ff527ecf'}} ) code = [ @@ -156,4 +156,4 @@ Value=Join(", ", GetAtt(AllSecurityGroups, "Value")), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Metadata.py b/examples/Metadata.py index cf9906da9..14bac7858 100644 --- a/examples/Metadata.py +++ b/examples/Metadata.py @@ -11,4 +11,4 @@ "Version": "V1.0", }) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/MskCluster.py b/examples/MskCluster.py index b6c1609c1..ba812584a 100644 --- a/examples/MskCluster.py +++ b/examples/MskCluster.py @@ -58,4 +58,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/NatGateway.py b/examples/NatGateway.py index ddee43f70..8cbd74649 100644 --- a/examples/NatGateway.py +++ b/examples/NatGateway.py @@ -120,4 +120,4 @@ Description='Nat Elastic IP', )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/NetworkLB.py b/examples/NetworkLB.py index fa819f2d2..3f8777b32 100644 --- a/examples/NetworkLB.py +++ b/examples/NetworkLB.py @@ -165,7 +165,7 @@ def main(): Value=Join("", ["http://", GetAtt(NetworkLB, "DNSName")]) )) - print(template.to_json()) + print((template.to_json())) if __name__ == '__main__': diff --git a/examples/OpenStack_AutoScaling.py b/examples/OpenStack_AutoScaling.py index 82676a8b8..1b2768fb0 100644 --- a/examples/OpenStack_AutoScaling.py +++ b/examples/OpenStack_AutoScaling.py @@ -135,4 +135,4 @@ LoadBalancerNames=Ref(loadbalancer), )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/OpenStack_Server.py b/examples/OpenStack_Server.py index 786485404..aceeb7b03 100644 --- a/examples/OpenStack_Server.py +++ b/examples/OpenStack_Server.py @@ -60,4 +60,4 @@ ])) )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/OpsWorksSnippet.py b/examples/OpsWorksSnippet.py index a5a83deef..06f33e7b1 100644 --- a/examples/OpsWorksSnippet.py +++ b/examples/OpsWorksSnippet.py @@ -182,4 +182,4 @@ }, )) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/RDS_Snapshot_On_Delete.py b/examples/RDS_Snapshot_On_Delete.py index 028231fad..dee2f1522 100644 --- a/examples/RDS_Snapshot_On_Delete.py +++ b/examples/RDS_Snapshot_On_Delete.py @@ -39,4 +39,4 @@ ]), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/RDS_VPC.py b/examples/RDS_VPC.py index 1a2cbd732..f8daa767b 100644 --- a/examples/RDS_VPC.py +++ b/examples/RDS_VPC.py @@ -132,4 +132,4 @@ ]) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/RDS_with_DBParameterGroup.py b/examples/RDS_with_DBParameterGroup.py index 732f86e3c..3c5af5821 100644 --- a/examples/RDS_with_DBParameterGroup.py +++ b/examples/RDS_with_DBParameterGroup.py @@ -60,4 +60,4 @@ DBParameterGroupName=Ref(myrdsparamgroup), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Redshift.py b/examples/Redshift.py index 070970473..5833349c4 100644 --- a/examples/Redshift.py +++ b/examples/Redshift.py @@ -111,4 +111,4 @@ GetAtt(redshiftcluster, "Endpoint.Port")]), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/RedshiftClusterInVpc.py b/examples/RedshiftClusterInVpc.py index ba467d910..f9429ea6e 100644 --- a/examples/RedshiftClusterInVpc.py +++ b/examples/RedshiftClusterInVpc.py @@ -156,4 +156,4 @@ GetAtt(redshiftcluster, "Endpoint.Port")]), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Route53_A.py b/examples/Route53_A.py index ba5b89b50..5c3c67b7e 100644 --- a/examples/Route53_A.py +++ b/examples/Route53_A.py @@ -53,4 +53,4 @@ t.add_output(Output("DomainName", Value=Ref(myDNSRecord))) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Route53_CNAME.py b/examples/Route53_CNAME.py index cd1c235f3..b2edcf482 100644 --- a/examples/Route53_CNAME.py +++ b/examples/Route53_CNAME.py @@ -36,4 +36,4 @@ t.add_output(Output("DomainName", Value=Ref(myDNSRecord))) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Route53_RoundRobin.py b/examples/Route53_RoundRobin.py index f6433beb0..72b581b56 100644 --- a/examples/Route53_RoundRobin.py +++ b/examples/Route53_RoundRobin.py @@ -52,4 +52,4 @@ )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/S3_Bucket.py b/examples/S3_Bucket.py index d96121788..8efe23c4f 100644 --- a/examples/S3_Bucket.py +++ b/examples/S3_Bucket.py @@ -22,4 +22,4 @@ Description="Name of S3 bucket to hold website content" )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/S3_Bucket_With_AccelerateConfiguration.py b/examples/S3_Bucket_With_AccelerateConfiguration.py index cef81663a..56286e30d 100644 --- a/examples/S3_Bucket_With_AccelerateConfiguration.py +++ b/examples/S3_Bucket_With_AccelerateConfiguration.py @@ -30,4 +30,4 @@ Description="Name of S3 bucket with s3 transfer acceleration enabled", )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py b/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py index 15593c0c7..af6aebf9d 100644 --- a/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py +++ b/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py @@ -66,4 +66,4 @@ Description="Name of S3 bucket to hold website content" )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/S3_Website_Bucket_With_Retain_On_Delete.py b/examples/S3_Website_Bucket_With_Retain_On_Delete.py index 3b98f8b01..2c4a58afa 100644 --- a/examples/S3_Website_Bucket_With_Retain_On_Delete.py +++ b/examples/S3_Website_Bucket_With_Retain_On_Delete.py @@ -39,4 +39,4 @@ ), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/SQSDLQ.py b/examples/SQSDLQ.py index badc2b5e1..40374f3fd 100644 --- a/examples/SQSDLQ.py +++ b/examples/SQSDLQ.py @@ -46,4 +46,4 @@ ), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/SQSEncrypt.py b/examples/SQSEncrypt.py index 7366d9462..8de7898b8 100644 --- a/examples/SQSEncrypt.py +++ b/examples/SQSEncrypt.py @@ -33,4 +33,4 @@ ) ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/SQS_With_CloudWatch_Alarms.py b/examples/SQS_With_CloudWatch_Alarms.py index 4e4b5961b..e97a57f54 100644 --- a/examples/SQS_With_CloudWatch_Alarms.py +++ b/examples/SQS_With_CloudWatch_Alarms.py @@ -80,4 +80,4 @@ ), ]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/SSMExample.py b/examples/SSMExample.py index 89507d19e..f08a64c40 100644 --- a/examples/SSMExample.py +++ b/examples/SSMExample.py @@ -88,4 +88,4 @@ Value="Redhat TIME_STAMP_VALUE" )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Secretsmanager.py b/examples/Secretsmanager.py index b1d8f4741..4c4badd37 100644 --- a/examples/Secretsmanager.py +++ b/examples/Secretsmanager.py @@ -18,4 +18,4 @@ ) )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Secretsmanager_Rds.py b/examples/Secretsmanager_Rds.py index f3a1f8c5f..7e417b8b6 100644 --- a/examples/Secretsmanager_Rds.py +++ b/examples/Secretsmanager_Rds.py @@ -42,4 +42,4 @@ TargetId=Ref(Instance), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Serverless_Api_Backend.py b/examples/Serverless_Api_Backend.py index 0a7bb12b5..51238dec3 100644 --- a/examples/Serverless_Api_Backend.py +++ b/examples/Serverless_Api_Backend.py @@ -84,4 +84,4 @@ ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Serverless_Deployment_Preference.py b/examples/Serverless_Deployment_Preference.py index 2cfeae422..5b92a6d81 100644 --- a/examples/Serverless_Deployment_Preference.py +++ b/examples/Serverless_Deployment_Preference.py @@ -26,4 +26,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/Serverless_S3_Processor.py b/examples/Serverless_S3_Processor.py index 65e8abbac..ad9cfb29e 100644 --- a/examples/Serverless_S3_Processor.py +++ b/examples/Serverless_S3_Processor.py @@ -35,4 +35,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py b/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py index 933156d01..353c2ef49 100644 --- a/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py +++ b/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py @@ -148,4 +148,4 @@ ), ]) -print(template.to_json()) +print((template.to_json())) diff --git a/examples/VPC_With_VPN_Connection.py b/examples/VPC_With_VPN_Connection.py index 0f51fa3cc..d2f075b21 100644 --- a/examples/VPC_With_VPN_Connection.py +++ b/examples/VPC_With_VPN_Connection.py @@ -212,4 +212,4 @@ Value=Ref(VPC), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/VPC_single_instance_in_subnet.py b/examples/VPC_single_instance_in_subnet.py index 2639f8a95..688cfe495 100644 --- a/examples/VPC_single_instance_in_subnet.py +++ b/examples/VPC_single_instance_in_subnet.py @@ -415,4 +415,4 @@ GetAtt('WebServerInstance', 'PublicIp')]))]) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/VpnEndpoint.py b/examples/VpnEndpoint.py index 48bf13ad9..e89ede2af 100644 --- a/examples/VpnEndpoint.py +++ b/examples/VpnEndpoint.py @@ -33,4 +33,4 @@ ) ) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/WAF_Common_Attacks_Sample.py b/examples/WAF_Common_Attacks_Sample.py index 71c7f0c6a..71afa9f72 100644 --- a/examples/WAF_Common_Attacks_Sample.py +++ b/examples/WAF_Common_Attacks_Sample.py @@ -225,4 +225,4 @@ MetricName=Ref(WebACLName), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/WAF_Regional_Common_Attacks_Sample.py b/examples/WAF_Regional_Common_Attacks_Sample.py index 6abf77594..713d5fcc7 100644 --- a/examples/WAF_Regional_Common_Attacks_Sample.py +++ b/examples/WAF_Regional_Common_Attacks_Sample.py @@ -225,4 +225,4 @@ MetricName=Ref(WebACLName), )) -print(t.to_json()) +print((t.to_json())) diff --git a/examples/WaitObject.py b/examples/WaitObject.py index f6563d2f8..b4e6b1711 100644 --- a/examples/WaitObject.py +++ b/examples/WaitObject.py @@ -39,4 +39,4 @@ ) ]) -print(t.to_json()) +print((t.to_json())) diff --git a/scripts/gen.py b/scripts/gen.py index 0c4df8d1e..789d93605 100644 --- a/scripts/gen.py +++ b/scripts/gen.py @@ -1,6 +1,6 @@ #!/usr/bin/env python -from __future__ import print_function + import argparse import json import yaml diff --git a/setup.py b/setup.py index dfb80395d..b373c79a9 100644 --- a/setup.py +++ b/setup.py @@ -11,8 +11,8 @@ # ---- Future -from __future__ import print_function -from __future__ import with_statement + + # ---- System import os diff --git a/tests/test_appsync.py b/tests/test_appsync.py index 2996b9c1c..8281801fa 100644 --- a/tests/test_appsync.py +++ b/tests/test_appsync.py @@ -4,7 +4,7 @@ class TestAppsyncResolver(unittest.TestCase): def test_resolver_kind_bad_value(self): - with self.assertRaisesRegexp(ValueError, 'Kind must be one of'): + with self.assertRaisesRegex(ValueError, 'Kind must be one of'): Resolver( 'MutationField', DataSourceName='SomeDatasource', diff --git a/tests/test_basic.py b/tests/test_basic.py index 6bdc37642..95d835e94 100644 --- a/tests/test_basic.py +++ b/tests/test_basic.py @@ -217,7 +217,7 @@ def test_noproperty(self): def test_empty_awsproperty_outputs_empty_object(self): t = FakeAWSProperty() d = t.to_dict() - self.assertEquals(len(d), 0) + self.assertEqual(len(d), 0) class TestParameter(unittest.TestCase): @@ -254,17 +254,17 @@ def test_get_or_add_adds(self): t = Template() p = Parameter("param", Type="String", Default="foo") result = t.get_or_add_parameter(p) - self.assertEquals(t.parameters["param"], p) - self.assertEquals(result, p) + self.assertEqual(t.parameters["param"], p) + self.assertEqual(result, p) def test_add_or_get_returns_with_out_adding_duplicate(self): t = Template() p = Parameter("param", Type="String", Default="foo") t.add_parameter(p) result = t.get_or_add_parameter(p) - self.assertEquals(t.parameters["param"], p) - self.assertEquals(result, p) - self.assertEquals(len(t.parameters), 1) + self.assertEqual(t.parameters["param"], p) + self.assertEqual(result, p) + self.assertEqual(len(t.parameters), 1) def test_property_default(self): p = Parameter("param", Type="String", Default="foo") diff --git a/tests/test_cloudwatch.py b/tests/test_cloudwatch.py index 097100527..cfafda2a7 100644 --- a/tests/test_cloudwatch.py +++ b/tests/test_cloudwatch.py @@ -42,14 +42,14 @@ def test_validate_units(self): for unit in cloudwatch.VALID_UNITS: cloudwatch.validate_unit(unit) for bad_unit in ['Minutes', 'Bytes/Minute', 'Bits/Hour', '']: - with self.assertRaisesRegexp(ValueError, "must be one of"): + with self.assertRaisesRegex(ValueError, "must be one of"): cloudwatch.validate_unit(bad_unit) def test_validate_treat_missing_data(self): for value in cloudwatch.VALID_TREAT_MISSING_DATA_TYPES: cloudwatch.validate_treat_missing_data(value) for bad_value in ['exists', 'notMissing', '']: - with self.assertRaisesRegexp(ValueError, "must be one of"): + with self.assertRaisesRegex(ValueError, "must be one of"): cloudwatch.validate_treat_missing_data(bad_value) diff --git a/tests/test_codebuild.py b/tests/test_codebuild.py index 197127a93..bb0cf6e64 100644 --- a/tests/test_codebuild.py +++ b/tests/test_codebuild.py @@ -58,13 +58,13 @@ def test_filter_no_filtergroup(self): def test_filter_not_list(self): match = ", expected " - with self.assertRaisesRegexp(TypeError, match): + with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=42).validate() def test_filter_element_not_a_list(self): wh = codebuild.WebhookFilter match = "is , expected " - with self.assertRaisesRegexp(TypeError, match): + with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=[ [wh(Type="EVENT", Pattern="PULL_REQUEST_CREATED")], "not a list", @@ -74,7 +74,7 @@ def test_filter_element_not_a_list(self): def test_filter_fail(self): wh = codebuild.WebhookFilter match = "" - with self.assertRaisesRegexp(TypeError, match): + with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=[ [wh(Type="EVENT", Pattern="PULL_REQUEST_CREATED")], [wh(Type="EVENT", Pattern="PULL_REQUEST_CREATED")], diff --git a/tests/test_codecommit.py b/tests/test_codecommit.py index 4cb93a7a9..b9a89c9fa 100644 --- a/tests/test_codecommit.py +++ b/tests/test_codecommit.py @@ -27,7 +27,7 @@ def test_trigger(self): 'deleteReference', ] ) - with self.assertRaisesRegexp(ValueError, "Trigger events: all"): + with self.assertRaisesRegex(ValueError, "Trigger events: all"): trigger.to_dict() trigger = cc.Trigger( @@ -36,5 +36,5 @@ def test_trigger(self): 'foobar', ] ) - with self.assertRaisesRegexp(ValueError, "invalid event foobar"): + with self.assertRaisesRegex(ValueError, "invalid event foobar"): trigger.to_dict() diff --git a/tests/test_dict.py b/tests/test_dict.py index 3b4791fea..6c0de6c31 100644 --- a/tests/test_dict.py +++ b/tests/test_dict.py @@ -38,7 +38,7 @@ def setUp(self): def test_valid_data(self): t = Template() cd = ecs.ContainerDefinition.from_dict("mycontainer", self.d) - self.assertEquals(cd.Links[0], "containerA") + self.assertEqual(cd.Links[0], "containerA") td = ecs.TaskDefinition( "taskdef", ContainerDefinitions=[cd], @@ -61,12 +61,12 @@ def test_invalid_sub_property(self): def test_toplevel_helper_fn(self): self.d["Cpu"] = Ref("MyCPU") cd = ecs.ContainerDefinition.from_dict("mycontainer", self.d) - self.assertEquals(cd.Cpu.data, {"Ref": "MyCPU"}) + self.assertEqual(cd.Cpu.data, {"Ref": "MyCPU"}) def test_sub_property_helper_fn(self): self.d["Environment"][0]["Value"] = Ref("RegistryStorage") cd = ecs.ContainerDefinition.from_dict("mycontainer", self.d) - self.assertEquals( + self.assertEqual( cd.Environment[0].Value.data, {"Ref": "RegistryStorage"}) def test_invalid_subproperty_definition(self): @@ -76,10 +76,10 @@ def test_invalid_subproperty_definition(self): def test_tags_from_dict(self): d = {"key1": "value1", "key2": "value2"} - expected = [{"Key": k, "Value": v} for k, v in d.items()] + expected = [{"Key": k, "Value": v} for k, v in list(d.items())] tags = Tags.from_dict(**d) - self.assertEquals(sorted(expected), sorted(tags.tags)) + self.assertEqual(sorted(expected), sorted(tags.tags)) if __name__ == '__main__': diff --git a/tests/test_examples.py b/tests/test_examples.py index d760211cd..781a78d1c 100644 --- a/tests/test_examples.py +++ b/tests/test_examples.py @@ -4,12 +4,12 @@ import unittest try: - import StringIO as io + import io as io except ImportError: import io try: - u = unicode + u = str except NameError: u = str @@ -46,7 +46,7 @@ def load_tests(loader, tests, pattern): # Filter out all *.py files from the examples directory examples = 'examples' regex = re.compile(r'.py$', re.I) - example_filesnames = filter(regex.search, os.listdir(examples)) + example_filesnames = list(filter(regex.search, os.listdir(examples))) suite = unittest.TestSuite() diff --git a/tests/test_examples_template_generator.py b/tests/test_examples_template_generator.py index f7db6e4af..940a92d53 100644 --- a/tests/test_examples_template_generator.py +++ b/tests/test_examples_template_generator.py @@ -6,7 +6,7 @@ from troposphere.template_generator import TemplateGenerator try: - u = unicode + u = str except NameError: u = str @@ -44,7 +44,7 @@ def load_tests(loader, tests, pattern): # Filter out all *.py files from the examples directory examples = 'examples' regex = re.compile(r'.py$', re.I) - example_filesnames = filter(regex.search, os.listdir(examples)) + example_filesnames = list(filter(regex.search, os.listdir(examples))) suite = unittest.TestSuite() diff --git a/tests/test_int_type.py b/tests/test_int_type.py index 37bdd351b..3b1c3933e 100644 --- a/tests/test_int_type.py +++ b/tests/test_int_type.py @@ -32,7 +32,7 @@ def get_aws_objects(self): return result def assertNoIntType(self, obj): - for prop_name, (types, required) in obj.props.items(): + for prop_name, (types, required) in list(obj.props.items()): error_msg = ( "{}.props['{}'] should have `validators.integer` " "rather than `int`".format(obj.__name__, prop_name)) diff --git a/tests/test_rds.py b/tests/test_rds.py index c6e547f68..2475d5c4f 100644 --- a/tests/test_rds.py +++ b/tests/test_rds.py @@ -38,7 +38,7 @@ def test_it_rds_instances_require_either_a_snapshot_or_credentials(self): Engine='MySQL' ) - with self.assertRaisesRegexp( + with self.assertRaisesRegex( ValueError, r'Either \(MasterUsername and MasterUserPassword\) or' r' DBSnapshotIdentifier are required' @@ -72,7 +72,7 @@ def test_replica_settings_are_inherited(self): DBSnapshotIdentifier="SomeDBSnapshotIdentifier", ) - with self.assertRaisesRegexp( + with self.assertRaisesRegex( ValueError, 'BackupRetentionPeriod, DBName, DBSnapshotIdentifier, ' 'MasterUserPassword, MasterUsername, ' @@ -95,7 +95,7 @@ def test_it_rds_instances_require_encryption_if_kms_key_provided(self): '12345678-1234-1234-1234-123456789012' ) - with self.assertRaisesRegexp( + with self.assertRaisesRegex( ValueError, 'If KmsKeyId is provided, StorageEncrypted is required' ): @@ -104,7 +104,7 @@ def test_it_rds_instances_require_encryption_if_kms_key_provided(self): def test_it_allows_an_rds_instance_with_iops(self): # ensure troposphere works with longs and ints try: - long_number = long(2000) + long_number = int(2000) except NameError: # Python 3 doesn't have 'long' anymore long_number = 2000 @@ -150,12 +150,12 @@ def test_fail_az_and_multiaz(self): Engine="postgres", AvailabilityZone="us-east-1", MultiAZ=True) - with self.assertRaisesRegexp(ValueError, "if MultiAZ is set to "): + with self.assertRaisesRegex(ValueError, "if MultiAZ is set to "): i.to_dict() i.MultiAZ = "false" i.to_dict() i.MultiAZ = "true" - with self.assertRaisesRegexp(ValueError, "if MultiAZ is set to "): + with self.assertRaisesRegex(ValueError, "if MultiAZ is set to "): i.to_dict() i.MultiAZ = Ref(AWS_NO_VALUE) @@ -185,7 +185,7 @@ def test_io1_storage_type_and_iops(self): DBInstanceClass="db.m1.small", Engine="postgres", StorageType='io1') - with self.assertRaisesRegexp(ValueError, "Must specify Iops if "): + with self.assertRaisesRegex(ValueError, "Must specify Iops if "): i.to_dict() def test_storage_to_iops_ratio(self): @@ -198,11 +198,11 @@ def test_storage_to_iops_ratio(self): StorageType='io1', Iops=6000, AllocatedStorage=10) - with self.assertRaisesRegexp(ValueError, " must be at least 100 "): + with self.assertRaisesRegex(ValueError, " must be at least 100 "): i.to_dict() i.AllocatedStorage = 100 - with self.assertRaisesRegexp( + with self.assertRaisesRegex( ValueError, " must be no less than 1/50th "): i.to_dict() @@ -240,7 +240,7 @@ def test_no_snapshot_or_engine(self): DBInstanceClass='db.m4.large', DBSubnetGroupName='default', ) - with self.assertRaisesRegexp( + with self.assertRaisesRegex( ValueError, "Resource Engine is required"): i.to_dict() @@ -287,10 +287,10 @@ def test_validate_backup_window(self): bad_format = ("bad_backup_window", "28:11-10:00", "10:00-28:11") for w in bad_format: - with self.assertRaisesRegexp(ValueError, "must be in the format"): + with self.assertRaisesRegex(ValueError, "must be in the format"): rds.validate_backup_window(w) - with self.assertRaisesRegexp(ValueError, "must be at least 30 "): + with self.assertRaisesRegex(ValueError, "must be at least 30 "): rds.validate_backup_window("10:00-10:10") def test_validate_maintenance_window(self): @@ -302,23 +302,23 @@ def test_validate_maintenance_window(self): bad_format = ("bad_mainteance", "Mon:10:00-Tue:28:00", "10:00-22:00") for w in bad_format: - with self.assertRaisesRegexp(ValueError, "must be in the format"): + with self.assertRaisesRegex(ValueError, "must be in the format"): rds.validate_maintenance_window(w) bad_days = ("Boo:10:00-Woo:10:30", "Boo:10:00-Tue:10:30", "Mon:10:00-Boo:10:30") for w in bad_days: - with self.assertRaisesRegexp(ValueError, " day part of ranges "): + with self.assertRaisesRegex(ValueError, " day part of ranges "): rds.validate_maintenance_window(w) - with self.assertRaisesRegexp(ValueError, "must be at least 30 "): + with self.assertRaisesRegex(ValueError, "must be at least 30 "): rds.validate_maintenance_window("Mon:10:00-Mon:10:10") def test_validate_backup_retention_period(self): for d in (1, 10, 15, 35): rds.validate_backup_retention_period(d) - with self.assertRaisesRegexp(ValueError, " cannot be larger than 35 "): + with self.assertRaisesRegex(ValueError, " cannot be larger than 35 "): rds.validate_backup_retention_period(40) rds.validate_backup_retention_period(10) diff --git a/tests/test_template_generator.py b/tests/test_template_generator.py index e8d7bada2..2e5815726 100644 --- a/tests/test_template_generator.py +++ b/tests/test_template_generator.py @@ -7,7 +7,7 @@ TemplateGenerator, ResourceTypeNotDefined, ResourceTypeNotFound try: - u = unicode + u = str except NameError: u = str @@ -92,7 +92,7 @@ def test_macro_resource(self): self.assertDictEqual(template.to_dict(), generated.to_dict()) foo = generated.resources["foo"] self.assertTrue(isinstance(foo, MyMacroResource)) - self.assertEquals("bar", foo.Foo) + self.assertEqual("bar", foo.Foo) def test_no_nested_name(self): """ @@ -123,8 +123,8 @@ class MyCustomResource(AWSObject): resource_type = "Custom::Resource" props = { - 'Foo': (basestring, True), - 'ServiceToken': (basestring, True), + 'Foo': (str, True), + 'ServiceToken': (str, True), } @@ -132,7 +132,7 @@ class MyMacroResource(AWSObject): resource_type = "Some::Special::Resource" props = { - 'Foo': (basestring, True), + 'Foo': (str, True), } diff --git a/troposphere/__init__.py b/troposphere/__init__.py index 45744a067..979226b99 100644 --- a/troposphere/__init__.py +++ b/troposphere/__init__.py @@ -62,7 +62,7 @@ def encode_to_dict(obj): return new_lst elif isinstance(obj, dict): props = {} - for name, prop in obj.items(): + for name, prop in list(obj.items()): props[name] = encode_to_dict(prop) return props @@ -93,7 +93,7 @@ def __init__(self, title, template=None, validation=True, **kwargs): self.template = template self.do_validation = validation # Cache the keys for validity checks - self.propnames = self.props.keys() + self.propnames = list(self.props.keys()) self.attributes = [ 'Condition', 'CreationPolicy', 'DeletionPolicy', 'DependsOn', 'Metadata', 'UpdatePolicy', 'UpdateReplacePolicy', @@ -117,13 +117,13 @@ def __init__(self, title, template=None, validation=True, **kwargs): self.__initialized = True # Check for properties defined in the class - for k, (_, required) in self.props.items(): + for k, (_, required) in list(self.props.items()): v = getattr(type(self), k, None) if v is not None and k not in kwargs: self.__setattr__(k, v) # Now that it is initialized, populate it with the kwargs - for k, v in kwargs.items(): + for k, v in list(kwargs.items()): self.__setattr__(k, v) self.add_to_template() @@ -155,7 +155,7 @@ def __getattr__(self, name): raise AttributeError(name) def __setattr__(self, name, value): - if name in self.__dict__.keys() \ + if name in list(self.__dict__.keys()) \ or '_BaseAWSObject__initialized' not in self.__dict__: return dict.__setattr__(self, name, value) elif name in self.attributes: @@ -198,7 +198,7 @@ def __setattr__(self, name, value): # Special case a list of a single validation function if (len(expected_type) == 1 and isinstance(expected_type[0], types.FunctionType)): - new_value = map(expected_type[0], value) + new_value = list(map(expected_type[0], value)) return self.properties.__setitem__(name, new_value) # Iterate over the list and make sure it matches our @@ -257,7 +257,7 @@ def to_dict(self): return encode_to_dict(self.resource) elif hasattr(self, 'resource_type'): d = {} - for k, v in self.resource.items(): + for k, v in list(self.resource.items()): if k != 'Properties': d[k] = v return d @@ -267,7 +267,7 @@ def to_dict(self): @classmethod def _from_dict(cls, title=None, **kwargs): props = {} - for prop_name, value in kwargs.items(): + for prop_name, value in list(kwargs.items()): try: prop_attrs = cls.props[prop_name] except KeyError: @@ -308,7 +308,7 @@ def from_dict(cls, title, d): return cls._from_dict(title, **d) def _validate_props(self): - for k, (_, required) in self.props.items(): + for k, (_, required) in list(self.props.items()): if required and k not in self.properties: rtype = getattr(self, 'resource_type', "") title = getattr(self, 'title') @@ -374,7 +374,7 @@ def __init__(self, title=None, **kwargs): def validate_delimiter(delimiter): - if not isinstance(delimiter, basestring): + if not isinstance(delimiter, str): raise ValueError( "Delimiter must be a String, %s provided" % type(delimiter) ) @@ -508,10 +508,10 @@ def __init__(self, data): def __eq__(self, other): if isinstance(other, self.__class__): return self.data == other.data - return self.data.values()[0] == other + return list(self.data.values())[0] == other def __hash__(self): - return hash(self.data.values()[0]) + return hash(list(self.data.values())[0]) # Pseudo Parameter Ref's @@ -556,18 +556,17 @@ def __init__(self, *args, **kwargs): elif isinstance(arg, dict): tag_dict.update(arg) else: - raise(TypeError, "Tags needs to be either kwargs, " - "dict, or AWSHelperFn") + raise TypeError def add_tag(tag_list, k, v): tag_list.append({'Key': k, 'Value': v, }) # Detect and handle non-string Tag items which do not sort in Python3 - if all(isinstance(k, basestring) for k in tag_dict): + if all(isinstance(k, str) for k in tag_dict): for k, v in sorted(tag_dict.items()): add_tag(self.tags, k, v) else: - for k, v in tag_dict.items(): + for k, v in list(tag_dict.items()): add_tag(self.tags, k, v) # allow concatenation of the Tags object via '+' operator @@ -585,9 +584,9 @@ def from_dict(cls, title=None, **kwargs): class Template(object): props = { - 'AWSTemplateFormatVersion': (basestring, False), - 'Transform': (basestring, False), - 'Description': (basestring, False), + 'AWSTemplateFormatVersion': (str, False), + 'Transform': (str, False), + 'Description': (str, False), 'Parameters': (dict, False), 'Mappings': (dict, False), 'Resources': (dict, False), @@ -824,9 +823,9 @@ def __init__(self, name): class Output(AWSDeclaration): props = { - 'Description': (basestring, False), + 'Description': (str, False), 'Export': (Export, False), - 'Value': (basestring, True), + 'Value': (str, True), } def add_to_template(self): @@ -839,17 +838,17 @@ class Parameter(AWSDeclaration): STRING_PROPERTIES = ['AllowedPattern', 'MaxLength', 'MinLength'] NUMBER_PROPERTIES = ['MaxValue', 'MinValue'] props = { - 'Type': (basestring, True), - 'Default': ((basestring, int, float), False), + 'Type': (str, True), + 'Default': ((str, int, float), False), 'NoEcho': (bool, False), 'AllowedValues': (list, False), - 'AllowedPattern': (basestring, False), + 'AllowedPattern': (str, False), 'MaxLength': (validators.positive_integer, False), 'MinLength': (validators.positive_integer, False), 'MaxValue': (validators.integer, False), 'MinValue': (validators.integer, False), - 'Description': (basestring, False), - 'ConstraintDescription': (basestring, False), + 'Description': (str, False), + 'ConstraintDescription': (str, False), } def add_to_template(self): @@ -880,25 +879,25 @@ def check_type(t, v): # matches (in the case of a String Type) or can be coerced # into one of the number formats. param_type = self.properties.get('Type') - if param_type == 'String' and not isinstance(default, basestring): + if param_type == 'String' and not isinstance(default, str): raise ValueError(error_str % ('String', type(default), default)) elif param_type == 'Number': allowed = [float, int] # See if the default value can be coerced into one # of the correct types - if not any(map(lambda x: check_type(x, default), allowed)): + if not any([check_type(x, default) for x in allowed]): raise ValueError(error_str % (param_type, type(default), default)) elif param_type == 'List': - if not isinstance(default, basestring): + if not isinstance(default, str): raise ValueError(error_str % (param_type, type(default), default)) allowed = [float, int] dlist = default.split(",") for d in dlist: # Verify the split array are all numbers - if not any(map(lambda x: check_type(x, d), allowed)): + if not any([check_type(x, d) for x in allowed]): raise ValueError(error_str % (param_type, type(d), dlist)) diff --git a/troposphere/accessanalyzer.py b/troposphere/accessanalyzer.py index 16b15385a..7e5550197 100644 --- a/troposphere/accessanalyzer.py +++ b/troposphere/accessanalyzer.py @@ -15,18 +15,18 @@ class Filter(AWSProperty): props = { - 'Contains': ([basestring], False), - 'Eq': ([basestring], False), + 'Contains': ([str], False), + 'Eq': ([str], False), 'Exists': (boolean, False), - 'Neq': ([basestring], False), - 'Property': (basestring, True), + 'Neq': ([str], False), + 'Property': (str, True), } class ArchiveRule(AWSProperty): props = { 'Filter': ([Filter], True), - 'RuleName': (basestring, True), + 'RuleName': (str, True), } @@ -34,8 +34,8 @@ class Analyzer(AWSObject): resource_type = "AWS::AccessAnalyzer::Analyzer" props = { - 'AnalyzerName': (basestring, False), + 'AnalyzerName': (str, False), 'ArchiveRules': ([ArchiveRule], False), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } diff --git a/troposphere/acmpca.py b/troposphere/acmpca.py index 5c354769b..cb4145a10 100644 --- a/troposphere/acmpca.py +++ b/troposphere/acmpca.py @@ -50,13 +50,13 @@ def validate_certificateauthority_type(certificateauthority_type): class Qualifier(AWSProperty): props = { - 'CpsUri': (basestring, True), + 'CpsUri': (str, True), } class PolicyQualifierInfo(AWSProperty): props = { - 'PolicyQualifierId': (basestring, True), + 'PolicyQualifierId': (str, True), 'Qualifier': (Qualifier, True), } @@ -69,7 +69,7 @@ class PolicyQualifierInfoList(AWSProperty): class PolicyInformation(AWSProperty): props = { - 'CertPolicyId': (basestring, True), + 'CertPolicyId': (str, True), 'PolicyQualifiers': (PolicyQualifierInfoList, False), } @@ -82,8 +82,8 @@ class CertificatePolicyList(AWSProperty): class ExtendedKeyUsage(AWSProperty): props = { - 'ExtendedKeyUsageObjectIdentifier': (basestring, False), - 'ExtendedKeyUsageType': (basestring, False), + 'ExtendedKeyUsageObjectIdentifier': (str, False), + 'ExtendedKeyUsageType': (str, False), } @@ -95,47 +95,47 @@ class ExtendedKeyUsageList(AWSProperty): class EdiPartyName(AWSProperty): props = { - 'NameAssigner': (basestring, True), - 'PartyName': (basestring, True), + 'NameAssigner': (str, True), + 'PartyName': (str, True), } class OtherName(AWSProperty): props = { - 'TypeId': (basestring, True), - 'Value': (basestring, True), + 'TypeId': (str, True), + 'Value': (str, True), } class Subject(AWSProperty): props = { - 'CommonName': (basestring, False), - 'Country': (basestring, False), - 'DistinguishedNameQualifier': (basestring, False), - 'GenerationQualifier': (basestring, False), - 'GivenName': (basestring, False), - 'Initials': (basestring, False), - 'Locality': (basestring, False), - 'Organization': (basestring, False), - 'OrganizationalUnit': (basestring, False), - 'Pseudonym': (basestring, False), - 'SerialNumber': (basestring, False), - 'State': (basestring, False), - 'Surname': (basestring, False), - 'Title': (basestring, False), + 'CommonName': (str, False), + 'Country': (str, False), + 'DistinguishedNameQualifier': (str, False), + 'GenerationQualifier': (str, False), + 'GivenName': (str, False), + 'Initials': (str, False), + 'Locality': (str, False), + 'Organization': (str, False), + 'OrganizationalUnit': (str, False), + 'Pseudonym': (str, False), + 'SerialNumber': (str, False), + 'State': (str, False), + 'Surname': (str, False), + 'Title': (str, False), } class GeneralName(AWSProperty): props = { 'DirectoryName': (Subject, False), - 'DnsName': (basestring, False), + 'DnsName': (str, False), 'EdiPartyName': (EdiPartyName, False), - 'IpAddress': (basestring, False), + 'IpAddress': (str, False), 'OtherName': (OtherName, False), - 'RegisteredId': (basestring, False), - 'Rfc822Name': (basestring, False), - 'UniformResourceIdentifier': (basestring, False), + 'RegisteredId': (str, False), + 'Rfc822Name': (str, False), + 'UniformResourceIdentifier': (str, False), } @@ -187,10 +187,10 @@ class Certificate(AWSObject): props = { 'ApiPassthrough': (ApiPassthrough, False), - 'CertificateAuthorityArn': (basestring, True), - 'CertificateSigningRequest': (basestring, True), + 'CertificateAuthorityArn': (str, True), + 'CertificateSigningRequest': (str, True), 'SigningAlgorithm': (validate_signing_algorithm, True), - 'TemplateArn': (basestring, False), + 'TemplateArn': (str, False), 'Validity': (Validity, True), 'ValidityNotBefore': (Validity, False), } @@ -200,19 +200,19 @@ class CertificateAuthorityActivation(AWSObject): resource_type = "AWS::ACMPCA::CertificateAuthorityActivation" props = { - 'Certificate': (basestring, True), - 'CertificateAuthorityArn': (basestring, True), - 'CertificateChain': (basestring, False), - 'Status': (basestring, False), + 'Certificate': (str, True), + 'CertificateAuthorityArn': (str, True), + 'CertificateChain': (str, False), + 'Status': (str, False), } class CrlConfiguration(AWSProperty): props = { - 'CustomCname': (basestring, False), + 'CustomCname': (str, False), 'Enabled': (boolean, False), 'ExpirationInDays': (integer, False), - 'S3BucketName': (basestring, False), + 'S3BucketName': (str, False), } @@ -224,20 +224,20 @@ class RevocationConfiguration(AWSProperty): class Subject(AWSProperty): props = { - 'CommonName': (basestring, False), - 'Country': (basestring, False), - 'DistinguishedNameQualifier': (basestring, False), - 'GenerationQualifier': (basestring, False), - 'GivenName': (basestring, False), - 'Initials': (basestring, False), - 'Locality': (basestring, False), - 'Organization': (basestring, False), - 'OrganizationalUnit': (basestring, False), - 'Pseudonym': (basestring, False), - 'SerialNumber': (basestring, False), - 'State': (basestring, False), - 'Surname': (basestring, False), - 'Title': (basestring, False), + 'CommonName': (str, False), + 'Country': (str, False), + 'DistinguishedNameQualifier': (str, False), + 'GenerationQualifier': (str, False), + 'GivenName': (str, False), + 'Initials': (str, False), + 'Locality': (str, False), + 'Organization': (str, False), + 'OrganizationalUnit': (str, False), + 'Pseudonym': (str, False), + 'SerialNumber': (str, False), + 'State': (str, False), + 'Surname': (str, False), + 'Title': (str, False), } diff --git a/troposphere/amazonmq.py b/troposphere/amazonmq.py index 81f0c1de3..b0f69eca6 100644 --- a/troposphere/amazonmq.py +++ b/troposphere/amazonmq.py @@ -16,37 +16,37 @@ class ConfigurationId(AWSProperty): props = { - 'Id': (basestring, True), + 'Id': (str, True), 'Revision': (integer, True), } class EncryptionOptions(AWSProperty): props = { - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'UseAwsOwnedKey': (boolean, True), } class InterBrokerCred(AWSProperty): props = { - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class ServerMetadata(AWSProperty): props = { - 'Hosts': ([basestring], True), - 'RoleBase': (basestring, True), - 'RoleName': (basestring, False), - 'RoleSearchMatching': (basestring, True), + 'Hosts': ([str], True), + 'RoleBase': (str, True), + 'RoleName': (str, False), + 'RoleSearchMatching': (str, True), 'RoleSearchSubtree': (boolean, False), - 'ServiceAccountPassword': (basestring, True), - 'ServiceAccountUsername': (basestring, True), - 'UserBase': (basestring, True), - 'UserRoleName': (basestring, False), - 'UserSearchMatching': (basestring, True), + 'ServiceAccountPassword': (str, True), + 'ServiceAccountUsername': (str, True), + 'UserBase': (str, True), + 'UserRoleName': (str, False), + 'UserSearchMatching': (str, True), 'UserSearchSubtree': (boolean, False), } @@ -60,16 +60,16 @@ class LdapMetadata(AWSProperty): class LdapServerMetadata(AWSProperty): props = { - 'Hosts': ([basestring], True), - 'RoleBase': (basestring, True), - 'RoleName': (basestring, False), - 'RoleSearchMatching': (basestring, True), + 'Hosts': ([str], True), + 'RoleBase': (str, True), + 'RoleName': (str, False), + 'RoleSearchMatching': (str, True), 'RoleSearchSubtree': (boolean, False), - 'ServiceAccountPassword': (basestring, True), - 'ServiceAccountUsername': (basestring, True), - 'UserBase': (basestring, True), - 'UserRoleName': (basestring, False), - 'UserSearchMatching': (basestring, True), + 'ServiceAccountPassword': (str, True), + 'ServiceAccountUsername': (str, True), + 'UserBase': (str, True), + 'UserRoleName': (str, False), + 'UserSearchMatching': (str, True), 'UserSearchSubtree': (boolean, False), } @@ -83,18 +83,18 @@ class LogsConfiguration(AWSProperty): class MaintenanceWindow(AWSProperty): props = { - 'DayOfWeek': (basestring, True), - 'TimeOfDay': (basestring, True), - 'TimeZone': (basestring, True), + 'DayOfWeek': (str, True), + 'TimeOfDay': (str, True), + 'TimeZone': (str, True), } class User(AWSProperty): props = { 'ConsoleAccess': (boolean, False), - 'Groups': ([basestring], False), - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Groups': ([str], False), + 'Password': (str, True), + 'Username': (str, True), } @@ -102,23 +102,23 @@ class Broker(AWSObject): resource_type = "AWS::AmazonMQ::Broker" props = { - 'AuthenticationStrategy': (basestring, False), + 'AuthenticationStrategy': (str, False), 'AutoMinorVersionUpgrade': (boolean, True), - 'BrokerName': (basestring, True), + 'BrokerName': (str, True), 'Configuration': (ConfigurationId, False), - 'DeploymentMode': (basestring, True), + 'DeploymentMode': (str, True), 'EncryptionOptions': (EncryptionOptions, False), - 'EngineType': (basestring, True), - 'EngineVersion': (basestring, True), - 'HostInstanceType': (basestring, True), + 'EngineType': (str, True), + 'EngineVersion': (str, True), + 'HostInstanceType': (str, True), 'LdapMetadata': (LdapMetadata, False), 'LdapServerMetadata': (LdapServerMetadata, False), 'Logs': (LogsConfiguration, False), 'MaintenanceWindowStartTime': (MaintenanceWindow, False), 'PubliclyAccessible': (boolean, True), - 'SecurityGroups': ([basestring], False), - 'StorageType': (basestring, False), - 'SubnetIds': ([basestring], False), + 'SecurityGroups': ([str], False), + 'StorageType': (str, False), + 'SubnetIds': ([str], False), 'Tags': ((Tags, list), False), 'Users': ([User], True), } @@ -128,11 +128,11 @@ class Configuration(AWSObject): resource_type = "AWS::AmazonMQ::Configuration" props = { - 'Data': (basestring, True), - 'Description': (basestring, False), - 'EngineType': (basestring, True), - 'EngineVersion': (basestring, True), - 'Name': (basestring, True), + 'Data': (str, True), + 'Description': (str, False), + 'EngineType': (str, True), + 'EngineVersion': (str, True), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -141,6 +141,6 @@ class ConfigurationAssociation(AWSObject): resource_type = "AWS::AmazonMQ::ConfigurationAssociation" props = { - 'Broker': (basestring, True), + 'Broker': (str, True), 'Configuration': (ConfigurationId, True), } diff --git a/troposphere/amplify.py b/troposphere/amplify.py index e6330df25..7b72135c9 100644 --- a/troposphere/amplify.py +++ b/troposphere/amplify.py @@ -16,39 +16,39 @@ class BasicAuthConfig(AWSProperty): props = { 'EnableBasicAuth': (boolean, False), - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class EnvironmentVariable(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class AutoBranchCreationConfig(AWSProperty): props = { - 'AutoBranchCreationPatterns': ([basestring], False), + 'AutoBranchCreationPatterns': ([str], False), 'BasicAuthConfig': (BasicAuthConfig, False), - 'BuildSpec': (basestring, False), + 'BuildSpec': (str, False), 'EnableAutoBranchCreation': (boolean, False), 'EnableAutoBuild': (boolean, False), 'EnablePerformanceMode': (boolean, False), 'EnablePullRequestPreview': (boolean, False), 'EnvironmentVariables': ([EnvironmentVariable], False), - 'PullRequestEnvironmentName': (basestring, False), - 'Stage': (basestring, False), + 'PullRequestEnvironmentName': (str, False), + 'Stage': (str, False), } class CustomRule(AWSProperty): props = { - 'Condition': (basestring, False), - 'Source': (basestring, True), - 'Status': (basestring, False), - 'Target': (basestring, True), + 'Condition': (str, False), + 'Source': (str, True), + 'Status': (str, False), + 'Target': (str, True), } @@ -56,19 +56,19 @@ class App(AWSObject): resource_type = "AWS::Amplify::App" props = { - 'AccessToken': (basestring, False), + 'AccessToken': (str, False), 'AutoBranchCreationConfig': (AutoBranchCreationConfig, False), 'BasicAuthConfig': (BasicAuthConfig, False), - 'BuildSpec': (basestring, False), - 'CustomHeaders': (basestring, False), + 'BuildSpec': (str, False), + 'CustomHeaders': (str, False), 'CustomRules': ([CustomRule], False), - 'Description': (basestring, False), + 'Description': (str, False), 'EnableBranchAutoDeletion': (boolean, False), 'EnvironmentVariables': ([EnvironmentVariable], False), - 'IAMServiceRole': (basestring, False), - 'Name': (basestring, True), - 'OauthToken': (basestring, False), - 'Repository': (basestring, False), + 'IAMServiceRole': (str, False), + 'Name': (str, True), + 'OauthToken': (str, False), + 'Repository': (str, False), 'Tags': (Tags, False), } @@ -77,25 +77,25 @@ class Branch(AWSObject): resource_type = "AWS::Amplify::Branch" props = { - 'AppId': (basestring, True), + 'AppId': (str, True), 'BasicAuthConfig': (BasicAuthConfig, False), - 'BranchName': (basestring, True), - 'BuildSpec': (basestring, False), - 'Description': (basestring, False), + 'BranchName': (str, True), + 'BuildSpec': (str, False), + 'Description': (str, False), 'EnableAutoBuild': (boolean, False), 'EnablePerformanceMode': (boolean, False), 'EnablePullRequestPreview': (boolean, False), 'EnvironmentVariables': ([EnvironmentVariable], False), - 'PullRequestEnvironmentName': (basestring, False), - 'Stage': (basestring, False), + 'PullRequestEnvironmentName': (str, False), + 'Stage': (str, False), 'Tags': (Tags, False), } class SubDomainSetting(AWSProperty): props = { - 'BranchName': (basestring, True), - 'Prefix': (basestring, True), + 'BranchName': (str, True), + 'Prefix': (str, True), } @@ -103,10 +103,10 @@ class Domain(AWSObject): resource_type = "AWS::Amplify::Domain" props = { - 'AppId': (basestring, True), - 'AutoSubDomainCreationPatterns': ([basestring], False), - 'AutoSubDomainIAMRole': (basestring, False), - 'DomainName': (basestring, True), + 'AppId': (str, True), + 'AutoSubDomainCreationPatterns': ([str], False), + 'AutoSubDomainIAMRole': (str, False), + 'DomainName': (str, True), 'EnableAutoSubDomain': (boolean, False), 'SubDomainSettings': ([SubDomainSetting], True), } diff --git a/troposphere/analytics.py b/troposphere/analytics.py index 65dc99c47..190638c24 100644 --- a/troposphere/analytics.py +++ b/troposphere/analytics.py @@ -15,22 +15,22 @@ class InputParallelism(AWSProperty): class RecordColumn(AWSProperty): props = { - 'Mapping': (basestring, False), - 'Name': (basestring, True), - 'SqlType': (basestring, True), + 'Mapping': (str, False), + 'Name': (str, True), + 'SqlType': (str, True), } class CSVMappingParameters(AWSProperty): props = { - 'RecordColumnDelimiter': (basestring, True), - 'RecordRowDelimiter': (basestring, True), + 'RecordColumnDelimiter': (str, True), + 'RecordRowDelimiter': (str, True), } class JSONMappingParameters(AWSProperty): props = { - 'RecordRowPath': (basestring, True), + 'RecordRowPath': (str, True), } @@ -44,36 +44,36 @@ class MappingParameters(AWSProperty): class RecordFormat(AWSProperty): props = { 'MappingParameters': (MappingParameters, False), - 'RecordFormatType': (basestring, True), + 'RecordFormatType': (str, True), } class InputSchema(AWSProperty): props = { 'RecordColumns': ([RecordColumn], True), - 'RecordEncoding': (basestring, False), + 'RecordEncoding': (str, False), 'RecordFormat': (RecordFormat, True), } class KinesisFirehoseInput(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } class KinesisStreamsInput(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } class InputLambdaProcessor(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } @@ -85,7 +85,7 @@ class InputProcessingConfiguration(AWSProperty): class Input(AWSProperty): props = { - 'NamePrefix': (basestring, True), + 'NamePrefix': (str, True), 'InputParallelism': (InputParallelism, False), 'InputSchema': (InputSchema, True), 'KinesisFirehoseInput': (KinesisFirehoseInput, False), @@ -98,37 +98,37 @@ class Application(AWSObject): resource_type = "AWS::KinesisAnalytics::Application" props = { - 'ApplicationName': (basestring, False), - 'ApplicationDescription': (basestring, False), - 'ApplicationCode': (basestring, False), + 'ApplicationName': (str, False), + 'ApplicationDescription': (str, False), + 'ApplicationCode': (str, False), 'Inputs': ([Input], True), } class DestinationSchema(AWSProperty): props = { - 'RecordFormatType': (basestring, False), + 'RecordFormatType': (str, False), } class KinesisFirehoseOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } class KinesisStreamsOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } class LambdaOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), - 'RoleARN': (basestring, True), + 'ResourceARN': (str, True), + 'RoleARN': (str, True), } @@ -138,7 +138,7 @@ class Output(AWSProperty): 'KinesisFirehoseOutput': (KinesisFirehoseOutput, False), 'KinesisStreamsOutput': (KinesisStreamsOutput, False), 'LambdaOutput': (LambdaOutput, False), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -146,7 +146,7 @@ class ApplicationOutput(AWSObject): resource_type = "AWS::KinesisAnalytics::ApplicationOutput" props = { - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'Output': (Output, True), } @@ -154,16 +154,16 @@ class ApplicationOutput(AWSObject): class ReferenceSchema(AWSProperty): props = { 'RecordColumns': ([RecordColumn], True), - 'RecordEncoding': (basestring, False), + 'RecordEncoding': (str, False), 'RecordFormat': (RecordFormat, True), } class S3ReferenceDataSource(AWSProperty): props = { - 'BucketARN': (basestring, False), - 'FileKey': (basestring, False), - 'ReferenceRoleARN': (basestring, False), + 'BucketARN': (str, False), + 'FileKey': (str, False), + 'ReferenceRoleARN': (str, False), } @@ -171,7 +171,7 @@ class ReferenceDataSource(AWSProperty): props = { 'ReferenceSchema': (ReferenceSchema, True), 'S3ReferenceDataSource': (S3ReferenceDataSource, False), - 'TableName': (basestring, False), + 'TableName': (str, False), } @@ -179,6 +179,6 @@ class ApplicationReferenceDataSource(AWSObject): resource_type = "AWS::KinesisAnalytics::ApplicationReferenceDataSource" props = { - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'ReferenceDataSource': (ReferenceDataSource, True), } diff --git a/troposphere/apigateway.py b/troposphere/apigateway.py index 1ebca1422..5a494a571 100644 --- a/troposphere/apigateway.py +++ b/troposphere/apigateway.py @@ -18,8 +18,8 @@ def validate_authorizer_ttl(ttl_value): class AccessLogSetting(AWSProperty): props = { - "DestinationArn": (basestring, False), - "Format": (basestring, False) + "DestinationArn": (str, False), + "Format": (str, False) } @@ -27,15 +27,15 @@ class Account(AWSObject): resource_type = "AWS::ApiGateway::Account" props = { - "CloudWatchRoleArn": (basestring, False) + "CloudWatchRoleArn": (str, False) } class StageKey(AWSProperty): props = { - "RestApiId": (basestring, False), - "StageName": (basestring, False) + "RestApiId": (str, False), + "StageName": (str, False) } @@ -43,14 +43,14 @@ class ApiKey(AWSObject): resource_type = "AWS::ApiGateway::ApiKey" props = { - "CustomerId": (basestring, False), - "Description": (basestring, False), + "CustomerId": (str, False), + "Description": (str, False), "Enabled": (boolean, False), "GenerateDistinctId": (boolean, False), - "Name": (basestring, False), + "Name": (str, False), "StageKeys": ([StageKey], False), "Tags": (Tags, False), - "Value": (basestring, False) + "Value": (str, False) } @@ -58,16 +58,16 @@ class Authorizer(AWSObject): resource_type = "AWS::ApiGateway::Authorizer" props = { - "AuthType": (basestring, False), - "AuthorizerCredentials": (basestring, False), + "AuthType": (str, False), + "AuthorizerCredentials": (str, False), "AuthorizerResultTtlInSeconds": (validate_authorizer_ttl, False), - "AuthorizerUri": (basestring, True), - "IdentitySource": (basestring, True), - "IdentityValidationExpression": (basestring, False), - "Name": (basestring, True), - "ProviderARNs": ([basestring], False), - "RestApiId": (basestring, False), - "Type": (basestring, True) + "AuthorizerUri": (str, True), + "IdentitySource": (str, True), + "IdentityValidationExpression": (str, False), + "Name": (str, True), + "ProviderARNs": ([str], False), + "RestApiId": (str, False), + "Type": (str, True) } @@ -75,10 +75,10 @@ class BasePathMapping(AWSObject): resource_type = "AWS::ApiGateway::BasePathMapping" props = { - "BasePath": (basestring, False), - "DomainName": (basestring, True), - "RestApiId": (basestring, True), - "Stage": (basestring, False) + "BasePath": (str, False), + "DomainName": (str, True), + "RestApiId": (str, True), + "Stage": (str, False) } @@ -87,7 +87,7 @@ class BasePathMapping(AWSObject): class CanarySetting(AWSProperty): props = { - "DeploymentId": (basestring, False), + "DeploymentId": (str, False), "PercentTraffic": ([double], False), "StageVariableOverrides": (dict, False), "UseStageCache": (boolean, False), @@ -101,7 +101,7 @@ class ClientCertificate(AWSObject): resource_type = "AWS::ApiGateway::ClientCertificate" props = { - "Description": (basestring, False), + "Description": (str, False), "Tags": (Tags, False), } @@ -129,10 +129,10 @@ class MethodSetting(AWSProperty): "CacheTtlInSeconds": (positive_integer, False), "CachingEnabled": (bool, False), "DataTraceEnabled": (bool, False), - "HttpMethod": (basestring, True), - "LoggingLevel": (basestring, False), + "HttpMethod": (str, True), + "LoggingLevel": (str, False), "MetricsEnabled": (bool, False), - "ResourcePath": (basestring, True), + "ResourcePath": (str, True), "ThrottlingBurstLimit": (positive_integer, False), "ThrottlingRateLimit": (positive_integer, False) } @@ -143,18 +143,18 @@ class StageDescription(AWSProperty): props = { "AccessLogSetting": (AccessLogSetting, False), "CacheClusterEnabled": (bool, False), - "CacheClusterSize": (basestring, False), + "CacheClusterSize": (str, False), "CacheDataEncrypted": (bool, False), "CacheTtlInSeconds": (positive_integer, False), "CachingEnabled": (bool, False), "CanarySetting": (DeploymentCanarySettings, False), - "ClientCertificateId": (basestring, False), + "ClientCertificateId": (str, False), "DataTraceEnabled": (bool, False), - "Description": (basestring, False), - "LoggingLevel": (basestring, False), + "Description": (str, False), + "LoggingLevel": (str, False), "MethodSettings": ([MethodSetting], False), "MetricsEnabled": (bool, False), - "StageName": (basestring, False), + "StageName": (str, False), "Tags": ((Tags, list), False), "ThrottlingBurstLimit": (positive_integer, False), "ThrottlingRateLimit": (positive_integer, False), @@ -174,20 +174,20 @@ class Deployment(AWSObject): props = { "DeploymentCanarySettings": (DeploymentCanarySettings, False), - "Description": (basestring, False), - "RestApiId": (basestring, True), + "Description": (str, False), + "RestApiId": (str, True), "StageDescription": (StageDescription, False), - "StageName": (basestring, False) + "StageName": (str, False) } class Location(AWSProperty): props = { - "Method": (basestring, False), - "Name": (basestring, False), - "Path": (basestring, False), - "StatusCode": (basestring, False), - "Type": (basestring, False), + "Method": (str, False), + "Name": (str, False), + "Path": (str, False), + "StatusCode": (str, False), + "Type": (str, False), } @@ -196,8 +196,8 @@ class DocumentationPart(AWSObject): props = { "Location": (Location, True), - "Properties": (basestring, True), - "RestApiId": (basestring, True), + "Properties": (str, True), + "RestApiId": (str, True), } @@ -205,24 +205,24 @@ class DocumentationVersion(AWSObject): resource_type = "AWS::ApiGateway::DocumentationVersion" props = { - "Description": (basestring, False), - "DocumentationVersion": (basestring, True), - "RestApiId": (basestring, True), + "Description": (str, False), + "DocumentationVersion": (str, True), + "RestApiId": (str, True), } class EndpointConfiguration(AWSProperty): props = { - "Types": ([basestring], False), - "VpcEndpointIds": ([basestring], False), + "Types": ([str], False), + "VpcEndpointIds": ([str], False), } class MutualTlsAuthentication(AWSProperty): props = { - 'TruststoreUri': (basestring, False), - 'TruststoreVersion': (basestring, False), + 'TruststoreUri': (str, False), + 'TruststoreVersion': (str, False), } @@ -230,12 +230,12 @@ class DomainName(AWSObject): resource_type = "AWS::ApiGateway::DomainName" props = { - "CertificateArn": (basestring, False), - "DomainName": (basestring, True), + "CertificateArn": (str, False), + "DomainName": (str, True), "EndpointConfiguration": (EndpointConfiguration, False), 'MutualTlsAuthentication': (MutualTlsAuthentication, False), - "RegionalCertificateArn": (basestring, False), - "SecurityPolicy": (basestring, False), + "RegionalCertificateArn": (str, False), + "SecurityPolicy": (str, False), "Tags": (Tags, False), } @@ -243,31 +243,31 @@ class DomainName(AWSObject): class IntegrationResponse(AWSProperty): props = { - "ContentHandling": (basestring, False), + "ContentHandling": (str, False), "ResponseParameters": (dict, False), "ResponseTemplates": (dict, False), - "SelectionPattern": (basestring, False), - "StatusCode": (basestring, False) + "SelectionPattern": (str, False), + "StatusCode": (str, False) } class Integration(AWSProperty): props = { - "CacheKeyParameters": ([basestring], False), - "CacheNamespace": (basestring, False), - "ConnectionId": (basestring, False), - "ConnectionType": (basestring, False), - "ContentHandling": (basestring, False), - "Credentials": (basestring, False), - "IntegrationHttpMethod": (basestring, False), + "CacheKeyParameters": ([str], False), + "CacheNamespace": (str, False), + "ConnectionId": (str, False), + "ConnectionType": (str, False), + "ContentHandling": (str, False), + "Credentials": (str, False), + "IntegrationHttpMethod": (str, False), "IntegrationResponses": ([IntegrationResponse], False), - "PassthroughBehavior": (basestring, False), + "PassthroughBehavior": (str, False), "RequestParameters": (dict, False), "RequestTemplates": (dict, False), "TimeoutInMillis": (integer_range(50, 29000), False), - "Type": (basestring, True), - "Uri": (basestring, False) + "Type": (str, True), + "Uri": (str, False) } @@ -276,7 +276,7 @@ class MethodResponse(AWSProperty): props = { "ResponseModels": (dict, False), "ResponseParameters": (dict, False), - "StatusCode": (basestring, True) + "StatusCode": (str, True) } @@ -285,18 +285,18 @@ class Method(AWSObject): props = { "ApiKeyRequired": (bool, False), - "AuthorizationScopes": ([basestring], False), - "AuthorizationType": (basestring, True), - "AuthorizerId": (basestring, False), - "HttpMethod": (basestring, True), + "AuthorizationScopes": ([str], False), + "AuthorizationType": (str, True), + "AuthorizerId": (str, False), + "HttpMethod": (str, True), "Integration": (Integration, False), "MethodResponses": ([MethodResponse], False), - "OperationName": (basestring, False), + "OperationName": (str, False), "RequestModels": (dict, False), "RequestParameters": (dict, False), - "RequestValidatorId": (basestring, False), - "ResourceId": (basestring, True), - "RestApiId": (basestring, True) + "RequestValidatorId": (str, False), + "ResourceId": (str, True), + "RestApiId": (str, True) } @@ -304,11 +304,11 @@ class Model(AWSObject): resource_type = "AWS::ApiGateway::Model" props = { - "ContentType": (basestring, False), - "Description": (basestring, False), - "Name": (basestring, False), - "RestApiId": (basestring, True), - "Schema": ((basestring, dict), False) + "ContentType": (str, False), + "Description": (str, False), + "Name": (str, False), + "RestApiId": (str, True), + "Schema": ((str, dict), False) } def validate(self): @@ -322,8 +322,8 @@ class RequestValidator(AWSObject): resource_type = "AWS::ApiGateway::RequestValidator" props = { - "Name": (basestring, True), - "RestApiId": (basestring, True), + "Name": (str, True), + "RestApiId": (str, True), "ValidateRequestBody": (boolean, False), "ValidateRequestParameters": (boolean, False), } @@ -333,19 +333,19 @@ class Resource(AWSObject): resource_type = "AWS::ApiGateway::Resource" props = { - "ParentId": (basestring, True), - "PathPart": (basestring, True), - "RestApiId": (basestring, True) + "ParentId": (str, True), + "PathPart": (str, True), + "RestApiId": (str, True) } class S3Location(AWSProperty): props = { - "Bucket": (basestring, False), - "ETag": (basestring, False), - "Key": (basestring, False), - "Version": (basestring, False) + "Bucket": (str, False), + "ETag": (str, False), + "Key": (str, False), + "Version": (str, False) } @@ -353,16 +353,16 @@ class RestApi(AWSObject): resource_type = "AWS::ApiGateway::RestApi" props = { - "ApiKeySourceType": (basestring, False), - "BinaryMediaTypes": ([basestring], False), + "ApiKeySourceType": (str, False), + "BinaryMediaTypes": ([str], False), "Body": (dict, False), "BodyS3Location": (S3Location, False), - "CloneFrom": (basestring, False), - "Description": (basestring, False), + "CloneFrom": (str, False), + "Description": (str, False), "EndpointConfiguration": (EndpointConfiguration, False), "FailOnWarnings": (boolean, False), "MinimumCompressionSize": (positive_integer, False), - "Name": (basestring, False), + "Name": (str, False), "Parameters": (dict, False), "Policy": (dict, False), "Tags": (Tags, False), @@ -375,15 +375,15 @@ class Stage(AWSObject): props = { "AccessLogSetting": (AccessLogSetting, False), "CacheClusterEnabled": (bool, False), - "CacheClusterSize": (basestring, False), + "CacheClusterSize": (str, False), "CanarySetting": (StageCanarySetting, False), - "ClientCertificateId": (basestring, False), - "DeploymentId": (basestring, True), - "Description": (basestring, False), - "DocumentationVersion": (basestring, False), + "ClientCertificateId": (str, False), + "DeploymentId": (str, True), + "Description": (str, False), + "DocumentationVersion": (str, False), "MethodSettings": ([MethodSetting], False), - "RestApiId": (basestring, True), - "StageName": (basestring, True), + "RestApiId": (str, True), + "StageName": (str, True), "Tags": ((Tags, list), False), "TracingEnabled": (bool, False), "Variables": (dict, False), @@ -394,7 +394,7 @@ class QuotaSettings(AWSProperty): props = { "Limit": (positive_integer, False), "Offset": (positive_integer, False), - "Period": (basestring, False), + "Period": (str, False), } @@ -407,8 +407,8 @@ class ThrottleSettings(AWSProperty): class ApiStage(AWSProperty): props = { - "ApiId": (basestring, False), - "Stage": (basestring, False), + "ApiId": (str, False), + "Stage": (str, False), "Throttle": (dict, False), } @@ -418,11 +418,11 @@ class UsagePlan(AWSObject): props = { "ApiStages": ([ApiStage], False), - "Description": (basestring, False), + "Description": (str, False), "Quota": (QuotaSettings, False), "Tags": (Tags, False), "Throttle": (ThrottleSettings, False), - "UsagePlanName": (basestring, False), + "UsagePlanName": (str, False), } @@ -430,9 +430,9 @@ class UsagePlanKey(AWSObject): resource_type = "AWS::ApiGateway::UsagePlanKey" props = { - "KeyId": (basestring, True), - "KeyType": (basestring, True), - "UsagePlanId": (basestring, True), + "KeyId": (str, True), + "KeyType": (str, True), + "UsagePlanId": (str, True), } @@ -477,8 +477,8 @@ class GatewayResponse(AWSObject): "ResponseParameters": (dict, False), "ResponseTemplates": (dict, False), "ResponseType": (validate_gateway_response_type, True), - "RestApiId": (basestring, True), - "StatusCode": (basestring, False) + "RestApiId": (str, True), + "StatusCode": (str, False) } @@ -486,7 +486,7 @@ class VpcLink(AWSObject): resource_type = "AWS::ApiGateway::VpcLink" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), - 'TargetArns': ([basestring], True), + 'Description': (str, False), + 'Name': (str, True), + 'TargetArns': ([str], True), } diff --git a/troposphere/apigatewayv2.py b/troposphere/apigatewayv2.py index 8d02ad717..a8cf54fc4 100644 --- a/troposphere/apigatewayv2.py +++ b/troposphere/apigatewayv2.py @@ -104,20 +104,20 @@ def validate_authorizer_ttl(ttl_value): class BodyS3Location(AWSProperty): props = { - 'Bucket': (basestring, False), - 'Etag': (basestring, False), - 'Key': (basestring, False), - 'Version': (basestring, False), + 'Bucket': (str, False), + 'Etag': (str, False), + 'Key': (str, False), + 'Version': (str, False), } class Cors(AWSProperty): props = { 'AllowCredentials': (boolean, False), - 'AllowHeaders': ([basestring], False), - 'AllowMethods': ([basestring], False), - 'AllowOrigins': ([basestring], False), - 'ExposeHeaders': ([basestring], False), + 'AllowHeaders': ([str], False), + 'AllowMethods': ([str], False), + 'AllowOrigins': ([str], False), + 'ExposeHeaders': ([str], False), 'MaxAge': (integer, False), } @@ -126,23 +126,23 @@ class Api(AWSObject): resource_type = "AWS::ApiGatewayV2::Api" props = { - 'ApiKeySelectionExpression': (basestring, False), - 'BasePath': (basestring, False), + 'ApiKeySelectionExpression': (str, False), + 'BasePath': (str, False), 'Body': (dict, False), 'BodyS3Location': (BodyS3Location, False), 'CorsConfiguration': (Cors, False), - 'CredentialsArn': (basestring, False), - 'Description': (basestring, False), + 'CredentialsArn': (str, False), + 'Description': (str, False), 'DisableExecuteApiEndpoint': (boolean, False), 'DisableSchemaValidation': (boolean, False), 'FailOnWarnings': (boolean, False), - 'Name': (basestring, False), - 'ProtocolType': (basestring, False), - 'RouteKey': (basestring, False), - 'RouteSelectionExpression': (basestring, False), + 'Name': (str, False), + 'ProtocolType': (str, False), + 'RouteKey': (str, False), + 'RouteSelectionExpression': (str, False), 'Tags': (dict, False), - 'Target': (basestring, False), - 'Version': (basestring, False), + 'Target': (str, False), + 'Version': (str, False), } @@ -150,17 +150,17 @@ class ApiMapping(AWSObject): resource_type = "AWS::ApiGatewayV2::ApiMapping" props = { - 'ApiId': (basestring, True), - 'ApiMappingKey': (basestring, False), - 'DomainName': (basestring, True), - 'Stage': (basestring, True), + 'ApiId': (str, True), + 'ApiMappingKey': (str, False), + 'DomainName': (str, True), + 'Stage': (str, True), } class JWTConfiguration(AWSProperty): props = { - 'Audience': ([basestring], False), - 'Issuer': (basestring, False), + 'Audience': ([str], False), + 'Issuer': (str, False), } @@ -168,17 +168,17 @@ class Authorizer(AWSObject): resource_type = "AWS::ApiGatewayV2::Authorizer" props = { - 'ApiId': (basestring, True), - 'AuthorizerCredentialsArn': (basestring, False), - 'AuthorizerPayloadFormatVersion': (basestring, False), + 'ApiId': (str, True), + 'AuthorizerCredentialsArn': (str, False), + 'AuthorizerPayloadFormatVersion': (str, False), 'AuthorizerResultTtlInSeconds': (validate_authorizer_ttl, False), 'AuthorizerType': (validate_authorizer_type, True), - 'AuthorizerUri': (basestring, False), + 'AuthorizerUri': (str, False), 'EnableSimpleResponses': (boolean, False), - 'IdentitySource': ([basestring], True), - 'IdentityValidationExpression': (basestring, False), + 'IdentitySource': ([str], True), + 'IdentityValidationExpression': (str, False), 'JwtConfiguration': (JWTConfiguration, False), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -186,24 +186,24 @@ class Deployment(AWSObject): resource_type = "AWS::ApiGatewayV2::Deployment" props = { - 'ApiId': (basestring, True), - 'Description': (basestring, False), - 'StageName': (basestring, False), + 'ApiId': (str, True), + 'Description': (str, False), + 'StageName': (str, False), } class DomainNameConfiguration(AWSProperty): props = { - 'CertificateArn': (basestring, False), - 'CertificateName': (basestring, False), - 'EndpointType': (basestring, False), + 'CertificateArn': (str, False), + 'CertificateName': (str, False), + 'EndpointType': (str, False), } class MutualTlsAuthentication(AWSProperty): props = { - 'TruststoreUri': (basestring, False), - 'TruststoreVersion': (basestring, False), + 'TruststoreUri': (str, False), + 'TruststoreVersion': (str, False), } @@ -211,7 +211,7 @@ class DomainName(AWSObject): resource_type = "AWS::ApiGatewayV2::DomainName" props = { - 'DomainName': (basestring, True), + 'DomainName': (str, True), 'DomainNameConfigurations': ([DomainNameConfiguration], False), 'MutualTlsAuthentication': (MutualTlsAuthentication, False), 'Tags': (dict, False), @@ -220,7 +220,7 @@ class DomainName(AWSObject): class TlsConfig(AWSProperty): props = { - 'ServerNameToVerify': (basestring, False), + 'ServerNameToVerify': (str, False), } @@ -228,21 +228,21 @@ class Integration(AWSObject): resource_type = "AWS::ApiGatewayV2::Integration" props = { - 'ApiId': (basestring, True), - 'ConnectionType': (basestring, False), - 'ConnectionId': (basestring, False), + 'ApiId': (str, True), + 'ConnectionType': (str, False), + 'ConnectionId': (str, False), 'ContentHandlingStrategy': (validate_content_handling_strategy, False), - 'CredentialsArn': (basestring, False), - 'Description': (basestring, False), - 'IntegrationMethod': (basestring, False), - 'IntegrationSubType': (basestring, False), + 'CredentialsArn': (str, False), + 'Description': (str, False), + 'IntegrationMethod': (str, False), + 'IntegrationSubType': (str, False), 'IntegrationType': (validate_integration_type, True), - 'IntegrationUri': (basestring, False), + 'IntegrationUri': (str, False), 'PassthroughBehavior': (validate_passthrough_behavior, False), - 'PayloadFormatVersion': (basestring, False), + 'PayloadFormatVersion': (str, False), 'RequestParameters': (dict, False), 'RequestTemplates': (dict, False), - 'TemplateSelectionExpression': (basestring, False), + 'TemplateSelectionExpression': (str, False), 'TimeoutInMillis': (integer_range(50, 29000), False), 'TlsConfig': (TlsConfig, False), } @@ -252,13 +252,13 @@ class IntegrationResponse(AWSObject): resource_type = "AWS::ApiGatewayV2::IntegrationResponse" props = { - 'ApiId': (basestring, True), + 'ApiId': (str, True), 'ContentHandlingStrategy': (validate_content_handling_strategy, False), - 'IntegrationId': (basestring, True), - 'IntegrationResponseKey': (basestring, True), + 'IntegrationId': (str, True), + 'IntegrationResponseKey': (str, True), 'ResponseParameters': (dict, False), 'ResponseTemplates': (dict, False), - 'TemplateSelectionExpression': (basestring, False), + 'TemplateSelectionExpression': (str, False), } @@ -266,11 +266,11 @@ class Model(AWSObject): resource_type = "AWS::ApiGatewayV2::Model" props = { - 'ApiId': (basestring, True), - 'ContentType': (basestring, False), - 'Description': (basestring, False), - 'Name': (basestring, True), - 'Schema': ((basestring, dict), True), + 'ApiId': (str, True), + 'ContentType': (str, False), + 'Description': (str, False), + 'Name': (str, True), + 'Schema': ((str, dict), True), } def validate(self): @@ -284,18 +284,18 @@ class Route(AWSObject): resource_type = "AWS::ApiGatewayV2::Route" props = { - 'ApiId': (basestring, True), + 'ApiId': (str, True), 'ApiKeyRequired': (boolean, False), - 'AuthorizationScopes': ([basestring], False), - 'AuthorizationType': (basestring, False), - 'AuthorizerId': (basestring, False), - 'ModelSelectionExpression': (basestring, False), - 'OperationName': (basestring, False), + 'AuthorizationScopes': ([str], False), + 'AuthorizationType': (str, False), + 'AuthorizerId': (str, False), + 'ModelSelectionExpression': (str, False), + 'OperationName': (str, False), 'RequestModels': (dict, False), 'RequestParameters': (dict, False), - 'RouteKey': (basestring, True), - 'RouteResponseSelectionExpression': (basestring, False), - 'Target': (basestring, False), + 'RouteKey': (str, True), + 'RouteResponseSelectionExpression': (str, False), + 'Target': (str, False), } @@ -303,19 +303,19 @@ class RouteResponse(AWSObject): resource_type = "AWS::ApiGatewayV2::RouteResponse" props = { - 'ApiId': (basestring, True), - 'ModelSelectionExpression': (basestring, False), + 'ApiId': (str, True), + 'ModelSelectionExpression': (str, False), 'ResponseModels': (dict, False), 'ResponseParameters': (dict, False), - 'RouteId': (basestring, True), - 'RouteResponseKey': (basestring, True), + 'RouteId': (str, True), + 'RouteResponseKey': (str, True), } class AccessLogSettings(AWSProperty): props = { - 'DestinationArn': (basestring, False), - 'Format': (basestring, False), + 'DestinationArn': (str, False), + 'Format': (str, False), } @@ -334,14 +334,14 @@ class Stage(AWSObject): props = { 'AccessLogSettings': (AccessLogSettings, False), - 'ApiId': (basestring, True), + 'ApiId': (str, True), 'AutoDeploy': (boolean, False), - 'ClientCertificateId': (basestring, False), + 'ClientCertificateId': (str, False), 'DefaultRouteSettings': (RouteSettings, False), - 'DeploymentId': (basestring, False), - 'Description': (basestring, False), + 'DeploymentId': (str, False), + 'Description': (str, False), 'RouteSettings': (dict, False), - 'StageName': (basestring, True), + 'StageName': (str, True), 'StageVariables': (dict, False), 'Tags': (dict, False), } @@ -351,8 +351,8 @@ class VpcLink(AWSObject): resource_type = "AWS::ApiGatewayV2::VpcLink" props = { - 'Name': (basestring, True), - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], True), + 'Name': (str, True), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], True), 'Tags': (dict, False), } diff --git a/troposphere/appconfig.py b/troposphere/appconfig.py index 24952d6a1..0a9cd2471 100644 --- a/troposphere/appconfig.py +++ b/troposphere/appconfig.py @@ -40,11 +40,11 @@ class DeploymentStrategy(AWSObject): props = { 'DeploymentDurationInMinutes': (double, True), - 'Description': (basestring, False), + 'Description': (str, False), 'FinalBakeTimeInMinutes': (double, False), 'GrowthFactor': (double, True), 'GrowthType': (validate_growth_type, False), - 'Name': (basestring, True), + 'Name': (str, True), 'ReplicateTo': (validate_replicate_to, True), 'Tags': (Tags, False), } @@ -52,8 +52,8 @@ class DeploymentStrategy(AWSObject): class Monitors(AWSProperty): props = { - 'AlarmArn': (basestring, False), - 'AlarmRoleArn': (basestring, False), + 'AlarmArn': (str, False), + 'AlarmRoleArn': (str, False), } @@ -61,10 +61,10 @@ class Environment(AWSObject): resource_type = "AWS::AppConfig::Environment" props = { - 'ApplicationId': (basestring, True), - 'Description': (basestring, False), + 'ApplicationId': (str, True), + 'Description': (str, False), 'Monitors': ([Monitors], False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -73,19 +73,19 @@ class Deployment(AWSObject): resource_type = "AWS::AppConfig::Deployment" props = { - 'ApplicationId': (basestring, True), - 'ConfigurationProfileId': (basestring, True), - 'ConfigurationVersion': (basestring, True), - 'DeploymentStrategyId': (basestring, True), - 'Description': (basestring, False), - 'EnvironmentId': (basestring, True), + 'ApplicationId': (str, True), + 'ConfigurationProfileId': (str, True), + 'ConfigurationVersion': (str, True), + 'DeploymentStrategyId': (str, True), + 'Description': (str, False), + 'EnvironmentId': (str, True), 'Tags': (Tags, False), } class Validators(AWSProperty): props = { - 'Content': (basestring, False), + 'Content': (str, False), 'Type': (validate_validator_type, False), } @@ -94,11 +94,11 @@ class ConfigurationProfile(AWSObject): resource_type = "AWS::AppConfig::ConfigurationProfile" props = { - 'ApplicationId': (basestring, True), - 'Description': (basestring, False), - 'LocationUri': (basestring, True), - 'Name': (basestring, True), - 'RetrievalRoleArn': (basestring, False), + 'ApplicationId': (str, True), + 'Description': (str, False), + 'LocationUri': (str, True), + 'Name': (str, True), + 'RetrievalRoleArn': (str, False), 'Tags': (Tags, False), 'Validators': ([Validators], False) } @@ -108,11 +108,11 @@ class HostedConfigurationVersion(AWSObject): resource_type = "AWS::AppConfig::HostedConfigurationVersion" props = { - 'ApplicationId': (basestring, True), - 'ConfigurationProfileId': (basestring, True), - 'Content': (basestring, True), - 'ContentType': (basestring, True), - 'Description': (basestring, False), + 'ApplicationId': (str, True), + 'ConfigurationProfileId': (str, True), + 'Content': (str, True), + 'ContentType': (str, True), + 'Description': (str, False), 'LatestVersionNumber': (double, False), } @@ -121,7 +121,7 @@ class Application(AWSObject): resource_type = "AWS::AppConfig::Application" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/appflow.py b/troposphere/appflow.py index 68b38d304..a93bcb518 100644 --- a/troposphere/appflow.py +++ b/troposphere/appflow.py @@ -16,121 +16,121 @@ class AmplitudeConnectorProfileCredentials(AWSProperty): props = { - 'ApiKey': (basestring, True), - 'SecretKey': (basestring, True), + 'ApiKey': (str, True), + 'SecretKey': (str, True), } class DatadogConnectorProfileCredentials(AWSProperty): props = { - 'ApiKey': (basestring, True), - 'ApplicationKey': (basestring, True), + 'ApiKey': (str, True), + 'ApplicationKey': (str, True), } class DynatraceConnectorProfileCredentials(AWSProperty): props = { - 'ApiToken': (basestring, True), + 'ApiToken': (str, True), } class ConnectorOAuthRequest(AWSProperty): props = { - 'AuthCode': (basestring, False), - 'RedirectUri': (basestring, False), + 'AuthCode': (str, False), + 'RedirectUri': (str, False), } class GoogleAnalyticsConnectorProfileCredentials(AWSProperty): props = { - 'AccessToken': (basestring, False), - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), + 'AccessToken': (str, False), + 'ClientId': (str, True), + 'ClientSecret': (str, True), 'ConnectorOAuthRequest': (ConnectorOAuthRequest, False), - 'RefreshToken': (basestring, False), + 'RefreshToken': (str, False), } class InforNexusConnectorProfileCredentials(AWSProperty): props = { - 'AccessKeyId': (basestring, True), - 'Datakey': (basestring, True), - 'SecretAccessKey': (basestring, True), - 'UserId': (basestring, True), + 'AccessKeyId': (str, True), + 'Datakey': (str, True), + 'SecretAccessKey': (str, True), + 'UserId': (str, True), } class MarketoConnectorProfileCredentials(AWSProperty): props = { - 'AccessToken': (basestring, False), - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), + 'AccessToken': (str, False), + 'ClientId': (str, True), + 'ClientSecret': (str, True), 'ConnectorOAuthRequest': (ConnectorOAuthRequest, False), } class RedshiftConnectorProfileCredentials(AWSProperty): props = { - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class SalesforceConnectorProfileCredentials(AWSProperty): props = { - 'AccessToken': (basestring, False), + 'AccessToken': (str, False), 'ConnectorOAuthRequest': (ConnectorOAuthRequest, False), - 'RefreshToken': (basestring, False), + 'RefreshToken': (str, False), } class ServiceNowConnectorProfileCredentials(AWSProperty): props = { - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class SingularConnectorProfileCredentials(AWSProperty): props = { - 'ApiKey': (basestring, True), + 'ApiKey': (str, True), } class SlackConnectorProfileCredentials(AWSProperty): props = { - 'AccessToken': (basestring, False), - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), + 'AccessToken': (str, False), + 'ClientId': (str, True), + 'ClientSecret': (str, True), 'ConnectorOAuthRequest': (ConnectorOAuthRequest, False), } class SnowflakeConnectorProfileCredentials(AWSProperty): props = { - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class TrendmicroConnectorProfileCredentials(AWSProperty): props = { - 'ApiSecretKey': (basestring, True), + 'ApiSecretKey': (str, True), } class VeevaConnectorProfileCredentials(AWSProperty): props = { - 'Password': (basestring, True), - 'Username': (basestring, True), + 'Password': (str, True), + 'Username': (str, True), } class ZendeskConnectorProfileCredentials(AWSProperty): props = { - 'AccessToken': (basestring, False), - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), + 'AccessToken': (str, False), + 'ClientId': (str, True), + 'ClientSecret': (str, True), 'ConnectorOAuthRequest': (ConnectorOAuthRequest, False), } @@ -158,77 +158,77 @@ class ConnectorProfileCredentials(AWSProperty): class DatadogConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class DynatraceConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class InforNexusConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class MarketoConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class RedshiftConnectorProfileProperties(AWSProperty): props = { - 'BucketName': (basestring, True), - 'BucketPrefix': (basestring, False), - 'DatabaseUrl': (basestring, True), - 'RoleArn': (basestring, True), + 'BucketName': (str, True), + 'BucketPrefix': (str, False), + 'DatabaseUrl': (str, True), + 'RoleArn': (str, True), } class SalesforceConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, False), + 'InstanceUrl': (str, False), 'isSandboxEnvironment': (boolean, False), } class ServiceNowConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class SlackConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class SnowflakeConnectorProfileProperties(AWSProperty): props = { - 'AccountName': (basestring, False), - 'BucketName': (basestring, True), - 'BucketPrefix': (basestring, False), - 'PrivateLinkServiceName': (basestring, False), - 'Region': (basestring, False), - 'Stage': (basestring, True), - 'Warehouse': (basestring, True), + 'AccountName': (str, False), + 'BucketName': (str, True), + 'BucketPrefix': (str, False), + 'PrivateLinkServiceName': (str, False), + 'Region': (str, False), + 'Stage': (str, True), + 'Warehouse': (str, True), } class VeevaConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } class ZendeskConnectorProfileProperties(AWSProperty): props = { - 'InstanceUrl': (basestring, True), + 'InstanceUrl': (str, True), } @@ -259,18 +259,18 @@ class ConnectorProfile(AWSObject): resource_type = "AWS::AppFlow::ConnectorProfile" props = { - 'ConnectionMode': (basestring, True), + 'ConnectionMode': (str, True), 'ConnectorProfileConfig': (ConnectorProfileConfig, False), - 'ConnectorProfileName': (basestring, True), - 'ConnectorType': (basestring, True), - 'KMSArn': (basestring, False), + 'ConnectorProfileName': (str, True), + 'ConnectorType': (str, True), + 'KMSArn': (str, False), } class ErrorHandlingConfig(AWSProperty): props = { - 'BucketName': (basestring, False), - 'BucketPrefix': (basestring, False), + 'BucketName': (str, False), + 'BucketPrefix': (str, False), 'FailOnFirstError': (boolean, False), } @@ -278,44 +278,44 @@ class ErrorHandlingConfig(AWSProperty): class EventBridgeDestinationProperties(AWSProperty): props = { 'ErrorHandlingConfig': (ErrorHandlingConfig, False), - 'Object': (basestring, True), + 'Object': (str, True), } class RedshiftDestinationProperties(AWSProperty): props = { - 'BucketPrefix': (basestring, False), + 'BucketPrefix': (str, False), 'ErrorHandlingConfig': (ErrorHandlingConfig, False), - 'IntermediateBucketName': (basestring, True), - 'Object': (basestring, True), + 'IntermediateBucketName': (str, True), + 'Object': (str, True), } class AggregationConfig(AWSProperty): props = { - 'AggregationType': (basestring, False), + 'AggregationType': (str, False), } class PrefixConfig(AWSProperty): props = { - 'PrefixFormat': (basestring, False), - 'PrefixType': (basestring, False), + 'PrefixFormat': (str, False), + 'PrefixType': (str, False), } class S3OutputFormatConfig(AWSProperty): props = { 'AggregationConfig': (AggregationConfig, False), - 'FileType': (basestring, False), + 'FileType': (str, False), 'PrefixConfig': (PrefixConfig, False), } class S3DestinationProperties(AWSProperty): props = { - 'BucketName': (basestring, True), - 'BucketPrefix': (basestring, False), + 'BucketName': (str, True), + 'BucketPrefix': (str, False), 'S3OutputFormatConfig': (S3OutputFormatConfig, False), } @@ -323,16 +323,16 @@ class S3DestinationProperties(AWSProperty): class SalesforceDestinationProperties(AWSProperty): props = { 'ErrorHandlingConfig': (ErrorHandlingConfig, False), - 'Object': (basestring, True), + 'Object': (str, True), } class SnowflakeDestinationProperties(AWSProperty): props = { - 'BucketPrefix': (basestring, False), + 'BucketPrefix': (str, False), 'ErrorHandlingConfig': (ErrorHandlingConfig, False), - 'IntermediateBucketName': (basestring, True), - 'Object': (basestring, True), + 'IntermediateBucketName': (str, True), + 'Object': (str, True), } @@ -348,8 +348,8 @@ class DestinationConnectorProperties(AWSProperty): class DestinationFlowConfig(AWSProperty): props = { - 'ConnectorProfileName': (basestring, False), - 'ConnectorType': (basestring, True), + 'ConnectorProfileName': (str, False), + 'ConnectorType': (str, True), 'DestinationConnectorProperties': (DestinationConnectorProperties, True), } @@ -357,44 +357,44 @@ class DestinationFlowConfig(AWSProperty): class AmplitudeSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class DatadogSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class DynatraceSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class GoogleAnalyticsSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class InforNexusSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class MarketoSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class S3SourceProperties(AWSProperty): props = { - 'BucketName': (basestring, True), - 'BucketPrefix': (basestring, True), + 'BucketName': (str, True), + 'BucketPrefix': (str, True), } @@ -402,43 +402,43 @@ class SalesforceSourceProperties(AWSProperty): props = { 'EnableDynamicFieldUpdate': (boolean, False), 'IncludeDeletedRecords': (boolean, False), - 'Object': (basestring, True), + 'Object': (str, True), } class ServiceNowSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class SingularSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class SlackSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class TrendmicroSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class VeevaSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } class ZendeskSourceProperties(AWSProperty): props = { - 'Object': (basestring, True), + 'Object': (str, True), } @@ -463,62 +463,62 @@ class SourceConnectorProperties(AWSProperty): class SourceFlowConfig(AWSProperty): props = { - 'ConnectorProfileName': (basestring, False), - 'ConnectorType': (basestring, True), + 'ConnectorProfileName': (str, False), + 'ConnectorType': (str, True), 'SourceConnectorProperties': (SourceConnectorProperties, True), } class ConnectorOperator(AWSProperty): props = { - 'Amplitude': (basestring, False), - 'Datadog': (basestring, False), - 'Dynatrace': (basestring, False), - 'GoogleAnalytics': (basestring, False), - 'InforNexus': (basestring, False), - 'Marketo': (basestring, False), - 'S3': (basestring, False), - 'Salesforce': (basestring, False), - 'ServiceNow': (basestring, False), - 'Singular': (basestring, False), - 'Slack': (basestring, False), - 'Trendmicro': (basestring, False), - 'Veeva': (basestring, False), - 'Zendesk': (basestring, False), + 'Amplitude': (str, False), + 'Datadog': (str, False), + 'Dynatrace': (str, False), + 'GoogleAnalytics': (str, False), + 'InforNexus': (str, False), + 'Marketo': (str, False), + 'S3': (str, False), + 'Salesforce': (str, False), + 'ServiceNow': (str, False), + 'Singular': (str, False), + 'Slack': (str, False), + 'Trendmicro': (str, False), + 'Veeva': (str, False), + 'Zendesk': (str, False), } class TaskPropertiesObject(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } class Task(AWSProperty): props = { 'ConnectorOperator': (ConnectorOperator, False), - 'DestinationField': (basestring, False), - 'SourceFields': ([basestring], True), + 'DestinationField': (str, False), + 'SourceFields': ([str], True), 'TaskProperties': ([TaskPropertiesObject], False), - 'TaskType': (basestring, True), + 'TaskType': (str, True), } class ScheduledTriggerProperties(AWSProperty): props = { - 'DataPullMode': (basestring, False), + 'DataPullMode': (str, False), 'ScheduleEndTime': (double, False), - 'ScheduleExpression': (basestring, True), + 'ScheduleExpression': (str, True), 'ScheduleStartTime': (double, False), - 'TimeZone': (basestring, False), + 'TimeZone': (str, False), } class TriggerConfig(AWSProperty): props = { 'TriggerProperties': (ScheduledTriggerProperties, False), - 'TriggerType': (basestring, True), + 'TriggerType': (str, True), } @@ -526,10 +526,10 @@ class Flow(AWSObject): resource_type = "AWS::AppFlow::Flow" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'DestinationFlowConfigList': ([DestinationFlowConfig], True), - 'FlowName': (basestring, True), - 'KMSArn': (basestring, False), + 'FlowName': (str, True), + 'KMSArn': (str, False), 'SourceFlowConfig': (SourceFlowConfig, True), 'Tags': (Tags, False), 'Tasks': ([Task], True), diff --git a/troposphere/applicationautoscaling.py b/troposphere/applicationautoscaling.py index 90c6947e6..43e442d3a 100644 --- a/troposphere/applicationautoscaling.py +++ b/troposphere/applicationautoscaling.py @@ -11,11 +11,11 @@ class ScalableTargetAction(AWSProperty): class ScheduledAction(AWSProperty): props = { - 'EndTime': (basestring, False), + 'EndTime': (str, False), 'ScalableTargetAction': (ScalableTargetAction, False), - 'Schedule': (basestring, True), - 'ScheduledActionName': (basestring, True), - 'StartTime': (basestring, False), + 'Schedule': (str, True), + 'ScheduledActionName': (str, True), + 'StartTime': (str, False), } @@ -33,11 +33,11 @@ class ScalableTarget(AWSObject): props = { 'MaxCapacity': (integer, True), 'MinCapacity': (integer, True), - 'ResourceId': (basestring, True), - 'RoleARN': (basestring, True), - 'ScalableDimension': (basestring, True), + 'ResourceId': (str, True), + 'RoleARN': (str, True), + 'ScalableDimension': (str, True), 'ScheduledActions': ([ScheduledAction], False), - 'ServiceNamespace': (basestring, True), + 'ServiceNamespace': (str, True), 'SuspendedState': (SuspendedState, False), } @@ -52,9 +52,9 @@ class StepAdjustment(AWSProperty): class StepScalingPolicyConfiguration(AWSProperty): props = { - 'AdjustmentType': (basestring, False), + 'AdjustmentType': (str, False), 'Cooldown': (integer, False), - 'MetricAggregationType': (basestring, False), + 'MetricAggregationType': (str, False), 'MinAdjustmentMagnitude': (integer, False), 'StepAdjustments': ([StepAdjustment], False), } @@ -62,25 +62,25 @@ class StepScalingPolicyConfiguration(AWSProperty): class MetricDimension(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class CustomizedMetricSpecification(AWSProperty): props = { 'Dimensions': ([MetricDimension], False), - 'MetricName': (basestring, False), - 'Namespace': (basestring, False), - 'Statistic': (basestring, False), - 'Unit': (basestring, True), + 'MetricName': (str, False), + 'Namespace': (str, False), + 'Statistic': (str, False), + 'Unit': (str, True), } class PredefinedMetricSpecification(AWSProperty): props = { - 'PredefinedMetricType': (basestring, True), - 'ResourceLabel': (basestring, False), + 'PredefinedMetricType': (str, True), + 'ResourceLabel': (str, False), } @@ -101,12 +101,12 @@ class ScalingPolicy(AWSObject): resource_type = "AWS::ApplicationAutoScaling::ScalingPolicy" props = { - 'PolicyName': (basestring, True), - 'PolicyType': (basestring, False), - 'ResourceId': (basestring, False), - 'ScalableDimension': (basestring, False), - 'ServiceNamespace': (basestring, False), - 'ScalingTargetId': (basestring, False), + 'PolicyName': (str, True), + 'PolicyType': (str, False), + 'ResourceId': (str, False), + 'ScalableDimension': (str, False), + 'ServiceNamespace': (str, False), + 'ScalingTargetId': (str, False), 'StepScalingPolicyConfiguration': ( StepScalingPolicyConfiguration, False, diff --git a/troposphere/applicationinsights.py b/troposphere/applicationinsights.py index ddf6bcabd..941ad1930 100644 --- a/troposphere/applicationinsights.py +++ b/troposphere/applicationinsights.py @@ -16,33 +16,33 @@ class Alarm(AWSProperty): props = { - 'AlarmName': (basestring, True), - 'Severity': (basestring, False), + 'AlarmName': (str, True), + 'Severity': (str, False), } class AlarmMetric(AWSProperty): props = { - 'AlarmMetricName': (basestring, True), + 'AlarmMetricName': (str, True), } class Log(AWSProperty): props = { - 'Encoding': (basestring, False), - 'LogGroupName': (basestring, False), - 'LogPath': (basestring, False), - 'LogType': (basestring, True), - 'PatternSet': (basestring, False), + 'Encoding': (str, False), + 'LogGroupName': (str, False), + 'LogPath': (str, False), + 'LogType': (str, True), + 'PatternSet': (str, False), } class WindowsEvent(AWSProperty): props = { - 'EventLevels': ([basestring], True), - 'EventName': (basestring, True), - 'LogGroupName': (basestring, True), - 'PatternSet': (basestring, False), + 'EventLevels': ([str], True), + 'EventName': (str, True), + 'LogGroupName': (str, True), + 'PatternSet': (str, False), } @@ -67,7 +67,7 @@ class SubComponentTypeConfiguration(AWSProperty): props = { 'SubComponentConfigurationDetails': (SubComponentConfigurationDetails, True), - 'SubComponentType': (basestring, True), + 'SubComponentType': (str, True), } @@ -81,27 +81,27 @@ class ComponentConfiguration(AWSProperty): class ComponentMonitoringSetting(AWSProperty): props = { - 'ComponentARN': (basestring, False), - 'ComponentConfigurationMode': (basestring, False), - 'ComponentName': (basestring, False), + 'ComponentARN': (str, False), + 'ComponentConfigurationMode': (str, False), + 'ComponentName': (str, False), 'CustomComponentConfiguration': (ComponentConfiguration, False), 'DefaultOverwriteComponentConfiguration': (ComponentConfiguration, False), - 'Tier': (basestring, False), + 'Tier': (str, False), } class CustomComponent(AWSProperty): props = { - 'ComponentName': (basestring, True), - 'ResourceList': ([basestring], True), + 'ComponentName': (str, True), + 'ResourceList': ([str], True), } class LogPattern(AWSProperty): props = { - 'Pattern': (basestring, True), - 'PatternName': (basestring, True), + 'Pattern': (str, True), + 'PatternName': (str, True), 'Rank': (integer, True), } @@ -109,7 +109,7 @@ class LogPattern(AWSProperty): class LogPatternSet(AWSProperty): props = { 'LogPatterns': ([LogPattern], True), - 'PatternSetName': (basestring, True), + 'PatternSetName': (str, True), } @@ -124,7 +124,7 @@ class Application(AWSObject): 'CustomComponents': ([CustomComponent], False), 'LogPatternSets': ([LogPatternSet], False), 'OpsCenterEnabled': (boolean, False), - 'OpsItemSNSTopicArn': (basestring, False), - 'ResourceGroupName': (basestring, True), + 'OpsItemSNSTopicArn': (str, False), + 'ResourceGroupName': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/appmesh.py b/troposphere/appmesh.py index 004301681..320de7a7e 100644 --- a/troposphere/appmesh.py +++ b/troposphere/appmesh.py @@ -28,7 +28,7 @@ def validate_listenertls_mode(listenertls_mode): class GatewayRouteVirtualService(AWSProperty): props = { - 'VirtualServiceName': (basestring, True), + 'VirtualServiceName': (str, True), } @@ -46,7 +46,7 @@ class GrpcGatewayRouteAction(AWSProperty): class GrpcGatewayRouteMatch(AWSProperty): props = { - 'ServiceName': (basestring, False), + 'ServiceName': (str, False), } @@ -65,7 +65,7 @@ class HttpGatewayRouteAction(AWSProperty): class HttpGatewayRouteMatch(AWSProperty): props = { - 'Prefix': (basestring, True), + 'Prefix': (str, True), } @@ -88,18 +88,18 @@ class GatewayRoute(AWSObject): resource_type = "AWS::AppMesh::GatewayRoute" props = { - 'GatewayRouteName': (basestring, False), - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), + 'GatewayRouteName': (str, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), 'Spec': (GatewayRouteSpec, True), 'Tags': (Tags, False), - 'VirtualGatewayName': (basestring, True), + 'VirtualGatewayName': (str, True), } class EgressFilter(AWSProperty): props = { - 'Type': (basestring, True), + 'Type': (str, True), } @@ -113,7 +113,7 @@ class Mesh(AWSObject): resource_type = "AWS::AppMesh::Mesh" props = { - 'MeshName': (basestring, False), + 'MeshName': (str, False), 'Spec': (MeshSpec, False), 'Tags': (Tags, False), } @@ -121,24 +121,24 @@ class Mesh(AWSObject): class Duration(AWSProperty): props = { - 'Unit': (basestring, True), + 'Unit': (str, True), 'Value': (integer, True), } class GrpcRetryPolicy(AWSProperty): props = { - 'GrpcRetryEvents': ([basestring], False), - 'HttpRetryEvents': ([basestring], False), + 'GrpcRetryEvents': ([str], False), + 'HttpRetryEvents': ([str], False), 'MaxRetries': (integer, True), 'PerRetryTimeout': (Duration, True), - 'TcpRetryEvents': ([basestring], False), + 'TcpRetryEvents': ([str], False), } class WeightedTarget(AWSProperty): props = { - 'VirtualNode': (basestring, True), + 'VirtualNode': (str, True), 'Weight': (integer, True), } @@ -158,11 +158,11 @@ class MatchRange(AWSProperty): class GrpcRouteMetadataMatchMethod(AWSProperty): props = { - 'Exact': (basestring, False), - 'Prefix': (basestring, False), + 'Exact': (str, False), + 'Prefix': (str, False), 'Range': (MatchRange, False), - 'Regex': (basestring, False), - 'Suffix': (basestring, False), + 'Regex': (str, False), + 'Suffix': (str, False), } @@ -170,15 +170,15 @@ class GrpcRouteMetadata(AWSProperty): props = { 'Invert': (boolean, False), 'Match': (GrpcRouteMetadataMatchMethod, False), - 'Name': (basestring, True), + 'Name': (str, True), } class GrpcRouteMatch(AWSProperty): props = { 'Metadata': ([GrpcRouteMetadata], False), - 'MethodName': (basestring, False), - 'ServiceName': (basestring, False), + 'MethodName': (str, False), + 'ServiceName': (str, False), } @@ -200,10 +200,10 @@ class GrpcRoute(AWSProperty): class HttpRetryPolicy(AWSProperty): props = { - 'HttpRetryEvents': ([basestring], False), + 'HttpRetryEvents': ([str], False), 'MaxRetries': (integer, True), 'PerRetryTimeout': (Duration, True), - 'TcpRetryEvents': ([basestring], False), + 'TcpRetryEvents': ([str], False), } @@ -215,11 +215,11 @@ class HttpRouteAction(AWSProperty): class HeaderMatchMethod(AWSProperty): props = { - 'Exact': (basestring, False), - 'Prefix': (basestring, False), + 'Exact': (str, False), + 'Prefix': (str, False), 'Range': (MatchRange, False), - 'Regex': (basestring, False), - 'Suffix': (basestring, False), + 'Regex': (str, False), + 'Suffix': (str, False), } @@ -227,16 +227,16 @@ class HttpRouteHeader(AWSProperty): props = { 'Invert': (boolean, False), 'Match': (HeaderMatchMethod, False), - 'Name': (basestring, True), + 'Name': (str, True), } class HttpRouteMatch(AWSProperty): props = { 'Headers': ([HttpRouteHeader], False), - 'Method': (basestring, False), - 'Prefix': (basestring, True), - 'Scheme': (basestring, False), + 'Method': (str, False), + 'Prefix': (str, True), + 'Scheme': (str, False), } @@ -289,25 +289,25 @@ class Route(AWSObject): resource_type = "AWS::AppMesh::Route" props = { - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), - 'RouteName': (basestring, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), + 'RouteName': (str, False), 'Spec': (RouteSpec, True), 'Tags': (Tags, False), - 'VirtualRouterName': (basestring, True), + 'VirtualRouterName': (str, True), } class VirtualGatewayListenerTlsFileCertificate(AWSProperty): props = { - 'CertificateChain': (basestring, True), - 'PrivateKey': (basestring, True), + 'CertificateChain': (str, True), + 'PrivateKey': (str, True), } class VirtualGatewayListenerTlsSdsCertificate(AWSProperty): props = { - 'SecretName': (basestring, True), + 'SecretName': (str, True), } @@ -320,7 +320,7 @@ class VirtualGatewayClientTlsCertificate(AWSProperty): class SubjectAlternativeNameMatchers(AWSProperty): props = { - 'Exact': ([basestring], False), + 'Exact': ([str], False), } @@ -332,19 +332,19 @@ class SubjectAlternativeNames(AWSProperty): class VirtualGatewayTlsValidationContextAcmTrust(AWSProperty): props = { - 'CertificateAuthorityArns': ([basestring], True), + 'CertificateAuthorityArns': ([str], True), } class VirtualGatewayTlsValidationContextFileTrust(AWSProperty): props = { - 'CertificateChain': (basestring, True), + 'CertificateChain': (str, True), } class VirtualGatewayTlsValidationContextSdsTrust(AWSProperty): props = { - 'SecretName': (basestring, True), + 'SecretName': (str, True), } @@ -415,9 +415,9 @@ class VirtualGatewayHealthCheckPolicy(AWSProperty): props = { 'HealthyThreshold': (integer, True), 'IntervalMillis': (integer, True), - 'Path': (basestring, False), + 'Path': (str, False), 'Port': (integer, False), - 'Protocol': (basestring, True), + 'Protocol': (str, True), 'TimeoutMillis': (integer, True), 'UnhealthyThreshold': (integer, True), } @@ -425,7 +425,7 @@ class VirtualGatewayHealthCheckPolicy(AWSProperty): class VirtualGatewayListenerTlsAcmCertificate(AWSProperty): props = { - 'CertificateArn': (basestring, True), + 'CertificateArn': (str, True), } @@ -454,7 +454,7 @@ class VirtualGatewayListenerTlsValidationContext(AWSProperty): class VirtualGatewayListenerTls(AWSProperty): props = { 'Certificate': (VirtualGatewayListenerTlsCertificate, True), - 'Mode': (basestring, True), + 'Mode': (str, True), 'Validation': (VirtualGatewayListenerTlsValidationContext, False), } @@ -462,7 +462,7 @@ class VirtualGatewayListenerTls(AWSProperty): class VirtualGatewayPortMapping(AWSProperty): props = { 'Port': (integer, True), - 'Protocol': (basestring, True), + 'Protocol': (str, True), } @@ -477,7 +477,7 @@ class VirtualGatewayListener(AWSProperty): class VirtualGatewayFileAccessLog(AWSProperty): props = { - 'Path': (basestring, True), + 'Path': (str, True), } @@ -505,24 +505,24 @@ class VirtualGateway(AWSObject): resource_type = "AWS::AppMesh::VirtualGateway" props = { - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), 'Spec': (VirtualGatewaySpec, True), 'Tags': (Tags, False), - 'VirtualGatewayName': (basestring, False), + 'VirtualGatewayName': (str, False), } class ListenerTlsFileCertificate(AWSProperty): props = { - 'CertificateChain': (basestring, True), - 'PrivateKey': (basestring, True), + 'CertificateChain': (str, True), + 'PrivateKey': (str, True), } class ListenerTlsSdsCertificate(AWSProperty): props = { - 'SecretName': (basestring, True), + 'SecretName': (str, True), } @@ -535,19 +535,19 @@ class ClientTlsCertificate(AWSProperty): class TlsValidationContextAcmTrust(AWSProperty): props = { - 'CertificateAuthorityArns': ([basestring], True), + 'CertificateAuthorityArns': ([str], True), } class TlsValidationContextFileTrust(AWSProperty): props = { - 'CertificateChain': (basestring, True), + 'CertificateChain': (str, True), } class TlsValidationContextSdsTrust(AWSProperty): props = { - 'SecretName': (basestring, True), + 'SecretName': (str, True), } @@ -584,7 +584,7 @@ class ClientPolicy(AWSProperty): class VirtualServiceBackend(AWSProperty): props = { 'ClientPolicy': (ClientPolicy, False), - 'VirtualServiceName': (basestring, True), + 'VirtualServiceName': (str, True), } @@ -604,9 +604,9 @@ class HealthCheck(AWSProperty): props = { 'HealthyThreshold': (integer, True), 'IntervalMillis': (integer, True), - 'Path': (basestring, False), + 'Path': (str, False), 'Port': (integer, False), - 'Protocol': (basestring, True), + 'Protocol': (str, True), 'TimeoutMillis': (integer, True), 'UnhealthyThreshold': (integer, True), } @@ -623,7 +623,7 @@ class ListenerTimeout(AWSProperty): class ListenerTlsAcmCertificate(AWSProperty): props = { - 'CertificateArn': (basestring, True), + 'CertificateArn': (str, True), } @@ -669,7 +669,7 @@ class OutlierDetection(AWSProperty): class PortMapping(AWSProperty): props = { 'Port': (integer, True), - 'Protocol': (basestring, True), + 'Protocol': (str, True), } @@ -720,7 +720,7 @@ class Listener(AWSProperty): class FileAccessLog(AWSProperty): props = { - 'Path': (basestring, True), + 'Path': (str, True), } @@ -738,22 +738,22 @@ class Logging(AWSProperty): class AwsCloudMapInstanceAttribute(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } class AwsCloudMapServiceDiscovery(AWSProperty): props = { 'Attributes': ([AwsCloudMapInstanceAttribute], False), - 'NamespaceName': (basestring, True), - 'ServiceName': (basestring, True), + 'NamespaceName': (str, True), + 'ServiceName': (str, True), } class DnsServiceDiscovery(AWSProperty): props = { - 'Hostname': (basestring, True), + 'Hostname': (str, True), } @@ -778,11 +778,11 @@ class VirtualNode(AWSObject): resource_type = "AWS::AppMesh::VirtualNode" props = { - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), 'Spec': (VirtualNodeSpec, True), 'Tags': (Tags, False), - 'VirtualNodeName': (basestring, False), + 'VirtualNodeName': (str, False), } @@ -802,23 +802,23 @@ class VirtualRouter(AWSObject): resource_type = "AWS::AppMesh::VirtualRouter" props = { - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), 'Spec': (VirtualRouterSpec, True), 'Tags': (Tags, False), - 'VirtualRouterName': (basestring, False), + 'VirtualRouterName': (str, False), } class VirtualNodeServiceProvider(AWSProperty): props = { - 'VirtualNodeName': (basestring, True), + 'VirtualNodeName': (str, True), } class VirtualRouterServiceProvider(AWSProperty): props = { - 'VirtualRouterName': (basestring, True), + 'VirtualRouterName': (str, True), } @@ -839,9 +839,9 @@ class VirtualService(AWSObject): resource_type = "AWS::AppMesh::VirtualService" props = { - 'MeshName': (basestring, True), - 'MeshOwner': (basestring, False), + 'MeshName': (str, True), + 'MeshOwner': (str, False), 'Spec': (VirtualServiceSpec, True), 'Tags': (Tags, False), - 'VirtualServiceName': (basestring, True), + 'VirtualServiceName': (str, True), } diff --git a/troposphere/appstream.py b/troposphere/appstream.py index 8736caba0..969f5c383 100644 --- a/troposphere/appstream.py +++ b/troposphere/appstream.py @@ -16,8 +16,8 @@ class ServiceAccountCredentials(AWSProperty): props = { - 'AccountName': (basestring, True), - 'AccountPassword': (basestring, True), + 'AccountName': (str, True), + 'AccountPassword': (str, True), } @@ -25,8 +25,8 @@ class DirectoryConfig(AWSObject): resource_type = "AWS::AppStream::DirectoryConfig" props = { - 'DirectoryName': (basestring, True), - 'OrganizationalUnitDistinguishedNames': ([basestring], True), + 'DirectoryName': (str, True), + 'OrganizationalUnitDistinguishedNames': ([str], True), 'ServiceAccountCredentials': (ServiceAccountCredentials, True), } @@ -39,15 +39,15 @@ class ComputeCapacity(AWSProperty): class DomainJoinInfo(AWSProperty): props = { - 'DirectoryName': (basestring, False), - 'OrganizationalUnitDistinguishedName': (basestring, False), + 'DirectoryName': (str, False), + 'OrganizationalUnitDistinguishedName': (str, False), } class VpcConfig(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], False), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], False), } @@ -56,20 +56,20 @@ class Fleet(AWSObject): props = { 'ComputeCapacity': (ComputeCapacity, True), - 'Description': (basestring, False), + 'Description': (str, False), 'DisconnectTimeoutInSeconds': (integer, False), - 'DisplayName': (basestring, False), + 'DisplayName': (str, False), 'DomainJoinInfo': (DomainJoinInfo, False), 'EnableDefaultInternetAccess': (boolean, False), - 'FleetType': (basestring, False), - 'IamRoleArn': (basestring, False), + 'FleetType': (str, False), + 'IamRoleArn': (str, False), 'IdleDisconnectTimeoutInSeconds': (integer, False), - 'ImageArn': (basestring, False), - 'ImageName': (basestring, False), - 'InstanceType': (basestring, True), + 'ImageArn': (str, False), + 'ImageName': (str, False), + 'InstanceType': (str, True), 'MaxUserDurationInSeconds': (integer, False), - 'Name': (basestring, False), - 'StreamView': (basestring, False), + 'Name': (str, False), + 'StreamView': (str, False), 'Tags': ((Tags, list), False), 'VpcConfig': (VpcConfig, False), } @@ -77,8 +77,8 @@ class Fleet(AWSObject): class AccessEndpoint(AWSProperty): props = { - 'EndpointType': (basestring, True), - 'VpceId': (basestring, True), + 'EndpointType': (str, True), + 'VpceId': (str, True), } @@ -87,16 +87,16 @@ class ImageBuilder(AWSObject): props = { 'AccessEndpoints': ([AccessEndpoint], False), - 'AppstreamAgentVersion': (basestring, False), - 'Description': (basestring, False), - 'DisplayName': (basestring, False), + 'AppstreamAgentVersion': (str, False), + 'Description': (str, False), + 'DisplayName': (str, False), 'DomainJoinInfo': (DomainJoinInfo, False), 'EnableDefaultInternetAccess': (boolean, False), - 'IamRoleArn': (basestring, False), - 'ImageArn': (basestring, False), - 'ImageName': (basestring, False), - 'InstanceType': (basestring, True), - 'Name': (basestring, False), + 'IamRoleArn': (str, False), + 'ImageArn': (str, False), + 'ImageName': (str, False), + 'InstanceType': (str, True), + 'Name': (str, False), 'Tags': ((Tags, list), False), 'VpcConfig': (VpcConfig, False), } @@ -105,22 +105,22 @@ class ImageBuilder(AWSObject): class ApplicationSettings(AWSProperty): props = { 'Enabled': (boolean, True), - 'SettingsGroup': (basestring, False), + 'SettingsGroup': (str, False), } class StorageConnector(AWSProperty): props = { - 'ConnectorType': (basestring, True), - 'Domains': ([basestring], False), - 'ResourceIdentifier': (basestring, False), + 'ConnectorType': (str, True), + 'Domains': ([str], False), + 'ResourceIdentifier': (str, False), } class UserSetting(AWSProperty): props = { - 'Action': (basestring, True), - 'Permission': (basestring, True), + 'Action': (str, True), + 'Permission': (str, True), } @@ -130,14 +130,14 @@ class Stack(AWSObject): props = { 'AccessEndpoints': ([AccessEndpoint], False), 'ApplicationSettings': (ApplicationSettings, False), - 'AttributesToDelete': ([basestring], False), + 'AttributesToDelete': ([str], False), 'DeleteStorageConnectors': (boolean, False), - 'Description': (basestring, False), - 'DisplayName': (basestring, False), - 'EmbedHostDomains': ([basestring], False), - 'FeedbackURL': (basestring, False), - 'Name': (basestring, False), - 'RedirectURL': (basestring, False), + 'Description': (str, False), + 'DisplayName': (str, False), + 'EmbedHostDomains': ([str], False), + 'FeedbackURL': (str, False), + 'Name': (str, False), + 'RedirectURL': (str, False), 'StorageConnectors': ([StorageConnector], False), 'Tags': ((Tags, list), False), 'UserSettings': ([UserSetting], False), @@ -148,8 +148,8 @@ class StackFleetAssociation(AWSObject): resource_type = "AWS::AppStream::StackFleetAssociation" props = { - 'FleetName': (basestring, True), - 'StackName': (basestring, True), + 'FleetName': (str, True), + 'StackName': (str, True), } @@ -157,10 +157,10 @@ class StackUserAssociation(AWSObject): resource_type = "AWS::AppStream::StackUserAssociation" props = { - 'AuthenticationType': (basestring, True), + 'AuthenticationType': (str, True), 'SendEmailNotification': (boolean, False), - 'StackName': (basestring, True), - 'UserName': (basestring, True), + 'StackName': (str, True), + 'UserName': (str, True), } @@ -168,9 +168,9 @@ class User(AWSObject): resource_type = "AWS::AppStream::User" props = { - 'AuthenticationType': (basestring, True), - 'FirstName': (basestring, False), - 'LastName': (basestring, False), - 'MessageAction': (basestring, False), - 'UserName': (basestring, True), + 'AuthenticationType': (str, True), + 'FirstName': (str, False), + 'LastName': (str, False), + 'MessageAction': (str, False), + 'UserName': (str, True), } diff --git a/troposphere/appsync.py b/troposphere/appsync.py index 39a46b0ba..0ad021ee9 100644 --- a/troposphere/appsync.py +++ b/troposphere/appsync.py @@ -22,12 +22,12 @@ class ApiCache(AWSObject): resource_type = "AWS::AppSync::ApiCache" props = { - 'ApiCachingBehavior': (basestring, True), - 'ApiId': (basestring, True), + 'ApiCachingBehavior': (str, True), + 'ApiId': (str, True), 'AtRestEncryptionEnabled': (boolean, False), 'TransitEncryptionEnabled': (boolean, False), 'Ttl': (double, True), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -35,26 +35,26 @@ class ApiKey(AWSObject): resource_type = "AWS::AppSync::ApiKey" props = { - 'ApiId': (basestring, True), - 'ApiKeyId': (basestring, False), - 'Description': (basestring, False), + 'ApiId': (str, True), + 'ApiKeyId': (str, False), + 'Description': (str, False), 'Expires': (double, False), } class DeltaSyncConfig(AWSProperty): props = { - 'BaseTableTTL': (basestring, True), - 'DeltaSyncTableName': (basestring, True), - 'DeltaSyncTableTTL': (basestring, True), + 'BaseTableTTL': (str, True), + 'DeltaSyncTableName': (str, True), + 'DeltaSyncTableTTL': (str, True), } class DynamoDBConfig(AWSProperty): props = { - 'AwsRegion': (basestring, True), + 'AwsRegion': (str, True), 'DeltaSyncConfig': (DeltaSyncConfig, False), - 'TableName': (basestring, True), + 'TableName': (str, True), 'UseCallerCredentials': (boolean, False), 'Versioned': (boolean, False), } @@ -62,21 +62,21 @@ class DynamoDBConfig(AWSProperty): class ElasticsearchConfig(AWSProperty): props = { - 'AwsRegion': (basestring, True), - 'Endpoint': (basestring, True), + 'AwsRegion': (str, True), + 'Endpoint': (str, True), } class AwsIamConfig(AWSProperty): props = { - 'SigningRegion': (basestring, False), - 'SigningServiceName': (basestring, False), + 'SigningRegion': (str, False), + 'SigningServiceName': (str, False), } class AuthorizationConfig(AWSProperty): props = { - 'AuthorizationType': (basestring, True), + 'AuthorizationType': (str, True), 'AwsIamConfig': (AwsIamConfig, False), } @@ -84,30 +84,30 @@ class AuthorizationConfig(AWSProperty): class HttpConfig(AWSProperty): props = { 'AuthorizationConfig': (AuthorizationConfig, False), - 'Endpoint': (basestring, True), + 'Endpoint': (str, True), } class LambdaConfig(AWSProperty): props = { - 'LambdaFunctionArn': (basestring, True), + 'LambdaFunctionArn': (str, True), } class RdsHttpEndpointConfig(AWSProperty): props = { - 'AwsRegion': (basestring, True), - 'AwsSecretStoreArn': (basestring, True), - 'DatabaseName': (basestring, False), - 'DbClusterIdentifier': (basestring, True), - 'Schema': (basestring, False), + 'AwsRegion': (str, True), + 'AwsSecretStoreArn': (str, True), + 'DatabaseName': (str, False), + 'DbClusterIdentifier': (str, True), + 'Schema': (str, False), } class RelationalDatabaseConfig(AWSProperty): props = { 'RdsHttpEndpointConfig': (RdsHttpEndpointConfig, False), - 'RelationalDatasourceType': (basestring, True), + 'RelationalDatasourceType': (str, True), } @@ -115,16 +115,16 @@ class DataSource(AWSObject): resource_type = "AWS::AppSync::DataSource" props = { - 'ApiId': (basestring, True), - 'Description': (basestring, False), + 'ApiId': (str, True), + 'Description': (str, False), 'DynamoDBConfig': (DynamoDBConfig, False), 'ElasticsearchConfig': (ElasticsearchConfig, False), 'HttpConfig': (HttpConfig, False), 'LambdaConfig': (LambdaConfig, False), - 'Name': (basestring, True), + 'Name': (str, True), 'RelationalDatabaseConfig': (RelationalDatabaseConfig, False), - 'ServiceRoleArn': (basestring, False), - 'Type': (basestring, True), + 'ServiceRoleArn': (str, False), + 'Type': (str, True), } @@ -132,38 +132,38 @@ class FunctionConfiguration(AWSObject): resource_type = "AWS::AppSync::FunctionConfiguration" props = { - 'ApiId': (basestring, True), - 'DataSourceName': (basestring, True), - 'Description': (basestring, False), - 'FunctionVersion': (basestring, True), - 'Name': (basestring, True), - 'RequestMappingTemplate': (basestring, False), - 'RequestMappingTemplateS3Location': (basestring, False), - 'ResponseMappingTemplate': (basestring, False), - 'ResponseMappingTemplateS3Location': (basestring, False), + 'ApiId': (str, True), + 'DataSourceName': (str, True), + 'Description': (str, False), + 'FunctionVersion': (str, True), + 'Name': (str, True), + 'RequestMappingTemplate': (str, False), + 'RequestMappingTemplateS3Location': (str, False), + 'ResponseMappingTemplate': (str, False), + 'ResponseMappingTemplateS3Location': (str, False), } class CognitoUserPoolConfig(AWSProperty): props = { - 'AppIdClientRegex': (basestring, False), - 'AwsRegion': (basestring, False), - 'UserPoolId': (basestring, False), + 'AppIdClientRegex': (str, False), + 'AwsRegion': (str, False), + 'UserPoolId': (str, False), } class OpenIDConnectConfig(AWSProperty): props = { 'AuthTTL': (double, False), - 'ClientId': (basestring, False), + 'ClientId': (str, False), 'IatTTL': (double, False), - 'Issuer': (basestring, False), + 'Issuer': (str, False), } class AdditionalAuthenticationProvider(AWSProperty): props = { - 'AuthenticationType': (basestring, True), + 'AuthenticationType': (str, True), 'OpenIDConnectConfig': (OpenIDConnectConfig, False), 'UserPoolConfig': (CognitoUserPoolConfig, False), } @@ -171,18 +171,18 @@ class AdditionalAuthenticationProvider(AWSProperty): class LogConfig(AWSProperty): props = { - 'CloudWatchLogsRoleArn': (basestring, False), + 'CloudWatchLogsRoleArn': (str, False), 'ExcludeVerboseContent': (boolean, False), - 'FieldLogLevel': (basestring, False), + 'FieldLogLevel': (str, False), } class UserPoolConfig(AWSProperty): props = { - 'AppIdClientRegex': (basestring, False), - 'AwsRegion': (basestring, False), - 'DefaultAction': (basestring, False), - 'UserPoolId': (basestring, False), + 'AppIdClientRegex': (str, False), + 'AwsRegion': (str, False), + 'DefaultAction': (str, False), + 'UserPoolId': (str, False), } @@ -192,9 +192,9 @@ class GraphQLApi(AWSObject): props = { 'AdditionalAuthenticationProviders': ([AdditionalAuthenticationProvider], False), - 'AuthenticationType': (basestring, True), + 'AuthenticationType': (str, True), 'LogConfig': (LogConfig, False), - 'Name': (basestring, True), + 'Name': (str, True), 'OpenIDConnectConfig': (OpenIDConnectConfig, False), 'Tags': (Tags, False), 'UserPoolConfig': (UserPoolConfig, False), @@ -206,35 +206,35 @@ class GraphQLSchema(AWSObject): resource_type = "AWS::AppSync::GraphQLSchema" props = { - 'ApiId': (basestring, True), - 'Definition': (basestring, False), - 'DefinitionS3Location': (basestring, False), + 'ApiId': (str, True), + 'Definition': (str, False), + 'DefinitionS3Location': (str, False), } class CachingConfig(AWSProperty): props = { - 'CachingKeys': ([basestring], False), + 'CachingKeys': ([str], False), 'Ttl': (double, False), } class PipelineConfig(AWSProperty): props = { - 'Functions': ([basestring], False), + 'Functions': ([str], False), } class LambdaConflictHandlerConfig(AWSProperty): props = { - 'LambdaConflictHandlerArn': (basestring, False), + 'LambdaConflictHandlerArn': (str, False), } class SyncConfig(AWSProperty): props = { - 'ConflictDetection': (basestring, True), - 'ConflictHandler': (basestring, False), + 'ConflictDetection': (str, True), + 'ConflictHandler': (str, False), 'LambdaConflictHandlerConfig': (LambdaConflictHandlerConfig, False), } @@ -243,16 +243,16 @@ class Resolver(AWSObject): resource_type = "AWS::AppSync::Resolver" props = { - 'ApiId': (basestring, True), + 'ApiId': (str, True), 'CachingConfig': (CachingConfig, False), - 'DataSourceName': (basestring, False), - 'FieldName': (basestring, True), + 'DataSourceName': (str, False), + 'FieldName': (str, True), 'Kind': (resolver_kind_validator, False), 'PipelineConfig': (PipelineConfig, False), - 'RequestMappingTemplate': (basestring, False), - 'RequestMappingTemplateS3Location': (basestring, False), - 'ResponseMappingTemplate': (basestring, False), - 'ResponseMappingTemplateS3Location': (basestring, False), + 'RequestMappingTemplate': (str, False), + 'RequestMappingTemplateS3Location': (str, False), + 'ResponseMappingTemplate': (str, False), + 'ResponseMappingTemplateS3Location': (str, False), 'SyncConfig': (SyncConfig, False), - 'TypeName': (basestring, True), + 'TypeName': (str, True), } diff --git a/troposphere/ask.py b/troposphere/ask.py index a40f65748..c80cc7e6b 100644 --- a/troposphere/ask.py +++ b/troposphere/ask.py @@ -14,19 +14,19 @@ class Overrides(AWSProperty): class AuthenticationConfiguration(AWSProperty): props = { - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), - 'RefreshToken': (basestring, True), + 'ClientId': (str, True), + 'ClientSecret': (str, True), + 'RefreshToken': (str, True), } class SkillPackage(AWSProperty): props = { 'Overrides': (Overrides, False), - 'S3Bucket': (basestring, True), - 'S3BucketRole': (basestring, False), - 'S3Key': (basestring, True), - 'S3ObjectVersion': (basestring, False), + 'S3Bucket': (str, True), + 'S3BucketRole': (str, False), + 'S3Key': (str, True), + 'S3ObjectVersion': (str, False), } @@ -36,5 +36,5 @@ class Skill(AWSObject): props = { 'AuthenticationConfiguration': (AuthenticationConfiguration, True), 'SkillPackage': (SkillPackage, True), - 'VendorId': (basestring, True), + 'VendorId': (str, True), } diff --git a/troposphere/athena.py b/troposphere/athena.py index a83713014..dd5556bb7 100644 --- a/troposphere/athena.py +++ b/troposphere/athena.py @@ -33,11 +33,11 @@ class DataCatalog(AWSObject): resource_type = "AWS::Athena::DataCatalog" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Parameters': (dict, False), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -45,10 +45,10 @@ class NamedQuery(AWSObject): resource_type = "AWS::Athena::NamedQuery" props = { - 'Database': (basestring, True), - 'Description': (basestring, False), - 'Name': (basestring, False), - 'QueryString': (basestring, True), + 'Database': (str, True), + 'Description': (str, False), + 'Name': (str, False), + 'QueryString': (str, True), } @@ -56,14 +56,14 @@ class EncryptionConfiguration(AWSProperty): props = { 'EncryptionOption': (validate_encryptionconfiguration_encryptionoption, False), - 'KmsKey': (basestring, False), + 'KmsKey': (str, False), } class ResultConfiguration(AWSProperty): props = { 'EncryptionConfiguration': (EncryptionConfiguration, False), - 'OutputLocation': (basestring, False), + 'OutputLocation': (str, False), } @@ -80,7 +80,7 @@ class WorkGroupConfiguration(AWSProperty): class ResultConfigurationUpdates(AWSProperty): props = { 'EncryptionConfiguration': (EncryptionConfiguration, False), - 'OutputLocation': (basestring, False), + 'OutputLocation': (str, False), 'RemoveEncryptionConfiguration': (boolean, False), 'RemoveOutputLocation': (boolean, False), } @@ -101,8 +101,8 @@ class WorkGroup(AWSObject): resource_type = "AWS::Athena::WorkGroup" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'RecursiveDeleteOption': (boolean, False), 'State': (validate_workgroup_state, False), 'Tags': (Tags, False), diff --git a/troposphere/auditmanager.py b/troposphere/auditmanager.py index 5325a7253..e1f37f5b3 100644 --- a/troposphere/auditmanager.py +++ b/troposphere/auditmanager.py @@ -14,29 +14,29 @@ class AWSAccount(AWSProperty): props = { - 'EmailAddress': (basestring, False), - 'Id': (basestring, False), - 'Name': (basestring, False), + 'EmailAddress': (str, False), + 'Id': (str, False), + 'Name': (str, False), } class AssessmentReportsDestination(AWSProperty): props = { - 'Destination': (basestring, False), - 'DestinationType': (basestring, False), + 'Destination': (str, False), + 'DestinationType': (str, False), } class Role(AWSProperty): props = { - 'RoleArn': (basestring, False), - 'RoleType': (basestring, False), + 'RoleArn': (str, False), + 'RoleType': (str, False), } class AWSService(AWSProperty): props = { - 'ServiceName': (basestring, False), + 'ServiceName': (str, False), } @@ -54,11 +54,11 @@ class Assessment(AWSObject): 'AssessmentReportsDestination': (AssessmentReportsDestination, False), 'AwsAccount': (AWSAccount, False), - 'Description': (basestring, False), - 'FrameworkId': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'FrameworkId': (str, False), + 'Name': (str, False), 'Roles': ([Role], False), 'Scope': (Scope, False), - 'Status': (basestring, False), + 'Status': (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/autoscaling.py b/troposphere/autoscaling.py index e7a3b35ec..4ddc641de 100644 --- a/troposphere/autoscaling.py +++ b/troposphere/autoscaling.py @@ -39,7 +39,7 @@ class Tags(AWSHelperFn): def __init__(self, **kwargs): self.tags = [] - for k, v in sorted(kwargs.iteritems()): + for k, v in sorted(kwargs.items()): if type(v) in self.manyType: propagate = boolean(v[1]) v = v[0] @@ -62,34 +62,34 @@ def to_dict(self): class MetadataOptions(AWSProperty): props = { - 'HttpEndpoint': (basestring, False), + 'HttpEndpoint': (str, False), 'HttpPutResponseHopLimit': (integer, False), - 'HttpTokens': (basestring, False), + 'HttpTokens': (str, False), } class LifecycleHookSpecification(AWSProperty): props = { - 'DefaultResult': (basestring, False), + 'DefaultResult': (str, False), 'HeartbeatTimeout': (integer, False), - 'LifecycleHookName': (basestring, True), - 'LifecycleTransition': (basestring, True), - 'NotificationMetadata': (basestring, False), - 'NotificationTargetARN': (basestring, False), - 'RoleARN': (basestring, False), + 'LifecycleHookName': (str, True), + 'LifecycleTransition': (str, True), + 'NotificationMetadata': (str, False), + 'NotificationTargetARN': (str, False), + 'RoleARN': (str, False), } class NotificationConfigurations(AWSProperty): props = { - 'TopicARN': (basestring, True), + 'TopicARN': (str, True), 'NotificationTypes': (list, True), } class MetricsCollection(AWSProperty): props = { - 'Granularity': (basestring, True), + 'Granularity': (str, True), 'Metrics': (list, False), } @@ -126,9 +126,9 @@ def validate(self, init, authentication): class LaunchTemplateSpecification(AWSProperty): props = { - 'LaunchTemplateId': (basestring, False), - 'LaunchTemplateName': (basestring, False), - 'Version': (basestring, True) + 'LaunchTemplateId': (str, False), + 'LaunchTemplateName': (str, False), + 'Version': (str, True) } def validate(self): @@ -141,19 +141,19 @@ def validate(self): class InstancesDistribution(AWSProperty): props = { - 'OnDemandAllocationStrategy': (basestring, False), + 'OnDemandAllocationStrategy': (str, False), 'OnDemandBaseCapacity': (integer, False), 'OnDemandPercentageAboveBaseCapacity': (integer, False), - 'SpotAllocationStrategy': (basestring, False), + 'SpotAllocationStrategy': (str, False), 'SpotInstancePools': (integer, False), - 'SpotMaxPrice': (basestring, False), + 'SpotMaxPrice': (str, False), } class LaunchTemplateOverrides(AWSProperty): props = { - 'InstanceType': (basestring, False), - 'WeightedCapacity': (basestring, False), + 'InstanceType': (str, False), + 'WeightedCapacity': (str, False), } @@ -175,15 +175,15 @@ class AutoScalingGroup(AWSObject): resource_type = "AWS::AutoScaling::AutoScalingGroup" props = { - 'AutoScalingGroupName': (basestring, False), + 'AutoScalingGroupName': (str, False), 'AvailabilityZones': (list, False), 'CapacityRebalance': (boolean, False), 'Cooldown': (integer, False), 'DesiredCapacity': (integer, False), 'HealthCheckGracePeriod': (integer, False), - 'HealthCheckType': (basestring, False), - 'InstanceId': (basestring, False), - 'LaunchConfigurationName': (basestring, False), + 'HealthCheckType': (str, False), + 'InstanceId': (str, False), + 'LaunchConfigurationName': (str, False), 'LaunchTemplate': (LaunchTemplateSpecification, False), 'LifecycleHookSpecificationList': ([LifecycleHookSpecification], False), @@ -195,11 +195,11 @@ class AutoScalingGroup(AWSObject): 'MixedInstancesPolicy': (MixedInstancesPolicy, False), 'NewInstancesProtectedFromScaleIn': (boolean, False), 'NotificationConfigurations': ([NotificationConfigurations], False), - 'PlacementGroup': (basestring, False), - 'ServiceLinkedRoleARN': (basestring, False), + 'PlacementGroup': (str, False), + 'ServiceLinkedRoleARN': (str, False), 'Tags': ((Tags, list), False), - 'TargetGroupARNs': ([basestring], False), - 'TerminationPolicies': ([basestring], False), + 'TargetGroupARNs': ([str], False), + 'TerminationPolicies': ([str], False), 'VPCZoneIdentifier': (list, False), } @@ -256,24 +256,24 @@ class LaunchConfiguration(AWSObject): props = { 'AssociatePublicIpAddress': (boolean, False), 'BlockDeviceMappings': (list, False), - 'ClassicLinkVPCId': (basestring, False), - 'ClassicLinkVPCSecurityGroups': ([basestring], False), + 'ClassicLinkVPCId': (str, False), + 'ClassicLinkVPCSecurityGroups': ([str], False), 'EbsOptimized': (boolean, False), - 'IamInstanceProfile': (basestring, False), - 'ImageId': (basestring, True), - 'InstanceId': (basestring, False), + 'IamInstanceProfile': (str, False), + 'ImageId': (str, True), + 'InstanceId': (str, False), 'InstanceMonitoring': (boolean, False), - 'InstanceType': (basestring, True), - 'KernelId': (basestring, False), - 'KeyName': (basestring, False), - 'LaunchConfigurationName': (basestring, False), + 'InstanceType': (str, True), + 'KernelId': (str, False), + 'KeyName': (str, False), + 'LaunchConfigurationName': (str, False), 'Metadata': (Metadata, False), 'MetadataOptions': (MetadataOptions, False), - 'PlacementTenancy': (basestring, False), - 'RamDiskId': (basestring, False), + 'PlacementTenancy': (str, False), + 'RamDiskId': (str, False), 'SecurityGroups': (list, False), - 'SpotPrice': (basestring, False), - 'UserData': (basestring, False), + 'SpotPrice': (str, False), + 'UserData': (str, False), } @@ -287,25 +287,25 @@ class StepAdjustments(AWSProperty): class MetricDimension(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class CustomizedMetricSpecification(AWSProperty): props = { 'Dimensions': ([MetricDimension], False), - 'MetricName': (basestring, True), - 'Namespace': (basestring, True), - 'Statistic': (basestring, True), - 'Unit': (basestring, False), + 'MetricName': (str, True), + 'Namespace': (str, True), + 'Statistic': (str, True), + 'Unit': (str, False), } class PredefinedMetricSpecification(AWSProperty): props = { - 'PredefinedMetricType': (basestring, True), - 'ResourceLabel': (basestring, False), + 'PredefinedMetricType': (str, True), + 'ResourceLabel': (str, False), } @@ -324,13 +324,13 @@ class ScalingPolicy(AWSObject): resource_type = "AWS::AutoScaling::ScalingPolicy" props = { - 'AdjustmentType': (basestring, False), - 'AutoScalingGroupName': (basestring, True), + 'AdjustmentType': (str, False), + 'AutoScalingGroupName': (str, True), 'Cooldown': (integer, False), 'EstimatedInstanceWarmup': (integer, False), - 'MetricAggregationType': (basestring, False), + 'MetricAggregationType': (str, False), 'MinAdjustmentMagnitude': (integer, False), - 'PolicyType': (basestring, False), + 'PolicyType': (str, False), 'ScalingAdjustment': (integer, False), 'StepAdjustments': ([StepAdjustments], False), 'TargetTrackingConfiguration': (TargetTrackingConfiguration, False), @@ -341,13 +341,13 @@ class ScheduledAction(AWSObject): resource_type = "AWS::AutoScaling::ScheduledAction" props = { - 'AutoScalingGroupName': (basestring, True), + 'AutoScalingGroupName': (str, True), 'DesiredCapacity': (integer, False), - 'EndTime': (basestring, False), + 'EndTime': (str, False), 'MaxSize': (integer, False), 'MinSize': (integer, False), - 'Recurrence': (basestring, False), - 'StartTime': (basestring, False), + 'Recurrence': (str, False), + 'StartTime': (str, False), } @@ -355,14 +355,14 @@ class LifecycleHook(AWSObject): resource_type = "AWS::AutoScaling::LifecycleHook" props = { - 'AutoScalingGroupName': (basestring, True), - 'DefaultResult': (basestring, False), + 'AutoScalingGroupName': (str, True), + 'DefaultResult': (str, False), 'HeartbeatTimeout': (integer, False), - 'LifecycleHookName': (basestring, False), - 'LifecycleTransition': (basestring, True), - 'NotificationMetadata': (basestring, False), - 'NotificationTargetARN': (basestring, False), - 'RoleARN': (basestring, False), + 'LifecycleHookName': (str, False), + 'LifecycleTransition': (str, True), + 'NotificationMetadata': (str, False), + 'NotificationTargetARN': (str, False), + 'RoleARN': (str, False), } @@ -370,16 +370,16 @@ class Trigger(AWSObject): resource_type = "AWS::AutoScaling::Trigger" props = { - 'AutoScalingGroupName': (basestring, True), + 'AutoScalingGroupName': (str, True), 'BreachDuration': (integer, True), 'Dimensions': (list, True), 'LowerBreachScaleIncrement': (integer, False), 'LowerThreshold': (integer, True), - 'MetricName': (basestring, True), - 'Namespace': (basestring, True), + 'MetricName': (str, True), + 'Namespace': (str, True), 'Period': (integer, True), - 'Statistic': (basestring, True), - 'Unit': (basestring, False), + 'Statistic': (str, True), + 'Unit': (str, False), 'UpperBreachScaleIncrement': (integer, False), 'UpperThreshold': (integer, True), } @@ -391,17 +391,17 @@ class EBSBlockDevice(AWSProperty): 'DeleteOnTermination': (boolean, False), 'Encrypted': (boolean, False), 'Iops': (integer, False), - 'SnapshotId': (basestring, False), + 'SnapshotId': (str, False), 'VolumeSize': (integer, False), - 'VolumeType': (basestring, False), + 'VolumeType': (str, False), } class BlockDeviceMapping(AWSProperty): # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-as-launchconfig-blockdev-mapping.html props = { - 'DeviceName': (basestring, True), + 'DeviceName': (str, True), 'Ebs': (EBSBlockDevice, False), 'NoDevice': (boolean, False), - 'VirtualName': (basestring, False), + 'VirtualName': (str, False), } diff --git a/troposphere/autoscalingplans.py b/troposphere/autoscalingplans.py index c830cfda5..ab70ec4a8 100644 --- a/troposphere/autoscalingplans.py +++ b/troposphere/autoscalingplans.py @@ -48,39 +48,39 @@ def validate_scalingpolicyupdatebehavior(scalingpolicyupdatebehavior): class TagFilter(AWSProperty): props = { - 'Values': ([basestring], False), - 'Key': (basestring, True) + 'Values': ([str], False), + 'Key': (str, True) } class ApplicationSource(AWSProperty): props = { - 'CloudFormationStackARN': (basestring, False), + 'CloudFormationStackARN': (str, False), 'TagFilters': ([TagFilter], False) } class PredefinedScalingMetricSpecification(AWSProperty): props = { - 'ResourceLabel': (basestring, False), - 'PredefinedScalingMetricType': (basestring, True) + 'ResourceLabel': (str, False), + 'PredefinedScalingMetricType': (str, True) } class MetricDimension(AWSProperty): props = { - 'Value': (basestring, True), - 'Name': (basestring, True) + 'Value': (str, True), + 'Name': (str, True) } class CustomizedScalingMetricSpecification(AWSProperty): props = { - 'MetricName': (basestring, True), + 'MetricName': (str, True), 'Statistic': (statistic_type, True), 'Dimensions': ([MetricDimension], False), - 'Unit': (basestring, False), - 'Namespace': (basestring, True) + 'Unit': (str, False), + 'Namespace': (str, True) } @@ -105,17 +105,17 @@ class TargetTrackingConfiguration(AWSProperty): class CustomizedLoadMetricSpecification(AWSObject): props = { 'Dimensions': ([MetricDimension], False), - 'MetricName': (basestring, True), - 'Namespace': (basestring, True), - 'Statistic': (basestring, True), - 'Unit': (basestring, False), + 'MetricName': (str, True), + 'Namespace': (str, True), + 'Statistic': (str, True), + 'Unit': (str, False), } class PredefinedLoadMetricSpecification(AWSProperty): props = { - 'PredefinedLoadMetricType': (basestring, True), - 'ResourceLabel': (basestring, False), + 'PredefinedLoadMetricType': (str, True), + 'ResourceLabel': (str, False), } @@ -129,7 +129,7 @@ class ScalingInstruction(AWSProperty): 'PredictiveScalingMaxCapacityBehavior': (validate_predictivescalingmaxcapacitybehavior, False), # NOQA 'PredictiveScalingMaxCapacityBuffer': (integer, False), 'PredictiveScalingMode': (validate_predictivescalingmode, False), - 'ResourceId': (basestring, True), + 'ResourceId': (str, True), 'ScalableDimension': (scalable_dimension_type, True), 'ScalingPolicyUpdateBehavior': (validate_scalingpolicyupdatebehavior, False), # NOQA 'ScheduledActionBufferTime': (integer, False), diff --git a/troposphere/awslambda.py b/troposphere/awslambda.py index 1bc2cd100..a3cb277bb 100644 --- a/troposphere/awslambda.py +++ b/troposphere/awslambda.py @@ -74,11 +74,11 @@ def validate_variables_name(variables): class Code(AWSProperty): props = { - 'ImageUri': (basestring, False), - 'S3Bucket': (basestring, False), - 'S3Key': (basestring, False), - 'S3ObjectVersion': (basestring, False), - 'ZipFile': (basestring, False) + 'ImageUri': (str, False), + 'S3Bucket': (str, False), + 'S3Key': (str, False), + 'S3ObjectVersion': (str, False), + 'ZipFile': (str, False) } @staticmethod @@ -93,7 +93,7 @@ def check_zip_file(zip_file): if zip_file is None: return - if isinstance(zip_file, basestring): + if isinstance(zip_file, str): z_length = len(zip_file) if z_length > maxlength: raise ValueError(toolong % (maxlength, z_length)) @@ -109,13 +109,13 @@ def check_zip_file(zip_file): return # Get the length of the delimiter - if isinstance(delimiter, basestring): + if isinstance(delimiter, str): d_length = len(delimiter) else: d_length = 0 # Get the length of each value that will be joined - v_lengths = [len(v) for v in values if isinstance(v, basestring)] + v_lengths = [len(v) for v in values if isinstance(v, str)] # Add all the lengths together z_length = sum(v_lengths) @@ -158,9 +158,9 @@ def validate(self): class ImageConfig(AWSProperty): props = { - 'Command': ([basestring], False), - 'EntryPoint': ([basestring], False), - 'WorkingDirectory': (basestring, False) + 'Command': ([str], False), + 'EntryPoint': ([str], False), + 'WorkingDirectory': (str, False) } def validate(self): @@ -185,13 +185,13 @@ class VPCConfig(AWSProperty): class OnFailure(AWSProperty): props = { - 'Destination': (basestring, True), + 'Destination': (str, True), } class OnSuccess(AWSProperty): props = { - 'Destination': (basestring, True), + 'Destination': (str, True), } @@ -207,16 +207,16 @@ class EventInvokeConfig(AWSObject): props = { 'DestinationConfig': (DestinationConfig, False), - 'FunctionName': (basestring, True), + 'FunctionName': (str, True), 'MaximumEventAgeInSeconds': (integer, False), 'MaximumRetryAttempts': (integer, False), - 'Qualifier': (basestring, True), + 'Qualifier': (str, True), } class Endpoints(AWSProperty): props = { - 'KafkaBootstrapServers': ([basestring], False), + 'KafkaBootstrapServers': ([str], False), } @@ -228,8 +228,8 @@ class SelfManagedEventSource(AWSProperty): class SourceAccessConfiguration(AWSProperty): props = { - 'Type': (basestring, False), - 'URI': (basestring, False), + 'Type': (str, False), + 'URI': (str, False), } @@ -241,26 +241,26 @@ class EventSourceMapping(AWSObject): 'BisectBatchOnFunctionError': (boolean, False), 'DestinationConfig': (DestinationConfig, False), 'Enabled': (boolean, False), - 'EventSourceArn': (basestring, False), - 'FunctionName': (basestring, True), - 'FunctionResponseTypes': ([basestring], False), + 'EventSourceArn': (str, False), + 'FunctionName': (str, True), + 'FunctionResponseTypes': ([str], False), 'MaximumBatchingWindowInSeconds': (integer, False), 'MaximumRecordAgeInSeconds': (integer, False), 'MaximumRetryAttempts': (integer, False), 'ParallelizationFactor': (integer, False), 'PartialBatchResponse': (boolean, False), - 'Queues': ([basestring], False), + 'Queues': ([str], False), 'SelfManagedEventSource': (SelfManagedEventSource, False), 'SourceAccessConfigurations': ([SourceAccessConfiguration], False), - 'StartingPosition': (basestring, False), - 'Topics': ([basestring], False), + 'StartingPosition': (str, False), + 'Topics': ([str], False), 'TumblingWindowInSeconds': (integer, False), } class DeadLetterConfig(AWSProperty): props = { - 'TargetArn': (basestring, False), + 'TargetArn': (str, False), } @@ -272,14 +272,14 @@ class Environment(AWSProperty): class FileSystemConfig(AWSProperty): props = { - 'Arn': (basestring, True), - 'LocalMountPath': (basestring, True), + 'Arn': (str, True), + 'LocalMountPath': (str, True), } class TracingConfig(AWSProperty): props = { - 'Mode': (basestring, False), + 'Mode': (str, False), } @@ -288,20 +288,20 @@ class Function(AWSObject): props = { 'Code': (Code, True), - 'Description': (basestring, False), + 'Description': (str, False), 'DeadLetterConfig': (DeadLetterConfig, False), 'Environment': (Environment, False), 'FileSystemConfigs': ([FileSystemConfig], False), - 'FunctionName': (basestring, False), - 'Handler': (basestring, False), + 'FunctionName': (str, False), + 'Handler': (str, False), 'ImageConfig': (ImageConfig, False), - 'KmsKeyArn': (basestring, False), + 'KmsKeyArn': (str, False), 'MemorySize': (validate_memory_size, False), - 'Layers': ([basestring], False), + 'Layers': ([str], False), 'PackageType': (validate_package_type, False), 'ReservedConcurrentExecutions': (positive_integer, False), - 'Role': (basestring, True), - 'Runtime': (basestring, False), + 'Role': (str, True), + 'Runtime': (str, False), 'Tags': (Tags, False), 'Timeout': (positive_integer, False), 'TracingConfig': (TracingConfig, False), @@ -313,19 +313,19 @@ class Permission(AWSObject): resource_type = "AWS::Lambda::Permission" props = { - 'Action': (basestring, True), - 'EventSourceToken': (basestring, False), - 'FunctionName': (basestring, True), - 'Principal': (basestring, True), - 'SourceAccount': (basestring, False), - 'SourceArn': (basestring, False), + 'Action': (str, True), + 'EventSourceToken': (str, False), + 'FunctionName': (str, True), + 'Principal': (str, True), + 'SourceAccount': (str, False), + 'SourceArn': (str, False), } class VersionWeight(AWSProperty): props = { - 'FunctionVersion': (basestring, True), + 'FunctionVersion': (str, True), 'FunctionWeight': (float, True), } @@ -348,10 +348,10 @@ class Alias(AWSObject): resource_type = "AWS::Lambda::Alias" props = { - 'Description': (basestring, False), - 'FunctionName': (basestring, True), - 'FunctionVersion': (basestring, True), - 'Name': (basestring, True), + 'Description': (str, False), + 'FunctionName': (str, True), + 'FunctionVersion': (str, True), + 'Name': (str, True), 'ProvisionedConcurrencyConfig': (ProvisionedConcurrencyConfiguration, False), 'RoutingConfig': (AliasRoutingConfiguration, False), @@ -360,13 +360,13 @@ class Alias(AWSObject): class AllowedPublishers(AWSProperty): props = { - 'SigningProfileVersionArns': ([basestring], True), + 'SigningProfileVersionArns': ([str], True), } class CodeSigningPolicies(AWSProperty): props = { - 'UntrustedArtifactOnDeployment': (basestring, True), + 'UntrustedArtifactOnDeployment': (str, True), } @@ -376,7 +376,7 @@ class CodeSigningConfig(AWSObject): props = { 'AllowedPublishers': (AllowedPublishers, True), 'CodeSigningPolicies': (CodeSigningPolicies, False), - 'Description': (basestring, False), + 'Description': (str, False), } @@ -384,9 +384,9 @@ class Version(AWSObject): resource_type = "AWS::Lambda::Version" props = { - 'CodeSha256': (basestring, False), - 'Description': (basestring, False), - 'FunctionName': (basestring, True), + 'CodeSha256': (str, False), + 'Description': (str, False), + 'FunctionName': (str, True), 'ProvisionedConcurrencyConfig': (ProvisionedConcurrencyConfiguration, False), } @@ -394,9 +394,9 @@ class Version(AWSObject): class Content(AWSProperty): props = { - 'S3Bucket': (basestring, True), - 'S3Key': (basestring, True), - 'S3ObjectVersion': (basestring, False), + 'S3Bucket': (str, True), + 'S3Key': (str, True), + 'S3ObjectVersion': (str, False), } @@ -404,11 +404,11 @@ class LayerVersion(AWSObject): resource_type = "AWS::Lambda::LayerVersion" props = { - 'CompatibleRuntimes': ([basestring], False), + 'CompatibleRuntimes': ([str], False), 'Content': (Content, True), - 'Description': (basestring, False), - 'LayerName': (basestring, False), - 'LicenseInfo': (basestring, False), + 'Description': (str, False), + 'LayerName': (str, False), + 'LicenseInfo': (str, False), } @@ -416,8 +416,8 @@ class LayerVersionPermission(AWSObject): resource_type = "AWS::Lambda::LayerVersionPermission" props = { - 'Action': (basestring, True), - 'LayerVersionArn': (basestring, True), - 'OrganizationId': (basestring, False), - 'Principal': (basestring, True), + 'Action': (str, True), + 'LayerVersionArn': (str, True), + 'OrganizationId': (str, False), + 'Principal': (str, True), } diff --git a/troposphere/backup.py b/troposphere/backup.py index ec438ceb2..d4074924b 100644 --- a/troposphere/backup.py +++ b/troposphere/backup.py @@ -10,7 +10,7 @@ class AdvancedBackupSettingResourceType(AWSProperty): props = { 'BackupOptions': (dict, True), - 'ResourceType': (basestring, True), + 'ResourceType': (str, True), } @@ -23,7 +23,7 @@ class LifecycleResourceType(AWSProperty): class CopyActionResourceType(AWSProperty): props = { - 'DestinationBackupVaultArn': (basestring, True), + 'DestinationBackupVaultArn': (str, True), 'Lifecycle': (LifecycleResourceType, False), } @@ -34,10 +34,10 @@ class BackupRuleResourceType(AWSProperty): 'CopyActions': ([CopyActionResourceType], False), 'Lifecycle': (LifecycleResourceType, False), 'RecoveryPointTags': (dict, False), - 'RuleName': (basestring, True), - 'ScheduleExpression': (basestring, False), + 'RuleName': (str, True), + 'ScheduleExpression': (str, False), 'StartWindowMinutes': (double, False), - 'TargetBackupVault': (basestring, True), + 'TargetBackupVault': (str, True), } @@ -45,7 +45,7 @@ class BackupPlanResourceType(AWSProperty): props = { 'AdvancedBackupSettings': ([AdvancedBackupSettingResourceType], False), - 'BackupPlanName': (basestring, True), + 'BackupPlanName': (str, True), 'BackupPlanRule': ([BackupRuleResourceType], True), } @@ -61,18 +61,18 @@ class BackupPlan(AWSObject): class ConditionResourceType(AWSProperty): props = { - 'ConditionKey': (basestring, True), - 'ConditionType': (basestring, True), - 'ConditionValue': (basestring, True), + 'ConditionKey': (str, True), + 'ConditionType': (str, True), + 'ConditionValue': (str, True), } class BackupSelectionResourceType(AWSProperty): props = { - 'IamRoleArn': (basestring, True), + 'IamRoleArn': (str, True), 'ListOfTags': ([ConditionResourceType], False), - 'Resources': ([basestring], False), - 'SelectionName': (basestring, True), + 'Resources': ([str], False), + 'SelectionName': (str, True), } def validate(self): @@ -97,15 +97,15 @@ class BackupSelection(AWSObject): resource_type = "AWS::Backup::BackupSelection" props = { - 'BackupPlanId': (basestring, True), + 'BackupPlanId': (str, True), 'BackupSelection': (BackupSelectionResourceType, True), } class NotificationObjectType(AWSProperty): props = { - 'BackupVaultEvents': ([basestring], True), - 'SNSTopicArn': (basestring, True) + 'BackupVaultEvents': ([str], True), + 'SNSTopicArn': (str, True) } @@ -116,6 +116,6 @@ class BackupVault(AWSObject): 'AccessPolicy': (json_checker, False), 'BackupVaultName': (backup_vault_name, True), 'BackupVaultTags': (dict, False), - 'EncryptionKeyArn': (basestring, False), + 'EncryptionKeyArn': (str, False), 'Notifications': (NotificationObjectType, False), } diff --git a/troposphere/batch.py b/troposphere/batch.py index a278a624b..a4c2ea35c 100644 --- a/troposphere/batch.py +++ b/troposphere/batch.py @@ -4,16 +4,16 @@ class Ec2ConfigurationObject(AWSProperty): props = { - 'ImageIdOverride': (basestring, False), - 'ImageType': (basestring, True), + 'ImageIdOverride': (str, False), + 'ImageType': (str, True), } class LaunchTemplateSpecification(AWSProperty): props = { - "LaunchTemplateId": (basestring, False), - "LaunchTemplateName": (basestring, False), - "Version": (basestring, False), + "LaunchTemplateId": (str, False), + "LaunchTemplateName": (str, False), + "Version": (str, False), } def validate(self): @@ -48,34 +48,34 @@ class ComputeResources(AWSProperty): "BidPercentage": (positive_integer, False), "DesiredvCpus": (positive_integer, False), 'Ec2Configuration': ([Ec2ConfigurationObject], False), - "Ec2KeyPair": (basestring, False), - "ImageId": (basestring, False), - "InstanceRole": (basestring, False), - "InstanceTypes": ([basestring], False), + "Ec2KeyPair": (str, False), + "ImageId": (str, False), + "InstanceRole": (str, False), + "InstanceTypes": ([str], False), "LaunchTemplate": (LaunchTemplateSpecification, False), "MaxvCpus": (positive_integer, True), "MinvCpus": (positive_integer, False), - "PlacementGroup": (basestring, False), - "SecurityGroupIds": ([basestring], False), - "SpotIamFleetRole": (basestring, False), - "Subnets": ([basestring], True), + "PlacementGroup": (str, False), + "SecurityGroupIds": ([str], False), + "SpotIamFleetRole": (str, False), + "Subnets": ([str], True), "Tags": (dict, False), - "Type": (basestring, True), + "Type": (str, True), } class Device(AWSProperty): props = { - 'ContainerPath': (basestring, False), - 'HostPath': (basestring, False), - 'Permissions': ([basestring], False), + 'ContainerPath': (str, False), + 'HostPath': (str, False), + 'Permissions': ([str], False), } class Tmpfs(AWSProperty): props = { - 'ContainerPath': (basestring, True), - 'MountOptions': ([basestring], False), + 'ContainerPath': (str, True), + 'MountOptions': ([str], False), 'Size': (integer, True), } @@ -93,14 +93,14 @@ class LinuxParameters(AWSProperty): class Secret(AWSProperty): props = { - 'Name': (basestring, True), - 'ValueFrom': (basestring, True), + 'Name': (str, True), + 'ValueFrom': (str, True), } class LogConfiguration(AWSProperty): props = { - 'LogDriver': (basestring, True), + 'LogDriver': (str, True), 'Options': (dict, False), 'SecretOptions': ([Secret], False), } @@ -110,15 +110,15 @@ class MountPoints(AWSProperty): props = { "ReadOnly": (bool, False), - "SourceVolume": (basestring, False), - "ContainerPath": (basestring, False) + "SourceVolume": (str, False), + "ContainerPath": (str, False) } class VolumesHost(AWSProperty): props = { - "SourcePath": (basestring, False) + "SourcePath": (str, False) } @@ -126,22 +126,22 @@ class Volumes(AWSProperty): props = { "Host": (VolumesHost, False), - "Name": (basestring, False) + "Name": (str, False) } class Environment(AWSProperty): props = { - "Value": (basestring, False), - "Name": (basestring, False) + "Value": (str, False), + "Name": (str, False) } class ResourceRequirement(AWSProperty): props = { - 'Type': (basestring, False), - 'Value': (basestring, False), + 'Type': (str, False), + 'Value': (str, False), } @@ -150,19 +150,19 @@ class Ulimit(AWSProperty): props = { "SoftLimit": (positive_integer, True), "HardLimit": (positive_integer, True), - "Name": (basestring, True) + "Name": (str, True) } class ContainerProperties(AWSProperty): props = { - 'Command': ([basestring], False), + 'Command': ([str], False), 'Environment': ([Environment], False), - 'ExecutionRoleArn': (basestring, False), - 'Image': (basestring, True), - 'InstanceType': (basestring, False), - 'JobRoleArn': (basestring, False), + 'ExecutionRoleArn': (str, False), + 'Image': (str, True), + 'InstanceType': (str, False), + 'JobRoleArn': (str, False), 'LinuxParameters': (LinuxParameters, False), 'LogConfiguration': (LogConfiguration, False), 'Memory': (positive_integer, True), @@ -172,7 +172,7 @@ class ContainerProperties(AWSProperty): 'ResourceRequirements': ([ResourceRequirement], False), 'Secrets': ([Secret], False), 'Ulimits': ([Ulimit], False), - 'User': (basestring, False), + 'User': (str, False), 'Vcpus': (positive_integer, True), 'Volumes': ([Volumes], False), } @@ -181,7 +181,7 @@ class ContainerProperties(AWSProperty): class NodeRangeProperty(AWSProperty): props = { 'Container': (ContainerProperties, False), - 'TargetNodes': (basestring, True), + 'TargetNodes': (str, True), } @@ -195,10 +195,10 @@ class NodeProperties(AWSProperty): class EvaluateOnExit(AWSProperty): props = { - 'Action': (basestring, True), - 'OnExitCode': (basestring, False), - 'OnReason': (basestring, False), - 'OnStatusReason': (basestring, False), + 'Action': (str, True), + 'OnExitCode': (str, False), + 'OnReason': (str, False), + 'OnStatusReason': (str, False), } @@ -221,15 +221,15 @@ class JobDefinition(AWSObject): props = { 'ContainerProperties': (ContainerProperties, False), - 'JobDefinitionName': (basestring, False), + 'JobDefinitionName': (str, False), 'NodeProperties': (NodeProperties, False), 'Parameters': (dict, False), - 'PlatformCapabilities': ([basestring], False), + 'PlatformCapabilities': ([str], False), 'PropagateTags': (boolean, False), 'RetryStrategy': (RetryStrategy, False), 'Tags': (dict, False), 'Timeout': (Timeout, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -253,9 +253,9 @@ class ComputeEnvironment(AWSObject): resource_type = "AWS::Batch::ComputeEnvironment" props = { - "Type": (basestring, True), - "ServiceRole": (basestring, True), - "ComputeEnvironmentName": (basestring, False), + "Type": (str, True), + "ServiceRole": (str, True), + "ComputeEnvironmentName": (str, False), "ComputeResources": (ComputeResources, True), "State": (validate_environment_state, False), "Tags": (dict, False), @@ -265,7 +265,7 @@ class ComputeEnvironment(AWSObject): class ComputeEnvironmentOrder(AWSProperty): props = { - "ComputeEnvironment": (basestring, True), + "ComputeEnvironment": (str, True), "Order": (positive_integer, True) } @@ -293,6 +293,6 @@ class JobQueue(AWSObject): "ComputeEnvironmentOrder": ([ComputeEnvironmentOrder], True), "Priority": (positive_integer, True), "State": (validate_queue_state, False), - "JobQueueName": (basestring, False), + "JobQueueName": (str, False), "Tags": (dict, False), } diff --git a/troposphere/budgets.py b/troposphere/budgets.py index 402224fc8..3f032d191 100644 --- a/troposphere/budgets.py +++ b/troposphere/budgets.py @@ -32,43 +32,43 @@ class CostTypes(AWSProperty): class Spend(AWSProperty): props = { 'Amount': (double, True), - 'Unit': (basestring, True), + 'Unit': (str, True), } class TimePeriod(AWSProperty): props = { - 'End': (basestring, False), - 'Start': (basestring, False), + 'End': (str, False), + 'Start': (str, False), } class BudgetData(AWSProperty): props = { 'BudgetLimit': (Spend, False), - 'BudgetName': (basestring, False), - 'BudgetType': (basestring, True), + 'BudgetName': (str, False), + 'BudgetType': (str, True), 'CostFilters': (dict, False), 'CostTypes': (CostTypes, False), 'PlannedBudgetLimits': (dict, False), 'TimePeriod': (TimePeriod, False), - 'TimeUnit': (basestring, True), + 'TimeUnit': (str, True), } class Notification(AWSProperty): props = { - 'ComparisonOperator': (basestring, True), - 'NotificationType': (basestring, True), + 'ComparisonOperator': (str, True), + 'NotificationType': (str, True), 'Threshold': (double, True), - 'ThresholdType': (basestring, False), + 'ThresholdType': (str, False), } class Subscriber(AWSProperty): props = { - 'Address': (basestring, True), - 'SubscriptionType': (basestring, True), + 'Address': (str, True), + 'SubscriptionType': (str, True), } diff --git a/troposphere/cassandra.py b/troposphere/cassandra.py index 3ef93badc..b7f57999c 100644 --- a/troposphere/cassandra.py +++ b/troposphere/cassandra.py @@ -32,15 +32,15 @@ class Keyspace(AWSObject): resource_type = "AWS::Cassandra::Keyspace" props = { - 'KeyspaceName': (basestring, False), + 'KeyspaceName': (str, False), 'Tags': (Tags, False), } class Column(AWSProperty): props = { - "ColumnName": (basestring, True), - "ColumnType": (basestring, True), + "ColumnName": (str, True), + "ColumnType": (str, True), } @@ -71,10 +71,10 @@ class Table(AWSObject): props = { "BillingMode": (BillingMode, False), "ClusteringKeyColumns": ([ClusteringKeyColumn], False), - "KeyspaceName": (basestring, True), + "KeyspaceName": (str, True), "PartitionKeyColumns": ([Column], True), 'PointInTimeRecoveryEnabled': (boolean, False), "RegularColumns": ([Column], False), - "TableName": (basestring, False), + "TableName": (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/ce.py b/troposphere/ce.py index c5f6dde7c..fa1d79a99 100644 --- a/troposphere/ce.py +++ b/troposphere/ce.py @@ -16,18 +16,18 @@ class AnomalyMonitor(AWSObject): resource_type = "AWS::CE::AnomalyMonitor" props = { - 'MonitorDimension': (basestring, False), - 'MonitorName': (basestring, True), - 'MonitorSpecification': (basestring, False), - 'MonitorType': (basestring, True), + 'MonitorDimension': (str, False), + 'MonitorName': (str, True), + 'MonitorSpecification': (str, False), + 'MonitorType': (str, True), } class Subscriber(AWSProperty): props = { - 'Address': (basestring, True), - 'Status': (basestring, False), - 'Type': (basestring, True), + 'Address': (str, True), + 'Status': (str, False), + 'Type': (str, True), } @@ -35,10 +35,10 @@ class AnomalySubscription(AWSObject): resource_type = "AWS::CE::AnomalySubscription" props = { - 'Frequency': (basestring, True), - 'MonitorArnList': ([basestring], True), + 'Frequency': (str, True), + 'MonitorArnList': ([str], True), 'Subscribers': ([Subscriber], True), - 'SubscriptionName': (basestring, True), + 'SubscriptionName': (str, True), 'Threshold': (double, True), } @@ -47,7 +47,7 @@ class CostCategory(AWSObject): resource_type = "AWS::CE::CostCategory" props = { - 'Name': (basestring, True), - 'RuleVersion': (basestring, True), - 'Rules': (basestring, True), + 'Name': (str, True), + 'RuleVersion': (str, True), + 'Rules': (str, True), } diff --git a/troposphere/certificatemanager.py b/troposphere/certificatemanager.py index cd7a2781f..270aaf91d 100644 --- a/troposphere/certificatemanager.py +++ b/troposphere/certificatemanager.py @@ -29,9 +29,9 @@ class Account(AWSObject): class DomainValidationOption(AWSProperty): props = { - 'DomainName': (basestring, True), - 'HostedZoneId': (basestring, False), - 'ValidationDomain': (basestring, False), + 'DomainName': (str, True), + 'HostedZoneId': (str, False), + 'ValidationDomain': (str, False), } @@ -39,11 +39,11 @@ class Certificate(AWSObject): resource_type = "AWS::CertificateManager::Certificate" props = { - 'CertificateAuthorityArn': (basestring, False), - 'CertificateTransparencyLoggingPreference': (basestring, False), - 'DomainName': (basestring, True), + 'CertificateAuthorityArn': (str, False), + 'CertificateTransparencyLoggingPreference': (str, False), + 'DomainName': (str, True), 'DomainValidationOptions': ([DomainValidationOption], False), - 'SubjectAlternativeNames': ([basestring], False), + 'SubjectAlternativeNames': ([str], False), 'Tags': ((Tags, list), False), - 'ValidationMethod': (basestring, False), + 'ValidationMethod': (str, False), } diff --git a/troposphere/chatbot.py b/troposphere/chatbot.py index 8473ba878..512efc005 100644 --- a/troposphere/chatbot.py +++ b/troposphere/chatbot.py @@ -23,11 +23,11 @@ class SlackChannelConfiguration(AWSObject): resource_type = "AWS::Chatbot::SlackChannelConfiguration" props = { - 'Arn': (basestring, False), - 'ConfigurationName': (basestring, True), - 'IamRoleArn': (basestring, True), + 'Arn': (str, False), + 'ConfigurationName': (str, True), + 'IamRoleArn': (str, True), 'LoggingLevel': (validate_logginglevel, False), - 'SlackChannelId': (basestring, True), - 'SlackWorkspaceId': (basestring, True), - 'SnsTopicArns': ([basestring], False), + 'SlackChannelId': (str, True), + 'SlackWorkspaceId': (str, True), + 'SnsTopicArns': ([str], False), } diff --git a/troposphere/cloud9.py b/troposphere/cloud9.py index fff8c6f0a..ce366c01d 100644 --- a/troposphere/cloud9.py +++ b/troposphere/cloud9.py @@ -9,8 +9,8 @@ class Repository(AWSProperty): props = { - 'PathComponent': (basestring, True), - 'RepositoryUrl': (basestring, True), + 'PathComponent': (str, True), + 'RepositoryUrl': (str, True), } @@ -19,10 +19,10 @@ class EnvironmentEC2(AWSObject): props = { 'AutomaticStopTimeMinutes': (integer, False), - 'Description': (basestring, False), - 'InstanceType': (basestring, True), - 'Name': (basestring, False), - 'OwnerArn': (basestring, False), + 'Description': (str, False), + 'InstanceType': (str, True), + 'Name': (str, False), + 'OwnerArn': (str, False), 'Repositories': ([Repository], False), - 'SubnetId': (basestring, False), + 'SubnetId': (str, False), } diff --git a/troposphere/cloudformation.py b/troposphere/cloudformation.py index 661fc2d8c..0e32d8c22 100644 --- a/troposphere/cloudformation.py +++ b/troposphere/cloudformation.py @@ -12,9 +12,9 @@ class ModuleDefaultVersion(AWSObject): resource_type = "AWS::CloudFormation::ModuleDefaultVersion" props = { - 'Arn': (basestring, False), - 'ModuleName': (basestring, False), - 'VersionId': (basestring, False), + 'Arn': (str, False), + 'ModuleName': (str, False), + 'VersionId': (str, False), } @@ -22,8 +22,8 @@ class ModuleVersion(AWSObject): resource_type = "AWS::CloudFormation::ModuleVersion" props = { - 'ModuleName': (basestring, True), - 'ModulePackage': (basestring, True), + 'ModuleName': (str, True), + 'ModulePackage': (str, True), } @@ -31,16 +31,16 @@ class ResourceDefaultVersion(AWSObject): resource_type = "AWS::CloudFormation::ResourceDefaultVersion" props = { - 'TypeName': (basestring, False), - 'TypeVersionArn': (basestring, False), - 'VersionId': (basestring, False), + 'TypeName': (str, False), + 'TypeVersionArn': (str, False), + 'VersionId': (str, False), } class LoggingConfig(AWSProperty): props = { - 'LogGroupName': (basestring, False), - 'LogRoleArn': (basestring, False), + 'LogGroupName': (str, False), + 'LogRoleArn': (str, False), } @@ -48,10 +48,10 @@ class ResourceVersion(AWSObject): resource_type = "AWS::CloudFormation::ResourceVersion" props = { - 'ExecutionRoleArn': (basestring, False), + 'ExecutionRoleArn': (str, False), 'LoggingConfig': (LoggingConfig, False), - 'SchemaHandlerPackage': (basestring, True), - 'TypeName': (basestring, True), + 'SchemaHandlerPackage': (str, True), + 'TypeName': (str, True), } @@ -59,10 +59,10 @@ class Stack(AWSObject): resource_type = "AWS::CloudFormation::Stack" props = { - 'NotificationARNs': ([basestring], False), + 'NotificationARNs': ([str], False), 'Parameters': (dict, False), 'Tags': ((Tags, list), False), - 'TemplateURL': (basestring, True), + 'TemplateURL': (str, True), 'TimeoutInMinutes': (integer, False), } @@ -75,7 +75,7 @@ class CustomResource(AWSCustomObject): resource_type = "AWS::CloudFormation::CustomResource" props = { - 'ServiceToken': (basestring, True) + 'ServiceToken': (str, True) } @@ -92,21 +92,21 @@ class OperationPreferences(AWSProperty): 'FailureTolerancePercentage': (integer, False), 'MaxConcurrentCount': (integer, False), 'MaxConcurrentPercentage': (integer, False), - 'RegionOrder': ([basestring], False), + 'RegionOrder': ([str], False), } class Parameter(AWSProperty): props = { - 'ParameterKey': (basestring, True), - 'ParameterValue': (basestring, True), + 'ParameterKey': (str, True), + 'ParameterValue': (str, True), } class DeploymentTargets(AWSProperty): props = { - 'Accounts': ([basestring], False), - 'OrganizationalUnitIds': ([basestring], False), + 'Accounts': ([str], False), + 'OrganizationalUnitIds': ([str], False), } @@ -114,7 +114,7 @@ class StackInstances(AWSProperty): props = { 'DeploymentTargets': (DeploymentTargets, True), 'ParameterOverrides': ([Parameter], False), - 'Regions': ([basestring], True), + 'Regions': ([str], True), } @@ -122,19 +122,19 @@ class StackSet(AWSObject): resource_type = "AWS::CloudFormation::StackSet" props = { - 'AdministrationRoleARN': (basestring, False), + 'AdministrationRoleARN': (str, False), 'AutoDeployment': (AutoDeployment, False), - 'Capabilities': ([basestring], False), - 'Description': (basestring, False), - 'ExecutionRoleName': (basestring, False), + 'Capabilities': ([str], False), + 'Description': (str, False), + 'ExecutionRoleName': (str, False), 'OperationPreferences': (OperationPreferences, False), 'Parameters': ([Parameter], False), - 'PermissionModel': (basestring, False), + 'PermissionModel': (str, False), 'StackInstancesGroup': ([StackInstances], False), - 'StackSetName': (basestring, False), + 'StackSetName': (str, False), 'Tags': (Tags, False), - 'TemplateBody': (basestring, False), - 'TemplateURL': (basestring, False), + 'TemplateBody': (str, False), + 'TemplateURL': (str, False), } @@ -143,13 +143,13 @@ class WaitCondition(AWSObject): props = { 'Count': (integer, False), - 'Handle': (basestring, False), + 'Handle': (str, False), 'Timeout': (integer, False), } def validate(self): if 'CreationPolicy' in self.resource: - for k in self.props.keys(): + for k in list(self.props.keys()): if k in self.properties: raise ValueError( "Property %s cannot be specified with CreationPolicy" % @@ -173,7 +173,7 @@ def __init__(self, *args): def to_dict(self): t = [] for i in self.data: - t += encode_to_dict(i).items() + t += list(encode_to_dict(i).items()) return dict(t) @@ -184,13 +184,13 @@ def __init__(self, data): class InitFile(AWSProperty): props = { - 'content': (basestring, False), - 'mode': (basestring, False), - 'owner': (basestring, False), + 'content': (str, False), + 'mode': (str, False), + 'owner': (str, False), 'encoding': (encoding, False), - 'group': (basestring, False), - 'source': (basestring, False), - 'authentication': (basestring, False), + 'group': (str, False), + 'source': (str, False), + 'authentication': (str, False), 'context': (InitFileContext, False) } @@ -236,7 +236,7 @@ def __init__(self, **kwargs): self.data = kwargs def validate(self, config_sets): - for k, v in config_sets.iteritems(): + for k, v in config_sets.items(): if not isinstance(v, list): raise ValueError('configSets values must be of type list') @@ -262,14 +262,14 @@ def validate_authentication_type(auth_type): class AuthenticationBlock(AWSProperty): props = { - "accessKeyId": (basestring, False), - "buckets": ([basestring], False), - "password": (basestring, False), - "secretKey": (basestring, False), + "accessKeyId": (str, False), + "buckets": ([str], False), + "password": (str, False), + "secretKey": (str, False), "type": (validate_authentication_type, False), - "uris": ([basestring], False), - "username": (basestring, False), - "roleName": (basestring, False) + "uris": ([str], False), + "username": (str, False), + "roleName": (str, False) } @@ -279,7 +279,7 @@ def __init__(self, data): self.data = {"AWS::CloudFormation::Authentication": data} def validate(self, data): - for k, v in data.iteritems(): + for k, v in data.items(): if not isinstance(v, AuthenticationBlock): raise ValueError( 'authentication block must be of type' @@ -301,7 +301,7 @@ def __init__(self, data, **kwargs): def validate(self, data, config_sets): if isinstance(data, InitConfigSets): - for k, v in sorted(config_sets.iteritems()): + for k, v in sorted(config_sets.items()): if not isinstance(v, InitConfig): raise ValueError( 'init configs must of type ', @@ -320,9 +320,9 @@ class Macro(AWSCustomObject): resource_type = "AWS::CloudFormation::Macro" props = { - 'Description': (basestring, False), - 'FunctionName': (basestring, True), - 'LogGroupName': (basestring, False), - 'LogRoleARN': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'FunctionName': (str, True), + 'LogGroupName': (str, False), + 'LogRoleARN': (str, False), + 'Name': (str, True), } diff --git a/troposphere/cloudfront.py b/troposphere/cloudfront.py index 24b53b633..a5d9d8180 100644 --- a/troposphere/cloudfront.py +++ b/troposphere/cloudfront.py @@ -20,16 +20,16 @@ class Cookies(AWSProperty): props = { 'Forward': (cloudfront_forward_type, True), - 'WhitelistedNames': ([basestring], False), + 'WhitelistedNames': ([str], False), } class ForwardedValues(AWSProperty): props = { 'Cookies': (Cookies, False), - 'Headers': ([basestring], False), + 'Headers': ([str], False), 'QueryString': (boolean, True), - 'QueryStringCacheKeys': ([basestring], False), + 'QueryStringCacheKeys': ([str], False), } @@ -37,50 +37,50 @@ class LambdaFunctionAssociation(AWSProperty): props = { 'EventType': (cloudfront_event_type, False), 'IncludeBody': (boolean, False), - 'LambdaFunctionARN': (basestring, False), + 'LambdaFunctionARN': (str, False), } class CacheBehavior(AWSProperty): props = { - 'AllowedMethods': ([basestring], False), - 'CachePolicyId': (basestring, False), - 'CachedMethods': ([basestring], False), + 'AllowedMethods': ([str], False), + 'CachePolicyId': (str, False), + 'CachedMethods': ([str], False), 'Compress': (boolean, False), 'DefaultTTL': (integer, False), - 'FieldLevelEncryptionId': (basestring, False), + 'FieldLevelEncryptionId': (str, False), 'ForwardedValues': (ForwardedValues, False), 'LambdaFunctionAssociations': ([LambdaFunctionAssociation], False), 'MaxTTL': (integer, False), 'MinTTL': (integer, False), - 'OriginRequestPolicyId': (basestring, False), - 'PathPattern': (basestring, True), - 'RealtimeLogConfigArn': (basestring, False), + 'OriginRequestPolicyId': (str, False), + 'PathPattern': (str, True), + 'RealtimeLogConfigArn': (str, False), 'SmoothStreaming': (boolean, False), - 'TargetOriginId': (basestring, True), - 'TrustedKeyGroups': ([basestring], False), - 'TrustedSigners': ([basestring], False), + 'TargetOriginId': (str, True), + 'TrustedKeyGroups': ([str], False), + 'TrustedSigners': ([str], False), 'ViewerProtocolPolicy': (cloudfront_viewer_protocol_policy, True), } class DefaultCacheBehavior(AWSProperty): props = { - 'AllowedMethods': ([basestring], False), - 'CachePolicyId': (basestring, False), - 'CachedMethods': ([basestring], False), + 'AllowedMethods': ([str], False), + 'CachePolicyId': (str, False), + 'CachedMethods': ([str], False), 'Compress': (boolean, False), 'DefaultTTL': (integer, False), - 'FieldLevelEncryptionId': (basestring, False), + 'FieldLevelEncryptionId': (str, False), 'ForwardedValues': (ForwardedValues, False), 'LambdaFunctionAssociations': ([LambdaFunctionAssociation], False), 'MaxTTL': (integer, False), 'MinTTL': (integer, False), - 'OriginRequestPolicyId': (basestring, False), - 'RealtimeLogConfigArn': (basestring, False), + 'OriginRequestPolicyId': (str, False), + 'RealtimeLogConfigArn': (str, False), 'SmoothStreaming': (boolean, False), - 'TargetOriginId': (basestring, True), - 'TrustedKeyGroups': ([basestring], False), + 'TargetOriginId': (str, True), + 'TrustedKeyGroups': ([str], False), 'TrustedSigners': (list, False), 'ViewerProtocolPolicy': (cloudfront_viewer_protocol_policy, True), } @@ -88,8 +88,8 @@ class DefaultCacheBehavior(AWSProperty): class S3Origin(AWSProperty): props = { - 'DomainName': (basestring, True), - 'OriginAccessIdentity': (basestring, False), + 'DomainName': (str, True), + 'OriginAccessIdentity': (str, False), } @@ -98,29 +98,29 @@ class CustomOriginConfig(AWSProperty): 'HTTPPort': (network_port, False), 'HTTPSPort': (network_port, False), 'OriginKeepaliveTimeout': (integer, False), - 'OriginProtocolPolicy': (basestring, True), + 'OriginProtocolPolicy': (str, True), 'OriginReadTimeout': (integer, False), - 'OriginSSLProtocols': ([basestring], False), + 'OriginSSLProtocols': ([str], False), } class OriginCustomHeader(AWSProperty): props = { - 'HeaderName': (basestring, True), - 'HeaderValue': (basestring, True), + 'HeaderName': (str, True), + 'HeaderValue': (str, True), } class S3OriginConfig(AWSProperty): props = { - 'OriginAccessIdentity': (basestring, False), + 'OriginAccessIdentity': (str, False), } class OriginShield(AWSProperty): props = { 'Enabled': (boolean, True), - 'OriginShieldRegion': (basestring, False), + 'OriginShieldRegion': (str, False), } @@ -129,10 +129,10 @@ class Origin(AWSProperty): 'ConnectionAttempts': (integer, False), 'ConnectionTimeout': (integer, False), 'CustomOriginConfig': (CustomOriginConfig, False), - 'DomainName': (basestring, True), - 'Id': (basestring, True), + 'DomainName': (str, True), + 'Id': (str, True), 'OriginCustomHeaders': ([OriginCustomHeader], False), - 'OriginPath': (basestring, False), + 'OriginPath': (str, False), 'OriginShield': (OriginShield, False), 'S3OriginConfig': (S3OriginConfig, False), } @@ -140,9 +140,9 @@ class Origin(AWSProperty): class Logging(AWSProperty): props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'IncludeCookies': (boolean, False), - 'Prefix': (basestring, False), + 'Prefix': (str, False), } @@ -151,13 +151,13 @@ class CustomErrorResponse(AWSProperty): 'ErrorCachingMinTTL': (positive_integer, False), 'ErrorCode': (positive_integer, True), 'ResponseCode': (positive_integer, False), - 'ResponsePagePath': (basestring, False), + 'ResponsePagePath': (str, False), } class GeoRestriction(AWSProperty): props = { - 'Locations': ([basestring], False), + 'Locations': ([str], False), 'RestrictionType': (cloudfront_restriction_type, True), } @@ -170,11 +170,11 @@ class Restrictions(AWSProperty): class ViewerCertificate(AWSProperty): props = { - 'AcmCertificateArn': (basestring, False), + 'AcmCertificateArn': (str, False), 'CloudFrontDefaultCertificate': (boolean, False), - 'IamCertificateId': (basestring, False), - 'MinimumProtocolVersion': (basestring, False), - 'SslSupportMethod': (basestring, False), + 'IamCertificateId': (str, False), + 'MinimumProtocolVersion': (str, False), + 'SslSupportMethod': (str, False), } @@ -193,7 +193,7 @@ class OriginGroupFailoverCriteria(AWSProperty): class OriginGroupMember(AWSProperty): props = { - 'OriginId': (basestring, True), + 'OriginId': (str, True), } @@ -207,7 +207,7 @@ class OriginGroupMembers(AWSProperty): class OriginGroup(AWSProperty): props = { 'FailoverCriteria': (OriginGroupFailoverCriteria, True), - 'Id': (basestring, True), + 'Id': (str, True), 'Members': (OriginGroupMembers, True), } @@ -223,12 +223,12 @@ class DistributionConfig(AWSProperty): props = { 'Aliases': (list, False), 'CacheBehaviors': ([CacheBehavior], False), - 'Comment': (basestring, False), + 'Comment': (str, False), 'CustomErrorResponses': ([CustomErrorResponse], False), 'DefaultCacheBehavior': (DefaultCacheBehavior, True), - 'DefaultRootObject': (basestring, False), + 'DefaultRootObject': (str, False), 'Enabled': (boolean, True), - 'HttpVersion': (basestring, False), + 'HttpVersion': (str, False), 'IPV6Enabled': (boolean, False), 'Logging': (Logging, False), 'Origins': ([Origin], True), @@ -236,7 +236,7 @@ class DistributionConfig(AWSProperty): 'PriceClass': (priceclass_type, False), 'Restrictions': (Restrictions, False), 'ViewerCertificate': (ViewerCertificate, False), - 'WebACLId': (basestring, False), + 'WebACLId': (str, False), } @@ -251,7 +251,7 @@ class Distribution(AWSObject): class CloudFrontOriginAccessIdentityConfig(AWSProperty): props = { - 'Comment': (basestring, True), + 'Comment': (str, True), } @@ -268,15 +268,15 @@ class CloudFrontOriginAccessIdentity(AWSObject): class TrustedSigners(AWSProperty): props = { - 'AwsAccountNumbers': ([basestring], False), + 'AwsAccountNumbers': ([str], False), 'Enabled': (boolean, True), } class StreamingDistributionConfig(AWSProperty): props = { - 'Aliases': ([basestring], False), - 'Comment': (basestring, True), + 'Aliases': ([str], False), + 'Comment': (str, True), 'Enabled': (boolean, True), 'Logging': (Logging, False), 'PriceClass': (priceclass_type, False), @@ -297,14 +297,14 @@ class StreamingDistribution(AWSObject): class CacheCookiesConfig(AWSProperty): props = { 'CookieBehavior': (cloudfront_cache_cookie_behavior, True), - 'Cookies': ([basestring], False), + 'Cookies': ([str], False), } class CacheHeadersConfig(AWSProperty): props = { 'HeaderBehavior': (cloudfront_cache_header_behavior, True), - 'Headers': ([basestring], False), + 'Headers': ([str], False), } @@ -312,7 +312,7 @@ class CacheQueryStringsConfig(AWSProperty): props = { 'QueryStringBehavior': ( cloudfront_cache_query_string_behavior, True), - 'QueryStrings': ([basestring], False), + 'QueryStrings': ([str], False), } @@ -328,11 +328,11 @@ class ParametersInCacheKeyAndForwardedToOrigin(AWSProperty): class CachePolicyConfig(AWSProperty): props = { - 'Comment': (basestring, False), + 'Comment': (str, False), 'DefaultTTL': (integer, True), 'MaxTTL': (integer, True), 'MinTTL': (integer, True), - 'Name': (basestring, True), + 'Name': (str, True), 'ParametersInCacheKeyAndForwardedToOrigin': ( ParametersInCacheKeyAndForwardedToOrigin, True), } @@ -349,14 +349,14 @@ class CachePolicy(AWSObject): class OriginRequestCookiesConfig(AWSProperty): props = { 'CookieBehavior': (cloudfront_origin_request_cookie_behavior, True), - 'Cookies': ([basestring], False), + 'Cookies': ([str], False), } class OriginRequestHeadersConfig(AWSProperty): props = { 'HeaderBehavior': (cloudfront_origin_request_header_behavior, True), - 'Headers': ([basestring], False), + 'Headers': ([str], False), } @@ -364,16 +364,16 @@ class OriginRequestQueryStringsConfig(AWSProperty): props = { 'QueryStringBehavior': ( cloudfront_origin_request_query_string_behavior, True), - 'QueryStrings': ([basestring], False), + 'QueryStrings': ([str], False), } class OriginRequestPolicyConfig(AWSProperty): props = { - 'Comment': (basestring, False), + 'Comment': (str, False), 'CookiesConfig': (OriginRequestCookiesConfig, True), 'HeadersConfig': (OriginRequestHeadersConfig, True), - 'Name': (basestring, True), + 'Name': (str, True), 'QueryStringsConfig': (OriginRequestQueryStringsConfig, True), } @@ -388,9 +388,9 @@ class OriginRequestPolicy(AWSObject): class KeyGroupConfig(AWSProperty): props = { - 'Comment': (basestring, False), - 'Items': ([basestring], True), - 'Name': (basestring, True), + 'Comment': (str, False), + 'Items': ([str], True), + 'Name': (str, True), } @@ -404,10 +404,10 @@ class KeyGroup(AWSObject): class PublicKeyConfig(AWSProperty): props = { - 'CallerReference': (basestring, True), - 'Comment': (basestring, False), - 'EncodedKey': (basestring, True), - 'Name': (basestring, True), + 'CallerReference': (str, True), + 'Comment': (str, False), + 'EncodedKey': (str, True), + 'Name': (str, True), } @@ -421,15 +421,15 @@ class PublicKey(AWSObject): class KinesisStreamConfig(AWSProperty): props = { - 'RoleArn': (basestring, True), - 'StreamArn': (basestring, True), + 'RoleArn': (str, True), + 'StreamArn': (str, True), } class EndPoint(AWSProperty): props = { 'KinesisStreamConfig': (KinesisStreamConfig, True), - 'StreamType': (basestring, True), + 'StreamType': (str, True), } @@ -438,7 +438,7 @@ class RealtimeLogConfig(AWSObject): props = { 'EndPoints': ([EndPoint], True), - 'Fields': ([basestring], True), - 'Name': (basestring, True), + 'Fields': ([str], True), + 'Name': (str, True), 'SamplingRate': (float, True), } diff --git a/troposphere/cloudtrail.py b/troposphere/cloudtrail.py index 0eb62c2fb..36a83a2b5 100644 --- a/troposphere/cloudtrail.py +++ b/troposphere/cloudtrail.py @@ -4,8 +4,8 @@ class DataResource(AWSProperty): props = { - 'Type': (basestring, True), - 'Values': ([basestring], False), + 'Type': (str, True), + 'Values': ([str], False), } @@ -13,7 +13,7 @@ class EventSelector(AWSProperty): props = { 'DataResources': ([DataResource], False), 'IncludeManagementEvents': (boolean, False), - 'ReadWriteType': (basestring, False), + 'ReadWriteType': (str, False), } @@ -21,17 +21,17 @@ class Trail(AWSObject): resource_type = "AWS::CloudTrail::Trail" props = { - 'CloudWatchLogsLogGroupArn': (basestring, False), - 'CloudWatchLogsRoleArn': (basestring, False), + 'CloudWatchLogsLogGroupArn': (str, False), + 'CloudWatchLogsRoleArn': (str, False), 'EnableLogFileValidation': (boolean, False), 'EventSelectors': ([EventSelector], False), 'IncludeGlobalServiceEvents': (boolean, False), 'IsLogging': (boolean, True), 'IsMultiRegionTrail': (boolean, False), - 'KMSKeyId': (basestring, False), - 'S3BucketName': (basestring, True), - 'S3KeyPrefix': (basestring, False), - 'SnsTopicName': (basestring, False), + 'KMSKeyId': (str, False), + 'S3BucketName': (str, True), + 'S3KeyPrefix': (str, False), + 'SnsTopicName': (str, False), 'Tags': (Tags, False), - 'TrailName': (basestring, False), + 'TrailName': (str, False), } diff --git a/troposphere/cloudwatch.py b/troposphere/cloudwatch.py index c8b1ca21b..af41989a2 100644 --- a/troposphere/cloudwatch.py +++ b/troposphere/cloudwatch.py @@ -40,16 +40,16 @@ def validate_treat_missing_data(value): class MetricDimension(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class Metric(AWSProperty): props = { 'Dimensions': ([MetricDimension], False), - 'MetricName': (basestring, False), - 'Namespace': (basestring, False), + 'MetricName': (str, False), + 'Namespace': (str, False), } @@ -57,16 +57,16 @@ class MetricStat(AWSProperty): props = { 'Metric': (Metric, True), 'Period': (integer, True), - 'Stat': (basestring, True), + 'Stat': (str, True), 'Unit': (validate_unit, False), } class MetricDataQuery(AWSProperty): props = { - 'Expression': (basestring, False), - 'Id': (basestring, True), - 'Label': (basestring, False), + 'Expression': (str, False), + 'Id': (str, True), + 'Label': (str, False), 'MetricStat': (MetricStat, False), 'Period': (integer, False), 'ReturnData': (boolean, False), @@ -78,26 +78,26 @@ class Alarm(AWSObject): props = { 'ActionsEnabled': (boolean, False), - 'AlarmActions': ([basestring], False), - 'AlarmDescription': (basestring, False), - 'AlarmName': (basestring, False), - 'ComparisonOperator': (basestring, True), + 'AlarmActions': ([str], False), + 'AlarmDescription': (str, False), + 'AlarmName': (str, False), + 'ComparisonOperator': (str, True), 'DatapointsToAlarm': (positive_integer, False), 'Dimensions': ([MetricDimension], False), - 'EvaluateLowSampleCountPercentile': (basestring, False), + 'EvaluateLowSampleCountPercentile': (str, False), 'EvaluationPeriods': (positive_integer, True), - 'ExtendedStatistic': (basestring, False), - 'InsufficientDataActions': ([basestring], False), - 'MetricName': (basestring, False), + 'ExtendedStatistic': (str, False), + 'InsufficientDataActions': ([str], False), + 'MetricName': (str, False), 'Metrics': ([MetricDataQuery], False), - 'Namespace': (basestring, False), - 'OKActions': ([basestring], False), + 'Namespace': (str, False), + 'OKActions': ([str], False), 'Period': (positive_integer, False), - 'Statistic': (basestring, False), + 'Statistic': (str, False), 'Threshold': (double, False), - 'ThresholdMetricId': (basestring, False), + 'ThresholdMetricId': (str, False), 'TreatMissingData': (validate_treat_missing_data, False), - 'Unit': (basestring, False), + 'Unit': (str, False), } def validate(self): @@ -113,8 +113,8 @@ class Dashboard(AWSObject): resource_type = "AWS::CloudWatch::Dashboard" props = { - 'DashboardBody': ((basestring, dict), True), - 'DashboardName': (basestring, False), + 'DashboardBody': ((str, dict), True), + 'DashboardName': (str, False), } def validate(self): @@ -126,15 +126,15 @@ def validate(self): class Range(AWSProperty): props = { - 'EndTime': (basestring, True), - 'StartTime': (basestring, True), + 'EndTime': (str, True), + 'StartTime': (str, True), } class Configuration(AWSProperty): props = { 'ExcludedTimeRanges': ([Range], False), - 'MetricTimeZone': (basestring, False), + 'MetricTimeZone': (str, False), } @@ -144,9 +144,9 @@ class AnomalyDetector(AWSObject): props = { 'Configuration': (Configuration, False), 'Dimensions': ([MetricDimension], False), - 'MetricName': (basestring, True), - 'Namespace': (basestring, True), - 'Stat': (basestring, True) + 'MetricName': (str, True), + 'Namespace': (str, True), + 'Stat': (str, True) } @@ -154,9 +154,9 @@ class InsightRule(AWSObject): resource_type = "AWS::CloudWatch::InsightRule" props = { - 'RuleBody': (basestring, True), - 'RuleName': (basestring, True), - 'RuleState': (basestring, True), + 'RuleBody': (str, True), + 'RuleName': (str, True), + 'RuleState': (str, True), 'Tags': (Tags, False), } @@ -166,10 +166,10 @@ class CompositeAlarm(AWSObject): props = { 'ActionsEnabled': (boolean, False), - 'AlarmActions': ([basestring], False), - 'AlarmDescription': (basestring, False), - 'AlarmName': (basestring, True), - 'AlarmRule': (basestring, True), - 'InsufficientDataActions': ([basestring], False), - 'OKActions': ([basestring], False), + 'AlarmActions': ([str], False), + 'AlarmDescription': (str, False), + 'AlarmName': (str, True), + 'AlarmRule': (str, True), + 'InsufficientDataActions': ([str], False), + 'OKActions': ([str], False), } diff --git a/troposphere/codeartifact.py b/troposphere/codeartifact.py index 96d5bd26f..4916c437e 100644 --- a/troposphere/codeartifact.py +++ b/troposphere/codeartifact.py @@ -15,8 +15,8 @@ class Domain(AWSObject): resource_type = "AWS::CodeArtifact::Domain" props = { - 'DomainName': (basestring, True), - 'EncryptionKey': (basestring, False), + 'DomainName': (str, True), + 'EncryptionKey': (str, False), 'PermissionsPolicyDocument': (dict, False), 'Tags': (Tags, False), } @@ -26,12 +26,12 @@ class Repository(AWSObject): resource_type = "AWS::CodeArtifact::Repository" props = { - 'Description': (basestring, False), - 'DomainName': (basestring, True), - 'DomainOwner': (basestring, False), - 'ExternalConnections': ([basestring], False), + 'Description': (str, False), + 'DomainName': (str, True), + 'DomainOwner': (str, False), + 'ExternalConnections': ([str], False), 'PermissionsPolicyDocument': (dict, False), - 'RepositoryName': (basestring, True), + 'RepositoryName': (str, True), 'Tags': (Tags, False), - 'Upstreams': ([basestring], False), + 'Upstreams': ([str], False), } diff --git a/troposphere/codebuild.py b/troposphere/codebuild.py index b7538bc9e..db378c750 100644 --- a/troposphere/codebuild.py +++ b/troposphere/codebuild.py @@ -52,8 +52,8 @@ def validate_projectfilesystemlocation_type(projectfilesystemlocation_type): class SourceAuth(AWSProperty): props = { - 'Resource': (basestring, False), - 'Type': (basestring, True), + 'Resource': (str, False), + 'Type': (str, True), } def validate(self): @@ -68,15 +68,15 @@ def validate(self): class Artifacts(AWSProperty): props = { - 'ArtifactIdentifier': (basestring, False), + 'ArtifactIdentifier': (str, False), 'EncryptionDisabled': (boolean, False), - 'Location': (basestring, False), - 'Name': (basestring, False), - 'NamespaceType': (basestring, False), + 'Location': (str, False), + 'Name': (str, False), + 'NamespaceType': (str, False), 'OverrideArtifactName': (boolean, False), - 'Packaging': (basestring, False), - 'Path': (basestring, False), - 'Type': (basestring, True), + 'Packaging': (str, False), + 'Path': (str, False), + 'Type': (str, True), } def validate(self): @@ -101,9 +101,9 @@ def validate(self): class EnvironmentVariable(AWSProperty): props = { - 'Name': (basestring, True), - 'Type': (basestring, False), - 'Value': (basestring, True), + 'Name': (str, True), + 'Type': (str, False), + 'Value': (str, True), } def validate(self): @@ -122,21 +122,21 @@ def validate(self): class RegistryCredential(AWSProperty): props = { - 'Credential': (basestring, True), + 'Credential': (str, True), 'CredentialProvider': (validate_credentials_provider, True), } class Environment(AWSProperty): props = { - 'Certificate': (basestring, False), - 'ComputeType': (basestring, True), + 'Certificate': (str, False), + 'ComputeType': (str, True), 'EnvironmentVariables': ((list, [EnvironmentVariable]), False), - 'Image': (basestring, True), + 'Image': (str, True), 'ImagePullCredentialsType': (validate_image_pull_credentials, False), 'PrivilegedMode': (boolean, False), 'RegistryCredential': (RegistryCredential, False), - 'Type': (basestring, True), + 'Type': (str, True), } def validate(self): @@ -155,7 +155,7 @@ def validate(self): class BatchRestrictions(AWSProperty): props = { - 'ComputeTypesAllowed': ([basestring], False), + 'ComputeTypesAllowed': ([str], False), 'MaximumBuildsAllowed': (integer, False), } @@ -164,16 +164,16 @@ class ProjectBuildBatchConfig(AWSProperty): props = { 'CombineArtifacts': (boolean, False), 'Restrictions': (BatchRestrictions, False), - 'ServiceRole': (basestring, False), + 'ServiceRole': (str, False), 'TimeoutInMins': (integer, False), } class ProjectCache(AWSProperty): props = { - 'Location': (basestring, False), - 'Modes': ([basestring], False), - 'Type': (basestring, True), + 'Location': (str, False), + 'Modes': ([str], False), + 'Type': (str, True), } def validate(self): @@ -190,8 +190,8 @@ def validate(self): class BuildStatusConfig(AWSProperty): props = { - 'Context': (basestring, False), - 'TargetUrl': (basestring, False), + 'Context': (str, False), + 'TargetUrl': (str, False), } @@ -204,15 +204,15 @@ class GitSubmodulesConfig(AWSProperty): class Source(AWSProperty): props = { 'Auth': (SourceAuth, False), - 'BuildSpec': (basestring, False), + 'BuildSpec': (str, False), 'BuildStatusConfig': (BuildStatusConfig, False), 'GitCloneDepth': (positive_integer, False), 'GitSubmodulesConfig': (GitSubmodulesConfig, False), 'InsecureSsl': (boolean, False), - 'Location': (basestring, False), + 'Location': (str, False), 'ReportBuildStatus': (boolean, False), - 'SourceIdentifier': (basestring, False), - 'Type': (basestring, True), + 'SourceIdentifier': (str, False), + 'Type': (str, True), } def validate(self): @@ -258,16 +258,16 @@ def validate(self): class VpcConfig(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], True), - 'Subnets': ([basestring], True), - 'VpcId': (basestring, True), + 'SecurityGroupIds': ([str], True), + 'Subnets': ([str], True), + 'VpcId': (str, True), } class WebhookFilter(AWSProperty): props = { 'ExcludeMatchedPattern': (boolean, False), - 'Pattern': (basestring, True), + 'Pattern': (str, True), 'Type': (validate_webhookfilter_type, True), } @@ -320,8 +320,8 @@ def validate_status(status): class CloudWatchLogs(AWSProperty): props = { "Status": (validate_status, True), - "GroupName": (basestring, False), - "StreamName": (basestring, False) + "GroupName": (str, False), + "StreamName": (str, False) } @@ -329,7 +329,7 @@ class S3Logs(AWSProperty): props = { "EncryptionDisabled": (boolean, False), "Status": (validate_status, True), - "Location": (basestring, False) + "Location": (str, False) } @@ -342,17 +342,17 @@ class LogsConfig(AWSProperty): class ProjectSourceVersion(AWSProperty): props = { - 'SourceIdentifier': (basestring, True), - 'SourceVersion': (basestring, False), + 'SourceIdentifier': (str, True), + 'SourceVersion': (str, False), } class ProjectFileSystemLocation(AWSProperty): props = { - 'Identifier': (basestring, True), - 'Location': (basestring, True), - 'MountOptions': (basestring, False), - 'MountPoint': (basestring, True), + 'Identifier': (str, True), + 'Location': (str, True), + 'MountOptions': (str, False), + 'MountPoint': (str, True), 'Type': (validate_projectfilesystemlocation_type, True), } @@ -365,19 +365,19 @@ class Project(AWSObject): 'BadgeEnabled': (boolean, False), 'BuildBatchConfig': (ProjectBuildBatchConfig, False), 'Cache': (ProjectCache, False), - 'Description': (basestring, False), - 'EncryptionKey': (basestring, False), + 'Description': (str, False), + 'EncryptionKey': (str, False), 'Environment': (Environment, True), 'FileSystemLocations': ([ProjectFileSystemLocation], False), 'LogsConfig': (LogsConfig, False), - 'Name': (basestring, False), + 'Name': (str, False), 'QueuedTimeoutInMinutes': (integer, False), 'SecondaryArtifacts': ([Artifacts], False), 'SecondarySourceVersions': ([ProjectSourceVersion], False), 'SecondarySources': ([Source], False), - 'ServiceRole': (basestring, True), + 'ServiceRole': (str, True), 'Source': (Source, True), - 'SourceVersion': (basestring, False), + 'SourceVersion': (str, False), 'Tags': (Tags, False), 'TimeoutInMinutes': (integer, False), 'Triggers': (ProjectTriggers, False), @@ -387,17 +387,17 @@ class Project(AWSObject): class S3ReportExportConfig(AWSProperty): props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'EncryptionDisabled': (boolean, False), - 'EncryptionKey': (basestring, False), - 'Packaging': (basestring, False), - 'Path': (basestring, False), + 'EncryptionKey': (str, False), + 'Packaging': (str, False), + 'Path': (str, False), } class ReportExportConfig(AWSProperty): props = { - 'ExportConfigType': (basestring, True), + 'ExportConfigType': (str, True), 'S3Destination': (S3ReportExportConfig, False), } @@ -408,9 +408,9 @@ class ReportGroup(AWSObject): props = { 'DeleteReports': (boolean, False), 'ExportConfig': (ReportExportConfig, True), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -418,8 +418,8 @@ class SourceCredential(AWSObject): resource_type = "AWS::CodeBuild::SourceCredential" props = { - 'AuthType': (basestring, True), - 'ServerType': (basestring, True), - 'Token': (basestring, True), - 'Username': (basestring, False), + 'AuthType': (str, True), + 'ServerType': (str, True), + 'Token': (str, True), + 'Username': (str, False), } diff --git a/troposphere/codecommit.py b/troposphere/codecommit.py index 3a62d5ca1..84150817b 100644 --- a/troposphere/codecommit.py +++ b/troposphere/codecommit.py @@ -8,26 +8,26 @@ class S3(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, True), - 'ObjectVersion': (basestring, False), + 'Bucket': (str, True), + 'Key': (str, True), + 'ObjectVersion': (str, False), } class Code(AWSProperty): props = { - 'BranchName': (basestring, False), + 'BranchName': (str, False), 'S3': (S3, True) } class Trigger(AWSProperty): props = { - 'Branches': ([basestring], False), - 'CustomData': (basestring, False), - 'DestinationArn': (basestring, False), - 'Events': ([basestring], False), - 'Name': (basestring, False), + 'Branches': ([str], False), + 'CustomData': (str, False), + 'DestinationArn': (str, False), + 'Events': ([str], False), + 'Name': (str, False), } def validate(self): @@ -52,8 +52,8 @@ class Repository(AWSObject): props = { 'Code': (Code, False), - 'RepositoryDescription': (basestring, False), - 'RepositoryName': (basestring, True), + 'RepositoryDescription': (str, False), + 'RepositoryName': (str, True), 'Tags': (Tags, False), 'Triggers': ([Trigger], False), } diff --git a/troposphere/codedeploy.py b/troposphere/codedeploy.py index c35a1ea2a..f874639d2 100644 --- a/troposphere/codedeploy.py +++ b/troposphere/codedeploy.py @@ -14,25 +14,25 @@ class GitHubLocation(AWSProperty): props = { - 'CommitId': (basestring, True), - 'Repository': (basestring, True), + 'CommitId': (str, True), + 'Repository': (str, True), } class S3Location(AWSProperty): props = { - 'Bucket': (basestring, True), - 'BundleType': (basestring, True), - 'ETag': (basestring, False), - 'Key': (basestring, True), - 'Version': (basestring, False), + 'Bucket': (str, True), + 'BundleType': (str, True), + 'ETag': (str, False), + 'Key': (str, True), + 'Version': (str, False), } class Revision(AWSProperty): props = { 'GitHubLocation': (GitHubLocation, False), - 'RevisionType': (basestring, False), + 'RevisionType': (str, False), 'S3Location': (S3Location, False), } @@ -56,13 +56,13 @@ def deployment_type_validator(x): class AutoRollbackConfiguration(AWSProperty): props = { 'Enabled': (bool, False), - 'Events': ([basestring], False) + 'Events': ([str], False) } class Deployment(AWSProperty): props = { - 'Description': (basestring, False), + 'Description': (str, False), 'IgnoreApplicationStopFailures': (bool, False), 'Revision': (Revision, True), } @@ -77,29 +77,29 @@ class DeploymentStyle(AWSProperty): class Ec2TagFilters(AWSProperty): props = { - 'Key': (basestring, False), - 'Type': (basestring, True), - 'Value': (basestring, False), + 'Key': (str, False), + 'Type': (str, True), + 'Value': (str, False), } class TagFilters(AWSProperty): props = { - 'Key': (basestring, False), - 'Type': (basestring, False), - 'Value': (basestring, False) + 'Key': (str, False), + 'Type': (str, False), + 'Value': (str, False) } class ElbInfoList(AWSProperty): props = { - 'Name': (basestring, False) + 'Name': (str, False) } class TargetGroupInfoList(AWSProperty): props = { - 'Name': (basestring, False) + 'Name': (str, False) } @@ -119,15 +119,15 @@ def validate(self): class OnPremisesInstanceTagFilters(AWSProperty): props = { - 'Key': (basestring, False), - 'Type': (basestring, False), - 'Value': (basestring, False), + 'Key': (str, False), + 'Type': (str, False), + 'Value': (str, False), } class MinimumHealthyHosts(AWSProperty): props = { - 'Type': (basestring, False), + 'Type': (str, False), 'Value': (positive_integer, False), } @@ -136,8 +136,8 @@ class Application(AWSObject): resource_type = "AWS::CodeDeploy::Application" props = { - 'ApplicationName': (basestring, False), - 'ComputePlatform': (basestring, False), + 'ApplicationName': (str, False), + 'ComputePlatform': (str, False), } @@ -145,14 +145,14 @@ class DeploymentConfig(AWSObject): resource_type = "AWS::CodeDeploy::DeploymentConfig" props = { - 'DeploymentConfigName': (basestring, False), + 'DeploymentConfigName': (str, False), 'MinimumHealthyHosts': (MinimumHealthyHosts, False), } class Alarm(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), } @@ -166,9 +166,9 @@ class AlarmConfiguration(AWSProperty): class TriggerConfig(AWSProperty): props = { - 'TriggerEvents': ([basestring], False), - 'TriggerName': (basestring, False), - 'TriggerTargetArn': (basestring, False), + 'TriggerEvents': ([str], False), + 'TriggerName': (str, False), + 'TriggerTargetArn': (str, False), } @@ -207,12 +207,12 @@ class DeploymentGroup(AWSObject): props = { 'AlarmConfiguration': (AlarmConfiguration, False), - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'AutoRollbackConfiguration': (AutoRollbackConfiguration, False), - 'AutoScalingGroups': ([basestring], False), + 'AutoScalingGroups': ([str], False), 'Deployment': (Deployment, False), - 'DeploymentConfigName': (basestring, False), - 'DeploymentGroupName': (basestring, False), + 'DeploymentConfigName': (str, False), + 'DeploymentGroupName': (str, False), 'DeploymentStyle': (DeploymentStyle, False), 'Ec2TagFilters': ([Ec2TagFilters], False), 'Ec2TagSet': (Ec2TagSet, False), @@ -221,7 +221,7 @@ class DeploymentGroup(AWSObject): [OnPremisesInstanceTagFilters], False ), 'OnPremisesInstanceTagSet': (OnPremisesTagSet, False), - 'ServiceRoleArn': (basestring, True), + 'ServiceRoleArn': (str, True), 'TriggerConfigurations': ([TriggerConfig], False), } diff --git a/troposphere/codeguruprofiler.py b/troposphere/codeguruprofiler.py index 514cd9592..b11bbb533 100644 --- a/troposphere/codeguruprofiler.py +++ b/troposphere/codeguruprofiler.py @@ -14,8 +14,8 @@ class Channel(AWSProperty): props = { - 'channelId': (basestring, False), - 'channelUri': (basestring, True), + 'channelId': (str, False), + 'channelUri': (str, True), } @@ -25,7 +25,7 @@ class ProfilingGroup(AWSObject): props = { 'AgentPermissions': (dict, False), 'AnomalyDetectionNotificationConfiguration': ([Channel], False), - 'ComputePlatform': (basestring, False), - 'ProfilingGroupName': (basestring, True), + 'ComputePlatform': (str, False), + 'ProfilingGroupName': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/codegurureviewer.py b/troposphere/codegurureviewer.py index 2e8038346..aeba27644 100644 --- a/troposphere/codegurureviewer.py +++ b/troposphere/codegurureviewer.py @@ -14,8 +14,8 @@ class RepositoryAssociation(AWSObject): resource_type = "AWS::CodeGuruReviewer::RepositoryAssociation" props = { - 'ConnectionArn': (basestring, False), - 'Name': (basestring, True), - 'Owner': (basestring, False), - 'Type': (basestring, True), + 'ConnectionArn': (str, False), + 'Name': (str, True), + 'Owner': (str, False), + 'Type': (str, True), } diff --git a/troposphere/codepipeline.py b/troposphere/codepipeline.py index b3872599f..1441ba086 100644 --- a/troposphere/codepipeline.py +++ b/troposphere/codepipeline.py @@ -9,10 +9,10 @@ class ActionTypeId(AWSProperty): props = { - 'Category': (basestring, True), - 'Owner': (basestring, True), - 'Provider': (basestring, True), - 'Version': (basestring, True) + 'Category': (str, True), + 'Owner': (str, True), + 'Provider': (str, True), + 'Version': (str, True) } @@ -25,70 +25,70 @@ class ArtifactDetails(AWSProperty): class Blockers(AWSProperty): props = { - 'Name': (basestring, True), - 'Type': (basestring, True) + 'Name': (str, True), + 'Type': (str, True) } class ConfigurationProperties(AWSProperty): props = { - 'Description': (basestring, False), + 'Description': (str, False), 'Key': (boolean, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Queryable': (boolean, False), 'Required': (boolean, True), 'Secret': (boolean, True), - 'Type': (basestring, False) + 'Type': (str, False) } class EncryptionKey(AWSProperty): props = { - 'Id': (basestring, True), - 'Type': (basestring, True) + 'Id': (str, True), + 'Type': (str, True) } class DisableInboundStageTransitions(AWSProperty): props = { - 'Reason': (basestring, True), - 'StageName': (basestring, True) + 'Reason': (str, True), + 'StageName': (str, True) } class InputArtifacts(AWSProperty): props = { - 'Name': (basestring, True) + 'Name': (str, True) } class OutputArtifacts(AWSProperty): props = { - 'Name': (basestring, True) + 'Name': (str, True) } class Settings(AWSProperty): props = { - 'EntityUrlTemplate': (basestring, False), - 'ExecutionUrlTemplate': (basestring, False), - 'RevisionUrlTemplate': (basestring, False), - 'ThirdPartyConfigurationUrl': (basestring, False) + 'EntityUrlTemplate': (str, False), + 'ExecutionUrlTemplate': (str, False), + 'RevisionUrlTemplate': (str, False), + 'ThirdPartyConfigurationUrl': (str, False) } class ArtifactStore(AWSProperty): props = { 'EncryptionKey': (EncryptionKey, False), - 'Location': (basestring, True), - 'Type': (basestring, True) + 'Location': (str, True), + 'Type': (str, True) } class ArtifactStoreMap(AWSProperty): props = { 'ArtifactStore': (ArtifactStore, True), - 'Region': (basestring, True) + 'Region': (str, True) } @@ -97,11 +97,11 @@ class Actions(AWSProperty): 'ActionTypeId': (ActionTypeId, True), 'Configuration': (dict, False), 'InputArtifacts': ([InputArtifacts], False), - 'Name': (basestring, True), - 'Namespace': (basestring, False), + 'Name': (str, True), + 'Namespace': (str, False), 'OutputArtifacts': ([OutputArtifacts], False), - 'Region': (basestring, False), - 'RoleArn': (basestring, False), + 'Region': (str, False), + 'RoleArn': (str, False), 'RunOrder': (integer, False) } @@ -110,7 +110,7 @@ class Stages(AWSProperty): props = { 'Actions': ([Actions], True), 'Blockers': ([Blockers], False), - 'Name': (basestring, True) + 'Name': (str, True) } @@ -118,14 +118,14 @@ class CustomActionType(AWSObject): resource_type = "AWS::CodePipeline::CustomActionType" props = { - 'Category': (basestring, True), + 'Category': (str, True), 'ConfigurationProperties': ([ConfigurationProperties], False), 'InputArtifactDetails': (ArtifactDetails, True), 'OutputArtifactDetails': (ArtifactDetails, True), - 'Provider': (basestring, True), + 'Provider': (str, True), 'Settings': (Settings, False), 'Tags': (Tags, False), - 'Version': (basestring, False), + 'Version': (str, False), } @@ -137,9 +137,9 @@ class Pipeline(AWSObject): 'ArtifactStores': ([ArtifactStoreMap], False), 'DisableInboundStageTransitions': ([DisableInboundStageTransitions], False), - 'Name': (basestring, False), + 'Name': (str, False), 'RestartExecutionOnUpdate': (boolean, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Stages': ([Stages], True), 'Tags': (Tags, False), } @@ -147,15 +147,15 @@ class Pipeline(AWSObject): class WebhookAuthConfiguration(AWSProperty): props = { - 'AllowedIPRange': (basestring, False), - 'SecretToken': (basestring, False), + 'AllowedIPRange': (str, False), + 'SecretToken': (str, False), } class WebhookFilterRule(AWSProperty): props = { - 'JsonPath': (basestring, True), - 'MatchEquals': (basestring, False), + 'JsonPath': (str, True), + 'MatchEquals': (str, False), } @@ -163,12 +163,12 @@ class Webhook(AWSObject): resource_type = "AWS::CodePipeline::Webhook" props = { - 'Authentication': (basestring, True), + 'Authentication': (str, True), 'AuthenticationConfiguration': (WebhookAuthConfiguration, True), 'Filters': ([WebhookFilterRule], True), - 'Name': (basestring, False), + 'Name': (str, False), 'RegisterWithThirdParty': (boolean, False), - 'TargetAction': (basestring, True), - 'TargetPipeline': (basestring, True), + 'TargetAction': (str, True), + 'TargetPipeline': (str, True), 'TargetPipelineVersion': (integer, True), } diff --git a/troposphere/codestar.py b/troposphere/codestar.py index 65805e594..76f5088ba 100644 --- a/troposphere/codestar.py +++ b/troposphere/codestar.py @@ -14,9 +14,9 @@ class S3(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, True), - 'ObjectVersion': (basestring, False), + 'Bucket': (str, True), + 'Key': (str, True), + 'ObjectVersion': (str, False), } @@ -33,8 +33,8 @@ class GitHubRepository(AWSObject): 'Code': (Code, False), 'EnableIssues': (boolean, False), 'IsPrivate': (boolean, False), - 'RepositoryAccessToken': (basestring, True), - 'RepositoryDescription': (basestring, False), - 'RepositoryName': (basestring, True), - 'RepositoryOwner': (basestring, True), + 'RepositoryAccessToken': (str, True), + 'RepositoryDescription': (str, False), + 'RepositoryName': (str, True), + 'RepositoryOwner': (str, True), } diff --git a/troposphere/codestarconnections.py b/troposphere/codestarconnections.py index 949f2dd83..8351b8df8 100644 --- a/troposphere/codestarconnections.py +++ b/troposphere/codestarconnections.py @@ -23,8 +23,8 @@ class Connection(AWSObject): resource_type = "AWS::CodeStarConnections::Connection" props = { - 'ConnectionName': (basestring, True), - 'HostArn': (basestring, False), + 'ConnectionName': (str, True), + 'HostArn': (str, False), 'ProviderType': (validate_connection_providertype, True), 'Tags': (Tags, False), } diff --git a/troposphere/codestarnotifications.py b/troposphere/codestarnotifications.py index a1e27ca4d..ac47fd70a 100644 --- a/troposphere/codestarnotifications.py +++ b/troposphere/codestarnotifications.py @@ -13,8 +13,8 @@ class Target(AWSProperty): props = { - 'TargetAddress': (basestring, False), - 'TargetType': (basestring, False), + 'TargetAddress': (str, False), + 'TargetType': (str, False), } @@ -22,11 +22,11 @@ class NotificationRule(AWSObject): resource_type = "AWS::CodeStarNotifications::NotificationRule" props = { - 'DetailType': (basestring, True), - 'EventTypeIds': ([basestring], True), - 'Name': (basestring, True), - 'Resource': (basestring, True), - 'Status': (basestring, False), + 'DetailType': (str, True), + 'EventTypeIds': ([str], True), + 'Name': (str, True), + 'Resource': (str, True), + 'Status': (str, False), 'Tags': (dict, False), 'Targets': ([Target], True), } diff --git a/troposphere/cognito.py b/troposphere/cognito.py index 573713d16..9dbcffa10 100644 --- a/troposphere/cognito.py +++ b/troposphere/cognito.py @@ -22,24 +22,24 @@ def validate_recoveryoption_name(recoveryoption_name): class CognitoIdentityProvider(AWSProperty): props = { - 'ClientId': (basestring, False), - 'ProviderName': (basestring, False), + 'ClientId': (str, False), + 'ProviderName': (str, False), 'ServerSideTokenCheck': (bool, False), } class CognitoStreams(AWSProperty): props = { - 'RoleArn': (basestring, False), - 'StreamingStatus': (basestring, False), - 'StreamName': (basestring, False), + 'RoleArn': (str, False), + 'StreamingStatus': (str, False), + 'StreamName': (str, False), } class PushSync(AWSProperty): props = { - 'ApplicationArns': ([basestring], False), - 'RoleArn': (basestring, False), + 'ApplicationArns': ([str], False), + 'RoleArn': (str, False), } @@ -51,21 +51,21 @@ class IdentityPool(AWSObject): 'CognitoEvents': (dict, False), 'CognitoIdentityProviders': ([CognitoIdentityProvider], False), 'CognitoStreams': (CognitoStreams, False), - 'DeveloperProviderName': (basestring, False), - 'IdentityPoolName': (basestring, False), - 'OpenIdConnectProviderARNs': ([basestring], False), + 'DeveloperProviderName': (str, False), + 'IdentityPoolName': (str, False), + 'OpenIdConnectProviderARNs': ([str], False), 'PushSync': (PushSync, False), - 'SamlProviderARNs': ([basestring], False), + 'SamlProviderARNs': ([str], False), 'SupportedLoginProviders': (dict, False), } class MappingRule(AWSProperty): props = { - 'Claim': (basestring, True), - 'MatchType': (basestring, True), - 'RoleARN': (basestring, True), - 'Value': (basestring, True), + 'Claim': (str, True), + 'MatchType': (str, True), + 'RoleARN': (str, True), + 'Value': (str, True), } @@ -77,9 +77,9 @@ class RulesConfiguration(AWSProperty): class RoleMapping(AWSProperty): props = { - 'AmbiguousRoleResolution': (basestring, False), + 'AmbiguousRoleResolution': (str, False), 'RulesConfiguration': (RulesConfiguration, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -87,7 +87,7 @@ class IdentityPoolRoleAttachment(AWSObject): resource_type = "AWS::Cognito::IdentityPoolRoleAttachment" props = { - 'IdentityPoolId': (basestring, True), + 'IdentityPoolId': (str, True), 'RoleMappings': (dict, False), 'Roles': (dict, False), } @@ -95,9 +95,9 @@ class IdentityPoolRoleAttachment(AWSObject): class InviteMessageTemplate(AWSProperty): props = { - 'EmailMessage': (basestring, False), - 'EmailSubject': (basestring, False), - 'SMSMessage': (basestring, False), + 'EmailMessage': (str, False), + 'EmailSubject': (str, False), + 'SMSMessage': (str, False), } @@ -118,26 +118,26 @@ class DeviceConfiguration(AWSProperty): class EmailConfiguration(AWSProperty): props = { - 'ConfigurationSet': (basestring, False), - 'EmailSendingAccount': (basestring, False), - 'From': (basestring, False), - 'ReplyToEmailAddress': (basestring, False), - 'SourceArn': (basestring, False), + 'ConfigurationSet': (str, False), + 'EmailSendingAccount': (str, False), + 'From': (str, False), + 'ReplyToEmailAddress': (str, False), + 'SourceArn': (str, False), } class LambdaConfig(AWSProperty): props = { - 'CreateAuthChallenge': (basestring, False), - 'CustomMessage': (basestring, False), - 'DefineAuthChallenge': (basestring, False), - 'PostAuthentication': (basestring, False), - 'PostConfirmation': (basestring, False), - 'PreAuthentication': (basestring, False), - 'PreSignUp': (basestring, False), - 'PreTokenGeneration': (basestring, False), - 'UserMigration': (basestring, False), - 'VerifyAuthChallengeResponse': (basestring, False), + 'CreateAuthChallenge': (str, False), + 'CustomMessage': (str, False), + 'DefineAuthChallenge': (str, False), + 'PostAuthentication': (str, False), + 'PostConfirmation': (str, False), + 'PreAuthentication': (str, False), + 'PreSignUp': (str, False), + 'PreTokenGeneration': (str, False), + 'UserMigration': (str, False), + 'VerifyAuthChallengeResponse': (str, False), } @@ -160,24 +160,24 @@ class Policies(AWSProperty): class NumberAttributeConstraints(AWSProperty): props = { - 'MaxValue': (basestring, False), - 'MinValue': (basestring, False), + 'MaxValue': (str, False), + 'MinValue': (str, False), } class StringAttributeConstraints(AWSProperty): props = { - 'MaxLength': (basestring, False), - 'MinLength': (basestring, False), + 'MaxLength': (str, False), + 'MinLength': (str, False), } class SchemaAttribute(AWSProperty): props = { - 'AttributeDataType': (basestring, False), + 'AttributeDataType': (str, False), 'DeveloperOnlyAttribute': (boolean, False), 'Mutable': (boolean, False), - 'Name': (basestring, False), + 'Name': (str, False), 'NumberAttributeConstraints': (NumberAttributeConstraints, False), 'StringAttributeConstraints': (StringAttributeConstraints, False), 'Required': (boolean, False), @@ -186,25 +186,25 @@ class SchemaAttribute(AWSProperty): class SmsConfiguration(AWSProperty): props = { - 'ExternalId': (basestring, False), - 'SnsCallerArn': (basestring, True), + 'ExternalId': (str, False), + 'SnsCallerArn': (str, True), } class UserPoolAddOns(AWSProperty): props = { - 'AdvancedSecurityMode': (basestring, False), + 'AdvancedSecurityMode': (str, False), } class VerificationMessageTemplate(AWSProperty): props = { - 'DefaultEmailOption': (basestring, False), - 'EmailMessage': (basestring, False), - 'EmailMessageByLink': (basestring, False), - 'EmailSubject': (basestring, False), - 'EmailSubjectByLink': (basestring, False), - 'SmsMessage': (basestring, False), + 'DefaultEmailOption': (str, False), + 'EmailMessage': (str, False), + 'EmailMessageByLink': (str, False), + 'EmailSubject': (str, False), + 'EmailSubjectByLink': (str, False), + 'SmsMessage': (str, False), } @@ -233,24 +233,24 @@ class UserPool(AWSObject): props = { 'AccountRecoverySetting': (AccountRecoverySetting, False), 'AdminCreateUserConfig': (AdminCreateUserConfig, False), - 'AliasAttributes': ([basestring], False), - 'AutoVerifiedAttributes': ([basestring], False), + 'AliasAttributes': ([str], False), + 'AutoVerifiedAttributes': ([str], False), 'DeviceConfiguration': (DeviceConfiguration, False), 'EmailConfiguration': (EmailConfiguration, False), - 'EmailVerificationMessage': (basestring, False), - 'EmailVerificationSubject': (basestring, False), - 'EnabledMfas': ([basestring], False), + 'EmailVerificationMessage': (str, False), + 'EmailVerificationSubject': (str, False), + 'EnabledMfas': ([str], False), 'LambdaConfig': (LambdaConfig, False), - 'MfaConfiguration': (basestring, False), + 'MfaConfiguration': (str, False), 'Policies': (Policies, False), 'Schema': ([SchemaAttribute], False), - 'SmsAuthenticationMessage': (basestring, False), + 'SmsAuthenticationMessage': (str, False), 'SmsConfiguration': (SmsConfiguration, False), - 'SmsVerificationMessage': (basestring, False), + 'SmsVerificationMessage': (str, False), 'UserPoolAddOns': (UserPoolAddOns, False), - 'UserPoolName': (basestring, False), + 'UserPoolName': (str, False), 'UserPoolTags': (dict, False), - 'UsernameAttributes': ([basestring], False), + 'UsernameAttributes': ([str], False), 'UsernameConfiguration': (UsernameConfiguration, False), 'VerificationMessageTemplate': (VerificationMessageTemplate, False), } @@ -258,18 +258,18 @@ class UserPool(AWSObject): class AnalyticsConfiguration(AWSProperty): props = { - 'ApplicationId': (basestring, False), - 'ExternalId': (basestring, False), - 'RoleArn': (basestring, False), + 'ApplicationId': (str, False), + 'ExternalId': (str, False), + 'RoleArn': (str, False), 'UserDataShared': (boolean, False), } class TokenValidityUnits(AWSProperty): props = { - 'AccessToken': (basestring, False), - 'IdToken': (basestring, False), - 'RefreshToken': (basestring, False), + 'AccessToken': (str, False), + 'IdToken': (str, False), + 'RefreshToken': (str, False), } @@ -278,30 +278,30 @@ class UserPoolClient(AWSObject): props = { 'AccessTokenValidity': (positive_integer, False), - 'AllowedOAuthFlows': ([basestring], False), + 'AllowedOAuthFlows': ([str], False), 'AllowedOAuthFlowsUserPoolClient': (boolean, False), - 'AllowedOAuthScopes': ([basestring], False), + 'AllowedOAuthScopes': ([str], False), 'AnalyticsConfiguration': (AnalyticsConfiguration, False), - 'CallbackURLs': ([basestring], False), - 'ClientName': (basestring, False), - 'DefaultRedirectURI': (basestring, False), - 'ExplicitAuthFlows': ([basestring], False), + 'CallbackURLs': ([str], False), + 'ClientName': (str, False), + 'DefaultRedirectURI': (str, False), + 'ExplicitAuthFlows': ([str], False), 'GenerateSecret': (boolean, False), 'IdTokenValidity': (positive_integer, False), - 'LogoutURLs': ([basestring], False), - 'PreventUserExistenceErrors': (basestring, False), - 'ReadAttributes': ([basestring], False), + 'LogoutURLs': ([str], False), + 'PreventUserExistenceErrors': (str, False), + 'ReadAttributes': ([str], False), 'RefreshTokenValidity': (positive_integer, False), - 'SupportedIdentityProviders': ([basestring], False), + 'SupportedIdentityProviders': ([str], False), 'TokenValidityUnits': (TokenValidityUnits, False), - 'UserPoolId': (basestring, True), - 'WriteAttributes': ([basestring], False), + 'UserPoolId': (str, True), + 'WriteAttributes': ([str], False), } class CustomDomainConfigType(AWSProperty): props = { - 'CertificateArn': (basestring, False), + 'CertificateArn': (str, False), } @@ -310,8 +310,8 @@ class UserPoolDomain(AWSObject): props = { 'CustomDomainConfig': (CustomDomainConfigType, False), - 'Domain': (basestring, True), - 'UserPoolId': (basestring, True), + 'Domain': (str, True), + 'UserPoolId': (str, True), } @@ -319,11 +319,11 @@ class UserPoolGroup(AWSObject): resource_type = "AWS::Cognito::UserPoolGroup" props = { - 'Description': (basestring, False), - 'GroupName': (basestring, True), + 'Description': (str, False), + 'GroupName': (str, True), 'Precedence': (positive_integer, False), - 'RoleArn': (basestring, False), - 'UserPoolId': (basestring, True), + 'RoleArn': (str, False), + 'UserPoolId': (str, True), } @@ -332,18 +332,18 @@ class UserPoolIdentityProvider(AWSObject): props = { 'AttributeMapping': (dict, False), - 'IdpIdentifiers': ([basestring], False), + 'IdpIdentifiers': ([str], False), 'ProviderDetails': (dict, False), - 'ProviderName': (basestring, True), - 'ProviderType': (basestring, True), - 'UserPoolId': (basestring, True), + 'ProviderName': (str, True), + 'ProviderType': (str, True), + 'UserPoolId': (str, True), } class ResourceServerScopeType(AWSProperty): props = { - "ScopeDescription": (basestring, True), - "ScopeName": (basestring, True) + "ScopeDescription": (str, True), + "ScopeName": (str, True) } @@ -351,16 +351,16 @@ class UserPoolResourceServer(AWSObject): resource_type = "AWS::Cognito::UserPoolResourceServer" props = { - "Identifier": (basestring, True), - "Name": (basestring, True), + "Identifier": (str, True), + "Name": (str, True), "Scopes": ([ResourceServerScopeType], False), - "UserPoolId": (basestring, True) + "UserPoolId": (str, True) } class AccountTakeoverActionType(AWSProperty): props = { - 'EventAction': (basestring, True), + 'EventAction': (str, True), 'Notify': (boolean, True), } @@ -375,20 +375,20 @@ class AccountTakeoverActionsType(AWSProperty): class NotifyEmailType(AWSProperty): props = { - 'HtmlBody': (basestring, False), - 'Subject': (basestring, True), - 'TextBody': (basestring, False), + 'HtmlBody': (str, False), + 'Subject': (str, True), + 'TextBody': (str, False), } class NotifyConfigurationType(AWSProperty): props = { 'BlockEmail': (NotifyEmailType, False), - 'From': (basestring, False), + 'From': (str, False), 'MfaEmail': (NotifyEmailType, False), 'NoActionEmail': (NotifyEmailType, False), - 'ReplyTo': (basestring, False), - 'SourceArn': (basestring, True), + 'ReplyTo': (str, False), + 'SourceArn': (str, True), } @@ -401,21 +401,21 @@ class AccountTakeoverRiskConfigurationType(AWSProperty): class CompromisedCredentialsActionsType(AWSProperty): props = { - 'EventAction': (basestring, True), + 'EventAction': (str, True), } class CompromisedCredentialsRiskConfigurationType(AWSProperty): props = { 'Actions': (CompromisedCredentialsActionsType, True), - 'EventFilter': ([basestring], False), + 'EventFilter': ([str], False), } class RiskExceptionConfigurationType(AWSProperty): props = { - 'BlockedIPRangeList': ([basestring], False), - 'SkippedIPRangeList': ([basestring], False), + 'BlockedIPRangeList': ([str], False), + 'SkippedIPRangeList': ([str], False), } @@ -425,12 +425,12 @@ class UserPoolRiskConfigurationAttachment(AWSObject): props = { 'AccountTakeoverRiskConfiguration': (AccountTakeoverRiskConfigurationType, False), - 'ClientId': (basestring, True), + 'ClientId': (str, True), 'CompromisedCredentialsRiskConfiguration': (CompromisedCredentialsRiskConfigurationType, False), 'RiskExceptionConfiguration': (RiskExceptionConfigurationType, False), - 'UserPoolId': (basestring, True), + 'UserPoolId': (str, True), } @@ -438,16 +438,16 @@ class UserPoolUICustomizationAttachment(AWSObject): resource_type = "AWS::Cognito::UserPoolUICustomizationAttachment" props = { - 'CSS': (basestring, False), - 'ClientId': (basestring, True), - 'UserPoolId': (basestring, True), + 'CSS': (str, False), + 'ClientId': (str, True), + 'UserPoolId': (str, True), } class AttributeType(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, False), + 'Name': (str, True), + 'Value': (str, False), } @@ -456,12 +456,12 @@ class UserPoolUser(AWSObject): props = { 'ClientMetadata': (dict, False), - 'DesiredDeliveryMediums': ([basestring], False), + 'DesiredDeliveryMediums': ([str], False), 'ForceAliasCreation': (boolean, False), 'UserAttributes': ([AttributeType], False), - 'MessageAction': (basestring, False), - 'Username': (basestring, False), - 'UserPoolId': (basestring, True), + 'MessageAction': (str, False), + 'Username': (str, False), + 'UserPoolId': (str, True), 'ValidationData': ([AttributeType], False), } @@ -470,7 +470,7 @@ class UserPoolUserToGroupAttachment(AWSObject): resource_type = "AWS::Cognito::UserPoolUserToGroupAttachment" props = { - 'GroupName': (basestring, True), - 'Username': (basestring, True), - 'UserPoolId': (basestring, True), + 'GroupName': (str, True), + 'Username': (str, True), + 'UserPoolId': (str, True), } diff --git a/troposphere/config.py b/troposphere/config.py index fa7e2c626..20677e7be 100644 --- a/troposphere/config.py +++ b/troposphere/config.py @@ -16,18 +16,18 @@ class Scope(AWSProperty): props = { - 'ComplianceResourceId': (basestring, False), - 'ComplianceResourceTypes': ([basestring], False), - 'TagKey': (basestring, False), - 'TagValue': (basestring, False), + 'ComplianceResourceId': (str, False), + 'ComplianceResourceTypes': ([str], False), + 'TagKey': (str, False), + 'TagValue': (str, False), } class SourceDetails(AWSProperty): props = { - 'EventSource': (basestring, True), - 'MaximumExecutionFrequency': (basestring, False), - 'MessageType': (basestring, True), + 'EventSource': (str, True), + 'MaximumExecutionFrequency': (str, False), + 'MessageType': (str, True), } def validate(self): @@ -47,9 +47,9 @@ def validate(self): class Source(AWSProperty): props = { - 'Owner': (basestring, True), + 'Owner': (str, True), 'SourceDetails': ([SourceDetails], False), - 'SourceIdentifier': (basestring, True), + 'SourceIdentifier': (str, True), } @@ -57,10 +57,10 @@ class ConfigRule(AWSObject): resource_type = "AWS::Config::ConfigRule" props = { - 'ConfigRuleName': (basestring, False), - 'Description': (basestring, False), + 'ConfigRuleName': (str, False), + 'Description': (str, False), 'InputParameters': (dict, False), - 'MaximumExecutionFrequency': (basestring, False), + 'MaximumExecutionFrequency': (str, False), 'Scope': (Scope, False), 'Source': (Source, True), } @@ -70,24 +70,24 @@ class AggregationAuthorization(AWSObject): resource_type = "AWS::Config::AggregationAuthorization" props = { - 'AuthorizedAccountId': (basestring, True), - 'AuthorizedAwsRegion': (basestring, True), + 'AuthorizedAccountId': (str, True), + 'AuthorizedAwsRegion': (str, True), } class OrganizationAggregationSource(AWSProperty): props = { 'AllAwsRegions': (boolean, False), - 'AwsRegions': ([basestring], False), - 'RoleArn': (basestring, True), + 'AwsRegions': ([str], False), + 'RoleArn': (str, True), } class AccountAggregationSources(AWSProperty): props = { - 'AccountIds': ([basestring], True), + 'AccountIds': ([str], True), 'AllAwsRegions': (boolean, False), - 'AwsRegions': ([basestring], False), + 'AwsRegions': ([str], False), } @@ -96,7 +96,7 @@ class ConfigurationAggregator(AWSObject): props = { 'AccountAggregationSources': ([AccountAggregationSources], False), - 'ConfigurationAggregatorName': (basestring, True), + 'ConfigurationAggregatorName': (str, True), 'OrganizationAggregationSource': (OrganizationAggregationSource, False), } @@ -106,7 +106,7 @@ class RecordingGroup(AWSProperty): props = { 'AllSupported': (boolean, False), 'IncludeGlobalResourceTypes': (boolean, False), - 'ResourceTypes': ([basestring], False), + 'ResourceTypes': ([str], False), } @@ -114,15 +114,15 @@ class ConfigurationRecorder(AWSObject): resource_type = "AWS::Config::ConfigurationRecorder" props = { - 'Name': (basestring, False), + 'Name': (str, False), 'RecordingGroup': (RecordingGroup, False), - 'RoleARN': (basestring, True), + 'RoleARN': (str, True), } class ConfigSnapshotDeliveryProperties(AWSProperty): props = { - 'DeliveryFrequency': (basestring, False), + 'DeliveryFrequency': (str, False), } @@ -132,37 +132,37 @@ class DeliveryChannel(AWSObject): props = { 'ConfigSnapshotDeliveryProperties': (ConfigSnapshotDeliveryProperties, False), - 'Name': (basestring, False), - 'S3BucketName': (basestring, True), - 'S3KeyPrefix': (basestring, False), - 'SnsTopicARN': (basestring, False), + 'Name': (str, False), + 'S3BucketName': (str, True), + 'S3KeyPrefix': (str, False), + 'SnsTopicARN': (str, False), } class OrganizationCustomRuleMetadata(AWSProperty): props = { - 'Description': (basestring, False), - 'InputParameters': (basestring, False), - 'LambdaFunctionArn': (basestring, True), - 'MaximumExecutionFrequency': (basestring, False), - 'OrganizationConfigRuleTriggerTypes': ([basestring], True), - 'ResourceIdScope': (basestring, False), - 'ResourceTypesScope': ([basestring], False), - 'TagKeyScope': (basestring, False), - 'TagValueScope': (basestring, False), + 'Description': (str, False), + 'InputParameters': (str, False), + 'LambdaFunctionArn': (str, True), + 'MaximumExecutionFrequency': (str, False), + 'OrganizationConfigRuleTriggerTypes': ([str], True), + 'ResourceIdScope': (str, False), + 'ResourceTypesScope': ([str], False), + 'TagKeyScope': (str, False), + 'TagValueScope': (str, False), } class OrganizationManagedRuleMetadata(AWSProperty): props = { - 'Description': (basestring, False), - 'InputParameters': (basestring, False), - 'MaximumExecutionFrequency': (basestring, False), - 'ResourceIdScope': (basestring, False), - 'ResourceTypesScope': ([basestring], False), - 'RuleIdentifier': (basestring, True), - 'TagKeyScope': (basestring, False), - 'TagValueScope': (basestring, False), + 'Description': (str, False), + 'InputParameters': (str, False), + 'MaximumExecutionFrequency': (str, False), + 'ResourceIdScope': (str, False), + 'ResourceTypesScope': ([str], False), + 'RuleIdentifier': (str, True), + 'TagKeyScope': (str, False), + 'TagValueScope': (str, False), } @@ -170,8 +170,8 @@ class OrganizationConfigRule(AWSObject): resource_type = "AWS::Config::OrganizationConfigRule" props = { - 'ExcludedAccounts': ([basestring], False), - 'OrganizationConfigRuleName': (basestring, True), + 'ExcludedAccounts': ([str], False), + 'OrganizationConfigRuleName': (str, True), 'OrganizationCustomRuleMetadata': (OrganizationCustomRuleMetadata, False), 'OrganizationManagedRuleMetadata': @@ -197,22 +197,22 @@ class RemediationConfiguration(AWSObject): props = { 'Automatic': (boolean, False), - 'ConfigRuleName': (basestring, True), + 'ConfigRuleName': (str, True), 'ExecutionControls': (ExecutionControls, False), 'MaximumAutomaticAttempts': (integer, False), 'Parameters': (dict, False), - 'ResourceType': (basestring, False), + 'ResourceType': (str, False), 'RetryAttemptSeconds': (integer, False), - 'TargetId': (basestring, True), - 'TargetType': (basestring, True), - 'TargetVersion': (basestring, False), + 'TargetId': (str, True), + 'TargetType': (str, True), + 'TargetVersion': (str, False), } class ConformancePackInputParameter(AWSProperty): props = { - 'ParameterName': (basestring, True), - 'ParameterValue': (basestring, True), + 'ParameterName': (str, True), + 'ParameterValue': (str, True), } @@ -221,11 +221,11 @@ class ConformancePack(AWSObject): props = { 'ConformancePackInputParameters': ([ConformancePackInputParameter], False), # NOQA - 'ConformancePackName': (basestring, True), - 'DeliveryS3Bucket': (basestring, True), - 'DeliveryS3KeyPrefix': (basestring, False), - 'TemplateBody': (basestring, False), - 'TemplateS3Uri': (basestring, False), + 'ConformancePackName': (str, True), + 'DeliveryS3Bucket': (str, True), + 'DeliveryS3KeyPrefix': (str, False), + 'TemplateBody': (str, False), + 'TemplateS3Uri': (str, False), } @@ -234,12 +234,12 @@ class OrganizationConformancePack(AWSObject): props = { 'ConformancePackInputParameters': ([ConformancePackInputParameter], False), # NOQA - 'DeliveryS3Bucket': (basestring, True), - 'DeliveryS3KeyPrefix': (basestring, False), - 'ExcludedAccounts': ([basestring], False), - 'OrganizationConformancePackName': (basestring, True), - 'TemplateBody': (basestring, False), - 'TemplateS3Uri': (basestring, False), + 'DeliveryS3Bucket': (str, True), + 'DeliveryS3KeyPrefix': (str, False), + 'ExcludedAccounts': ([str], False), + 'OrganizationConformancePackName': (str, True), + 'TemplateBody': (str, False), + 'TemplateS3Uri': (str, False), } @@ -247,8 +247,8 @@ class StoredQuery(AWSObject): resource_type = "AWS::Config::StoredQuery" props = { - 'QueryDescription': (basestring, False), - 'QueryExpression': (basestring, True), - 'QueryName': (basestring, True), + 'QueryDescription': (str, False), + 'QueryExpression': (str, True), + 'QueryName': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/databrew.py b/troposphere/databrew.py index 46e6c6398..bbef0d627 100644 --- a/troposphere/databrew.py +++ b/troposphere/databrew.py @@ -18,17 +18,17 @@ class Dataset(AWSObject): resource_type = "AWS::DataBrew::Dataset" props = { - 'Format': (basestring, False), + 'Format': (str, False), 'FormatOptions': (dict, False), 'Input': (dict, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } class CsvOutputOptions(AWSProperty): props = { - 'Delimiter': (basestring, False), + 'Delimiter': (str, False), } @@ -40,19 +40,19 @@ class OutputFormatOptions(AWSProperty): class S3Location(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, False), + 'Bucket': (str, True), + 'Key': (str, False), } class Output(AWSProperty): props = { - 'CompressionFormat': (basestring, False), - 'Format': (basestring, False), + 'CompressionFormat': (str, False), + 'Format': (str, False), 'FormatOptions': (OutputFormatOptions, False), 'Location': (S3Location, True), 'Overwrite': (boolean, False), - 'PartitionColumns': ([basestring], False), + 'PartitionColumns': ([str], False), } @@ -60,22 +60,22 @@ class Job(AWSObject): resource_type = "AWS::DataBrew::Job" props = { - 'DatasetName': (basestring, False), - 'EncryptionKeyArn': (basestring, False), - 'EncryptionMode': (basestring, False), + 'DatasetName': (str, False), + 'EncryptionKeyArn': (str, False), + 'EncryptionMode': (str, False), 'JobSample': (dict, False), - 'LogSubscription': (basestring, False), + 'LogSubscription': (str, False), 'MaxCapacity': (integer, False), 'MaxRetries': (integer, False), - 'Name': (basestring, True), + 'Name': (str, True), 'OutputLocation': (dict, False), 'Outputs': ([Output], False), - 'ProjectName': (basestring, False), + 'ProjectName': (str, False), 'Recipe': (dict, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), 'Timeout': (integer, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -83,10 +83,10 @@ class Project(AWSObject): resource_type = "AWS::DataBrew::Project" props = { - 'DatasetName': (basestring, True), - 'Name': (basestring, True), - 'RecipeName': (basestring, True), - 'RoleArn': (basestring, True), + 'DatasetName': (str, True), + 'Name': (str, True), + 'RecipeName': (str, True), + 'RoleArn': (str, True), 'Sample': (dict, False), 'Tags': (Tags, False), } @@ -94,9 +94,9 @@ class Project(AWSObject): class DataCatalogInputDefinition(AWSProperty): props = { - 'CatalogId': (basestring, False), - 'DatabaseName': (basestring, False), - 'TableName': (basestring, False), + 'CatalogId': (str, False), + 'DatabaseName': (str, False), + 'TableName': (str, False), 'TempDirectory': (S3Location, False), } @@ -110,122 +110,122 @@ class SecondaryInput(AWSProperty): class RecipeParameters(AWSProperty): props = { - 'AggregateFunction': (basestring, False), - 'Base': (basestring, False), - 'CaseStatement': (basestring, False), - 'CategoryMap': (basestring, False), - 'CharsToRemove': (basestring, False), - 'CollapseConsecutiveWhitespace': (basestring, False), - 'ColumnDataType': (basestring, False), - 'ColumnRange': (basestring, False), - 'Count': (basestring, False), - 'CustomCharacters': (basestring, False), - 'CustomStopWords': (basestring, False), - 'CustomValue': (basestring, False), - 'DatasetsColumns': (basestring, False), - 'DateAddValue': (basestring, False), - 'DateTimeFormat': (basestring, False), - 'DateTimeParameters': (basestring, False), - 'DeleteOtherRows': (basestring, False), - 'Delimiter': (basestring, False), - 'EndPattern': (basestring, False), - 'EndPosition': (basestring, False), - 'EndValue': (basestring, False), - 'ExpandContractions': (basestring, False), - 'Exponent': (basestring, False), - 'FalseString': (basestring, False), - 'GroupByAggFunctionOptions': (basestring, False), - 'GroupByColumns': (basestring, False), - 'HiddenColumns': (basestring, False), - 'IgnoreCase': (basestring, False), - 'IncludeInSplit': (basestring, False), + 'AggregateFunction': (str, False), + 'Base': (str, False), + 'CaseStatement': (str, False), + 'CategoryMap': (str, False), + 'CharsToRemove': (str, False), + 'CollapseConsecutiveWhitespace': (str, False), + 'ColumnDataType': (str, False), + 'ColumnRange': (str, False), + 'Count': (str, False), + 'CustomCharacters': (str, False), + 'CustomStopWords': (str, False), + 'CustomValue': (str, False), + 'DatasetsColumns': (str, False), + 'DateAddValue': (str, False), + 'DateTimeFormat': (str, False), + 'DateTimeParameters': (str, False), + 'DeleteOtherRows': (str, False), + 'Delimiter': (str, False), + 'EndPattern': (str, False), + 'EndPosition': (str, False), + 'EndValue': (str, False), + 'ExpandContractions': (str, False), + 'Exponent': (str, False), + 'FalseString': (str, False), + 'GroupByAggFunctionOptions': (str, False), + 'GroupByColumns': (str, False), + 'HiddenColumns': (str, False), + 'IgnoreCase': (str, False), + 'IncludeInSplit': (str, False), 'Input': (dict, False), - 'Interval': (basestring, False), - 'IsText': (basestring, False), - 'JoinKeys': (basestring, False), - 'JoinType': (basestring, False), - 'LeftColumns': (basestring, False), - 'Limit': (basestring, False), - 'LowerBound': (basestring, False), - 'MapType': (basestring, False), - 'ModeType': (basestring, False), + 'Interval': (str, False), + 'IsText': (str, False), + 'JoinKeys': (str, False), + 'JoinType': (str, False), + 'LeftColumns': (str, False), + 'Limit': (str, False), + 'LowerBound': (str, False), + 'MapType': (str, False), + 'ModeType': (str, False), 'MultiLine': (boolean, False), - 'NumRows': (basestring, False), - 'NumRowsAfter': (basestring, False), - 'NumRowsBefore': (basestring, False), - 'OrderByColumn': (basestring, False), - 'OrderByColumns': (basestring, False), - 'Other': (basestring, False), - 'Pattern': (basestring, False), - 'PatternOption1': (basestring, False), - 'PatternOption2': (basestring, False), - 'PatternOptions': (basestring, False), - 'Period': (basestring, False), - 'Position': (basestring, False), - 'RemoveAllPunctuation': (basestring, False), - 'RemoveAllQuotes': (basestring, False), - 'RemoveAllWhitespace': (basestring, False), - 'RemoveCustomCharacters': (basestring, False), - 'RemoveCustomValue': (basestring, False), - 'RemoveLeadingAndTrailingPunctuation': (basestring, False), - 'RemoveLeadingAndTrailingQuotes': (basestring, False), - 'RemoveLeadingAndTrailingWhitespace': (basestring, False), - 'RemoveLetters': (basestring, False), - 'RemoveNumbers': (basestring, False), - 'RemoveSourceColumn': (basestring, False), - 'RemoveSpecialCharacters': (basestring, False), - 'RightColumns': (basestring, False), - 'SampleSize': (basestring, False), - 'SampleType': (basestring, False), - 'SecondInput': (basestring, False), + 'NumRows': (str, False), + 'NumRowsAfter': (str, False), + 'NumRowsBefore': (str, False), + 'OrderByColumn': (str, False), + 'OrderByColumns': (str, False), + 'Other': (str, False), + 'Pattern': (str, False), + 'PatternOption1': (str, False), + 'PatternOption2': (str, False), + 'PatternOptions': (str, False), + 'Period': (str, False), + 'Position': (str, False), + 'RemoveAllPunctuation': (str, False), + 'RemoveAllQuotes': (str, False), + 'RemoveAllWhitespace': (str, False), + 'RemoveCustomCharacters': (str, False), + 'RemoveCustomValue': (str, False), + 'RemoveLeadingAndTrailingPunctuation': (str, False), + 'RemoveLeadingAndTrailingQuotes': (str, False), + 'RemoveLeadingAndTrailingWhitespace': (str, False), + 'RemoveLetters': (str, False), + 'RemoveNumbers': (str, False), + 'RemoveSourceColumn': (str, False), + 'RemoveSpecialCharacters': (str, False), + 'RightColumns': (str, False), + 'SampleSize': (str, False), + 'SampleType': (str, False), + 'SecondInput': (str, False), 'SecondaryInputs': ([SecondaryInput], False), 'SheetIndexes': ([integer], False), - 'SheetNames': ([basestring], False), - 'SourceColumn': (basestring, False), - 'SourceColumn1': (basestring, False), - 'SourceColumn2': (basestring, False), - 'SourceColumns': (basestring, False), - 'StartColumnIndex': (basestring, False), - 'StartPattern': (basestring, False), - 'StartPosition': (basestring, False), - 'StartValue': (basestring, False), - 'StemmingMode': (basestring, False), - 'StepCount': (basestring, False), - 'StepIndex': (basestring, False), - 'StopWordsMode': (basestring, False), - 'Strategy': (basestring, False), - 'TargetColumn': (basestring, False), - 'TargetColumnNames': (basestring, False), - 'TargetDateFormat': (basestring, False), - 'TargetIndex': (basestring, False), - 'TimeZone': (basestring, False), - 'TokenizerPattern': (basestring, False), - 'TrueString': (basestring, False), - 'UdfLang': (basestring, False), - 'Units': (basestring, False), - 'UnpivotColumn': (basestring, False), - 'UpperBound': (basestring, False), - 'UseNewDataFrame': (basestring, False), - 'Value': (basestring, False), - 'Value1': (basestring, False), - 'Value2': (basestring, False), - 'ValueColumn': (basestring, False), - 'ViewFrame': (basestring, False), + 'SheetNames': ([str], False), + 'SourceColumn': (str, False), + 'SourceColumn1': (str, False), + 'SourceColumn2': (str, False), + 'SourceColumns': (str, False), + 'StartColumnIndex': (str, False), + 'StartPattern': (str, False), + 'StartPosition': (str, False), + 'StartValue': (str, False), + 'StemmingMode': (str, False), + 'StepCount': (str, False), + 'StepIndex': (str, False), + 'StopWordsMode': (str, False), + 'Strategy': (str, False), + 'TargetColumn': (str, False), + 'TargetColumnNames': (str, False), + 'TargetDateFormat': (str, False), + 'TargetIndex': (str, False), + 'TimeZone': (str, False), + 'TokenizerPattern': (str, False), + 'TrueString': (str, False), + 'UdfLang': (str, False), + 'Units': (str, False), + 'UnpivotColumn': (str, False), + 'UpperBound': (str, False), + 'UseNewDataFrame': (str, False), + 'Value': (str, False), + 'Value1': (str, False), + 'Value2': (str, False), + 'ValueColumn': (str, False), + 'ViewFrame': (str, False), } class Action(AWSProperty): props = { - 'Operation': (basestring, True), + 'Operation': (str, True), 'Parameters': (RecipeParameters, False), } class ConditionExpression(AWSProperty): props = { - 'Condition': (basestring, True), - 'TargetColumn': (basestring, True), - 'Value': (basestring, False), + 'Condition': (str, True), + 'TargetColumn': (str, True), + 'Value': (str, False), } @@ -240,8 +240,8 @@ class Recipe(AWSObject): resource_type = "AWS::DataBrew::Recipe" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Steps': ([RecipeStep], True), 'Tags': (Tags, False), } @@ -251,8 +251,8 @@ class Schedule(AWSObject): resource_type = "AWS::DataBrew::Schedule" props = { - 'CronExpression': (basestring, True), - 'JobNames': ([basestring], False), - 'Name': (basestring, True), + 'CronExpression': (str, True), + 'JobNames': ([str], False), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/datapipeline.py b/troposphere/datapipeline.py index c10c5b85c..de2b2208e 100644 --- a/troposphere/datapipeline.py +++ b/troposphere/datapipeline.py @@ -4,45 +4,45 @@ class ParameterObjectAttribute(AWSProperty): props = { - 'Key': (basestring, True), - 'StringValue': (basestring, False), + 'Key': (str, True), + 'StringValue': (str, False), } class ParameterObject(AWSProperty): props = { 'Attributes': ([ParameterObjectAttribute], True), - 'Id': (basestring, True), + 'Id': (str, True), } class ParameterValue(AWSProperty): props = { - 'Id': (basestring, True), - 'StringValue': (basestring, True), + 'Id': (str, True), + 'StringValue': (str, True), } class ObjectField(AWSProperty): props = { - 'Key': (basestring, True), - 'RefValue': (basestring, False), - 'StringValue': (basestring, False), + 'Key': (str, True), + 'RefValue': (str, False), + 'StringValue': (str, False), } class PipelineObject(AWSProperty): props = { 'Fields': ([ObjectField], True), - 'Id': (basestring, True), - 'Name': (basestring, True), + 'Id': (str, True), + 'Name': (str, True), } class PipelineTag(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -51,8 +51,8 @@ class Pipeline(AWSObject): props = { 'Activate': (boolean, False), - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'ParameterObjects': ([ParameterObject], False), 'ParameterValues': ([ParameterValue], False), 'PipelineObjects': ([PipelineObject], True), diff --git a/troposphere/datasync.py b/troposphere/datasync.py index 1d398c4c1..73199e241 100644 --- a/troposphere/datasync.py +++ b/troposphere/datasync.py @@ -17,19 +17,19 @@ class Agent(AWSObject): resource_type = "AWS::DataSync::Agent" props = { - 'ActivationKey': (basestring, True), - 'AgentName': (basestring, False), - 'SecurityGroupArns': ([basestring], False), - 'SubnetArns': ([basestring], False), + 'ActivationKey': (str, True), + 'AgentName': (str, False), + 'SecurityGroupArns': ([str], False), + 'SubnetArns': ([str], False), 'Tags': (Tags, False), - 'VpcEndpointId': (basestring, False), + 'VpcEndpointId': (str, False), } class Ec2Config(AWSProperty): props = { - 'SecurityGroupArns': ([basestring], True), - 'SubnetArn': (basestring, True), + 'SecurityGroupArns': ([str], True), + 'SubnetArn': (str, True), } @@ -38,8 +38,8 @@ class LocationEFS(AWSObject): props = { 'Ec2Config': (Ec2Config, True), - 'EfsFilesystemArn': (basestring, True), - 'Subdirectory': (basestring, False), + 'EfsFilesystemArn': (str, True), + 'Subdirectory': (str, False), 'Tags': (Tags, False), } @@ -48,25 +48,25 @@ class LocationFSxWindows(AWSObject): resource_type = "AWS::DataSync::LocationFSxWindows" props = { - 'Domain': (basestring, False), - 'FsxFilesystemArn': (basestring, True), - 'Password': (basestring, True), - 'SecurityGroupArns': ([basestring], True), - 'Subdirectory': (basestring, False), + 'Domain': (str, False), + 'FsxFilesystemArn': (str, True), + 'Password': (str, True), + 'SecurityGroupArns': ([str], True), + 'Subdirectory': (str, False), 'Tags': (Tags, False), - 'User': (basestring, True), + 'User': (str, True), } class MountOptions(AWSProperty): props = { - 'Version': (basestring, False), + 'Version': (str, False), } class OnPremConfig(AWSProperty): props = { - 'AgentArns': ([basestring], True), + 'AgentArns': ([str], True), } @@ -76,8 +76,8 @@ class LocationNFS(AWSObject): props = { 'MountOptions': (MountOptions, False), 'OnPremConfig': (OnPremConfig, True), - 'ServerHostname': (basestring, True), - 'Subdirectory': (basestring, True), + 'ServerHostname': (str, True), + 'Subdirectory': (str, True), 'Tags': (Tags, False), } @@ -86,21 +86,21 @@ class LocationObjectStorage(AWSObject): resource_type = "AWS::DataSync::LocationObjectStorage" props = { - 'AccessKey': (basestring, False), - 'AgentArns': ([basestring], True), - 'BucketName': (basestring, True), - 'SecretKey': (basestring, False), - 'ServerHostname': (basestring, True), + 'AccessKey': (str, False), + 'AgentArns': ([str], True), + 'BucketName': (str, True), + 'SecretKey': (str, False), + 'ServerHostname': (str, True), 'ServerPort': (integer, False), - 'ServerProtocol': (basestring, False), - 'Subdirectory': (basestring, False), + 'ServerProtocol': (str, False), + 'Subdirectory': (str, False), 'Tags': (Tags, False), } class S3Config(AWSProperty): props = { - 'BucketAccessRoleArn': (basestring, True), + 'BucketAccessRoleArn': (str, True), } @@ -108,10 +108,10 @@ class LocationS3(AWSObject): resource_type = "AWS::DataSync::LocationS3" props = { - 'S3BucketArn': (basestring, True), + 'S3BucketArn': (str, True), 'S3Config': (S3Config, True), - 'S3StorageClass': (basestring, False), - 'Subdirectory': (basestring, False), + 'S3StorageClass': (str, False), + 'Subdirectory': (str, False), 'Tags': (Tags, False), } @@ -120,45 +120,45 @@ class LocationSMB(AWSObject): resource_type = "AWS::DataSync::LocationSMB" props = { - 'AgentArns': ([basestring], True), - 'Domain': (basestring, False), + 'AgentArns': ([str], True), + 'Domain': (str, False), 'MountOptions': (MountOptions, False), - 'Password': (basestring, True), - 'ServerHostname': (basestring, True), - 'Subdirectory': (basestring, True), + 'Password': (str, True), + 'ServerHostname': (str, True), + 'Subdirectory': (str, True), 'Tags': (Tags, False), - 'User': (basestring, True), + 'User': (str, True), } class FilterRule(AWSProperty): props = { - 'FilterType': (basestring, False), - 'Value': (basestring, False), + 'FilterType': (str, False), + 'Value': (str, False), } class Options(AWSProperty): props = { - 'Atime': (basestring, False), + 'Atime': (str, False), 'BytesPerSecond': (integer, False), - 'Gid': (basestring, False), - 'LogLevel': (basestring, False), - 'Mtime': (basestring, False), - 'OverwriteMode': (basestring, False), - 'PosixPermissions': (basestring, False), - 'PreserveDeletedFiles': (basestring, False), - 'PreserveDevices': (basestring, False), - 'TaskQueueing': (basestring, False), - 'TransferMode': (basestring, False), - 'Uid': (basestring, False), - 'VerifyMode': (basestring, False), + 'Gid': (str, False), + 'LogLevel': (str, False), + 'Mtime': (str, False), + 'OverwriteMode': (str, False), + 'PosixPermissions': (str, False), + 'PreserveDeletedFiles': (str, False), + 'PreserveDevices': (str, False), + 'TaskQueueing': (str, False), + 'TransferMode': (str, False), + 'Uid': (str, False), + 'VerifyMode': (str, False), } class TaskSchedule(AWSProperty): props = { - 'ScheduleExpression': (basestring, True), + 'ScheduleExpression': (str, True), } @@ -166,12 +166,12 @@ class Task(AWSObject): resource_type = "AWS::DataSync::Task" props = { - 'CloudWatchLogGroupArn': (basestring, False), - 'DestinationLocationArn': (basestring, True), + 'CloudWatchLogGroupArn': (str, False), + 'DestinationLocationArn': (str, True), 'Excludes': ([FilterRule], False), - 'Name': (basestring, False), + 'Name': (str, False), 'Options': (Options, False), 'Schedule': (TaskSchedule, False), - 'SourceLocationArn': (basestring, True), + 'SourceLocationArn': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/dax.py b/troposphere/dax.py index 611c7a763..446ad3ebd 100644 --- a/troposphere/dax.py +++ b/troposphere/dax.py @@ -17,18 +17,18 @@ class Cluster(AWSObject): resource_type = "AWS::DAX::Cluster" props = { - 'AvailabilityZones': (basestring, False), - 'ClusterName': (basestring, False), - 'Description': (basestring, False), - 'IAMRoleARN': (basestring, True), - 'NodeType': (basestring, True), - 'NotificationTopicARN': (basestring, False), - 'ParameterGroupName': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), - 'ReplicationFactor': (basestring, True), + 'AvailabilityZones': (str, False), + 'ClusterName': (str, False), + 'Description': (str, False), + 'IAMRoleARN': (str, True), + 'NodeType': (str, True), + 'NotificationTopicARN': (str, False), + 'ParameterGroupName': (str, False), + 'PreferredMaintenanceWindow': (str, False), + 'ReplicationFactor': (str, True), 'SSESpecification': (SSESpecification, False), - 'SecurityGroupIds': ([basestring], False), - 'SubnetGroupName': (basestring, True), + 'SecurityGroupIds': ([str], False), + 'SubnetGroupName': (str, True), 'Tags': (dict, False), } @@ -37,8 +37,8 @@ class ParameterGroup(AWSObject): resource_type = "AWS::DAX::ParameterGroup" props = { - 'Description': (basestring, False), - 'ParameterGroupName': (basestring, False), + 'Description': (str, False), + 'ParameterGroupName': (str, False), 'ParameterNameValues': (dict, False), } @@ -47,7 +47,7 @@ class SubnetGroup(AWSObject): resource_type = "AWS::DAX::SubnetGroup" props = { - 'Description': (basestring, False), - 'SubnetGroupName': (basestring, False), - 'SubnetIds': ([basestring], False), + 'Description': (str, False), + 'SubnetGroupName': (str, False), + 'SubnetIds': ([str], False), } diff --git a/troposphere/detective.py b/troposphere/detective.py index fd8d45858..eb30dbe43 100644 --- a/troposphere/detective.py +++ b/troposphere/detective.py @@ -19,8 +19,8 @@ class MemberInvitation(AWSObject): props = { 'DisableEmailNotification': (boolean, False), - 'GraphArn': (basestring, True), - 'MemberEmailAddress': (basestring, True), - 'MemberId': (basestring, True), - 'Message': (basestring, False), + 'GraphArn': (str, True), + 'MemberEmailAddress': (str, True), + 'MemberId': (str, True), + 'Message': (str, False), } diff --git a/troposphere/devopsguru.py b/troposphere/devopsguru.py index 87424f180..d43cf6041 100644 --- a/troposphere/devopsguru.py +++ b/troposphere/devopsguru.py @@ -13,7 +13,7 @@ class SnsChannelConfig(AWSProperty): props = { - 'TopicArn': (basestring, False), + 'TopicArn': (str, False), } @@ -33,7 +33,7 @@ class NotificationChannel(AWSObject): class CloudFormationCollectionFilter(AWSProperty): props = { - 'StackNames': ([basestring], False), + 'StackNames': ([str], False), } diff --git a/troposphere/directoryservice.py b/troposphere/directoryservice.py index f9371881a..784bbdd74 100644 --- a/troposphere/directoryservice.py +++ b/troposphere/directoryservice.py @@ -9,8 +9,8 @@ class VpcSettings(AWSProperty): props = { - 'SubnetIds': ([basestring], True), - 'VpcId': (basestring, True), + 'SubnetIds': ([str], True), + 'VpcId': (str, True), } @@ -19,11 +19,11 @@ class MicrosoftAD(AWSObject): props = { 'CreateAlias': (boolean, False), - 'Edition': (basestring, False), + 'Edition': (str, False), 'EnableSso': (boolean, False), - 'Name': (basestring, True), - 'Password': (basestring, True), - 'ShortName': (basestring, False), + 'Name': (str, True), + 'Password': (str, True), + 'ShortName': (str, False), 'VpcSettings': (VpcSettings, True) } @@ -33,11 +33,11 @@ class SimpleAD(AWSObject): props = { 'CreateAlias': (boolean, False), - 'Description': (basestring, False), + 'Description': (str, False), 'EnableSso': (boolean, False), - 'Name': (basestring, True), - 'Password': (basestring, True), - 'ShortName': (basestring, False), - 'Size': (basestring, True), + 'Name': (str, True), + 'Password': (str, True), + 'ShortName': (str, False), + 'Size': (str, True), 'VpcSettings': (VpcSettings, True), } diff --git a/troposphere/dlm.py b/troposphere/dlm.py index 4a3fe2111..ab41864db 100644 --- a/troposphere/dlm.py +++ b/troposphere/dlm.py @@ -49,33 +49,33 @@ class CreateRule(AWSProperty): props = { 'Interval': (validate_interval, True), 'IntervalUnit': (validate_interval_unit, True), - 'Times': ([basestring], False), + 'Times': ([str], False), } class CrossRegionCopyRetainRule(AWSProperty): props = { 'Interval': (integer, True), - 'IntervalUnit': (basestring, True), + 'IntervalUnit': (str, True), } class CrossRegionCopyRule(AWSProperty): props = { - 'CmkArn': (basestring, False), + 'CmkArn': (str, False), 'CopyTags': (boolean, False), 'Encrypted': (boolean, True), 'RetainRule': (CrossRegionCopyRetainRule, False), - 'TargetRegion': (basestring, True), + 'TargetRegion': (str, True), } class FastRestoreRule(AWSProperty): props = { - 'AvailabilityZones': ([basestring], False), + 'AvailabilityZones': ([str], False), 'Count': (integer, False), 'Interval': (integer, False), - 'IntervalUnit': (basestring, False), + 'IntervalUnit': (str, False), } @@ -91,7 +91,7 @@ class Schedule(AWSProperty): 'CreateRule': (CreateRule, False), 'CrossRegionCopyRules': ([CrossRegionCopyRule], False), 'FastRestoreRule': (FastRestoreRule, False), - 'Name': (basestring, False), + 'Name': (str, False), 'RetainRule': (RetainRule, False), 'TagsToAdd': ((Tags, list), False), } @@ -100,8 +100,8 @@ class Schedule(AWSProperty): class PolicyDetails(AWSProperty): props = { 'Parameters': (Parameters, False), - 'PolicyType': (basestring, False), - 'ResourceTypes': ([basestring], False), + 'PolicyType': (str, False), + 'ResourceTypes': ([str], False), 'Schedules': ([Schedule], False), 'TargetTags': ((Tags, list), False), } @@ -111,8 +111,8 @@ class LifecyclePolicy(AWSObject): resource_type = "AWS::DLM::LifecyclePolicy" props = { - 'Description': (basestring, False), - 'ExecutionRoleArn': (basestring, False), + 'Description': (str, False), + 'ExecutionRoleArn': (str, False), 'PolicyDetails': (PolicyDetails, False), 'State': (validate_state, False), } diff --git a/troposphere/dms.py b/troposphere/dms.py index 01b76ba5a..86528bc82 100644 --- a/troposphere/dms.py +++ b/troposphere/dms.py @@ -16,85 +16,85 @@ class Certificate(AWSObject): resource_type = "AWS::DMS::Certificate" props = { - 'CertificateIdentifier': (basestring, False), - 'CertificatePem': (basestring, False), - 'CertificateWallet': (basestring, False), + 'CertificateIdentifier': (str, False), + 'CertificatePem': (str, False), + 'CertificateWallet': (str, False), } class DocDbSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } class DynamoDbSettings(AWSProperty): props = { - 'ServiceAccessRoleArn': (basestring, False), + 'ServiceAccessRoleArn': (str, False), } class ElasticsearchSettings(AWSProperty): props = { - 'EndpointUri': (basestring, False), + 'EndpointUri': (str, False), 'ErrorRetryDuration': (integer, False), 'FullLoadErrorPercentage': (integer, False), - 'ServiceAccessRoleArn': (basestring, False), + 'ServiceAccessRoleArn': (str, False), } class IbmDb2Settings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } class KafkaSettings(AWSProperty): props = { - 'Broker': (basestring, False), - 'Topic': (basestring, False), + 'Broker': (str, False), + 'Topic': (str, False), } class KinesisSettings(AWSProperty): props = { - 'MessageFormat': (basestring, False), - 'ServiceAccessRoleArn': (basestring, False), - 'StreamArn': (basestring, False), + 'MessageFormat': (str, False), + 'ServiceAccessRoleArn': (str, False), + 'StreamArn': (str, False), } class MicrosoftSqlServerSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } class MongoDbSettings(AWSProperty): props = { - 'AuthMechanism': (basestring, False), - 'AuthSource': (basestring, False), - 'AuthType': (basestring, False), - 'DatabaseName': (basestring, False), - 'DocsToInvestigate': (basestring, False), - 'ExtractDocId': (basestring, False), - 'NestingLevel': (basestring, False), - 'Password': (basestring, False), + 'AuthMechanism': (str, False), + 'AuthSource': (str, False), + 'AuthType': (str, False), + 'DatabaseName': (str, False), + 'DocsToInvestigate': (str, False), + 'ExtractDocId': (str, False), + 'NestingLevel': (str, False), + 'Password': (str, False), 'Port': (network_port, False), - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), - 'ServerName': (basestring, False), - 'Username': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), + 'ServerName': (str, False), + 'Username': (str, False), } class MySqlSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } @@ -104,51 +104,51 @@ class NeptuneSettings(AWSProperty): 'IamAuthEnabled': (boolean, False), 'MaxFileSize': (integer, False), 'MaxRetryCount': (integer, False), - 'S3BucketFolder': (basestring, False), - 'S3BucketName': (basestring, False), - 'ServiceAccessRoleArn': (basestring, False), + 'S3BucketFolder': (str, False), + 'S3BucketName': (str, False), + 'ServiceAccessRoleArn': (str, False), } class OracleSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerOracleAsmAccessRoleArn': (basestring, False), - 'SecretsManagerOracleAsmSecretId': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerOracleAsmAccessRoleArn': (str, False), + 'SecretsManagerOracleAsmSecretId': (str, False), + 'SecretsManagerSecretId': (str, False), } class PostgreSqlSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } class RedshiftSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } class S3Settings(AWSProperty): props = { - 'BucketFolder': (basestring, False), - 'BucketName': (basestring, False), - 'CompressionType': (basestring, False), - 'CsvDelimiter': (basestring, False), - 'CsvRowDelimiter': (basestring, False), - 'ExternalTableDefinition': (basestring, False), - 'ServiceAccessRoleArn': (basestring, False), + 'BucketFolder': (str, False), + 'BucketName': (str, False), + 'CompressionType': (str, False), + 'CsvDelimiter': (str, False), + 'CsvRowDelimiter': (str, False), + 'ExternalTableDefinition': (str, False), + 'ServiceAccessRoleArn': (str, False), } class SybaseSettings(AWSProperty): props = { - 'SecretsManagerAccessRoleArn': (basestring, False), - 'SecretsManagerSecretId': (basestring, False), + 'SecretsManagerAccessRoleArn': (str, False), + 'SecretsManagerSecretId': (str, False), } @@ -156,34 +156,34 @@ class Endpoint(AWSObject): resource_type = "AWS::DMS::Endpoint" props = { - 'CertificateArn': (basestring, False), - 'DatabaseName': (basestring, False), + 'CertificateArn': (str, False), + 'DatabaseName': (str, False), 'DocDbSettings': (DocDbSettings, False), 'DynamoDbSettings': (DynamoDbSettings, False), 'ElasticsearchSettings': (ElasticsearchSettings, False), - 'EndpointIdentifier': (basestring, False), - 'EndpointType': (basestring, True), - 'EngineName': (basestring, True), - 'ExtraConnectionAttributes': (basestring, False), + 'EndpointIdentifier': (str, False), + 'EndpointType': (str, True), + 'EngineName': (str, True), + 'ExtraConnectionAttributes': (str, False), 'IbmDb2Settings': (IbmDb2Settings, False), 'KafkaSettings': (KafkaSettings, False), 'KinesisSettings': (KinesisSettings, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'MicrosoftSqlServerSettings': (MicrosoftSqlServerSettings, False), 'MongoDbSettings': (MongoDbSettings, False), 'MySqlSettings': (MySqlSettings, False), 'NeptuneSettings': (NeptuneSettings, False), 'OracleSettings': (OracleSettings, False), - 'Password': (basestring, False), + 'Password': (str, False), 'Port': (network_port, False), 'PostgreSqlSettings': (PostgreSqlSettings, False), 'RedshiftSettings': (RedshiftSettings, False), 'S3Settings': (S3Settings, False), - 'ServerName': (basestring, False), - 'SslMode': (basestring, False), + 'ServerName': (str, False), + 'SslMode': (str, False), 'SybaseSettings': (SybaseSettings, False), 'Tags': (Tags, False), - 'Username': (basestring, False), + 'Username': (str, False), } @@ -192,11 +192,11 @@ class EventSubscription(AWSObject): props = { 'Enabled': (boolean, False), - 'EventCategories': ([basestring], False), - 'SnsTopicArn': (basestring, True), - 'SourceIds': ([basestring], False), - 'SourceType': (basestring, False), - 'SubscriptionName': (basestring, False), + 'EventCategories': ([str], False), + 'SnsTopicArn': (str, True), + 'SourceIds': ([str], False), + 'SourceType': (str, False), + 'SubscriptionName': (str, False), 'Tags': (Tags, False), } @@ -208,17 +208,17 @@ class ReplicationInstance(AWSObject): 'AllocatedStorage': (integer, False), 'AllowMajorVersionUpgrade': (boolean, False), 'AutoMinorVersionUpgrade': (boolean, False), - 'AvailabilityZone': (basestring, False), - 'EngineVersion': (basestring, False), - 'KmsKeyId': (basestring, False), + 'AvailabilityZone': (str, False), + 'EngineVersion': (str, False), + 'KmsKeyId': (str, False), 'MultiAZ': (boolean, False), - 'PreferredMaintenanceWindow': (basestring, False), + 'PreferredMaintenanceWindow': (str, False), 'PubliclyAccessible': (boolean, False), - 'ReplicationInstanceClass': (basestring, True), - 'ReplicationInstanceIdentifier': (basestring, False), - 'ReplicationSubnetGroupIdentifier': (basestring, False), + 'ReplicationInstanceClass': (str, True), + 'ReplicationInstanceIdentifier': (str, False), + 'ReplicationSubnetGroupIdentifier': (str, False), 'Tags': (Tags, False), - 'VpcSecurityGroupIds': ([basestring], False), + 'VpcSecurityGroupIds': ([str], False), } @@ -226,9 +226,9 @@ class ReplicationSubnetGroup(AWSObject): resource_type = "AWS::DMS::ReplicationSubnetGroup" props = { - 'ReplicationSubnetGroupDescription': (basestring, True), - 'ReplicationSubnetGroupIdentifier': (basestring, False), - 'SubnetIds': ([basestring], True), + 'ReplicationSubnetGroupDescription': (str, True), + 'ReplicationSubnetGroupIdentifier': (str, False), + 'SubnetIds': ([str], True), 'Tags': (Tags, False), } @@ -237,16 +237,16 @@ class ReplicationTask(AWSObject): resource_type = "AWS::DMS::ReplicationTask" props = { - 'CdcStartPosition': (basestring, False), + 'CdcStartPosition': (str, False), 'CdcStartTime': (positive_integer, False), - 'CdcStopPosition': (basestring, False), - 'MigrationType': (basestring, True), - 'ReplicationInstanceArn': (basestring, True), - 'ReplicationTaskIdentifier': (basestring, False), - 'ReplicationTaskSettings': (basestring, False), - 'SourceEndpointArn': (basestring, True), - 'TableMappings': (basestring, True), + 'CdcStopPosition': (str, False), + 'MigrationType': (str, True), + 'ReplicationInstanceArn': (str, True), + 'ReplicationTaskIdentifier': (str, False), + 'ReplicationTaskSettings': (str, False), + 'SourceEndpointArn': (str, True), + 'TableMappings': (str, True), 'Tags': (Tags, False), - 'TargetEndpointArn': (basestring, True), - 'TaskData': (basestring, False), + 'TargetEndpointArn': (str, True), + 'TaskData': (str, False), } diff --git a/troposphere/docdb.py b/troposphere/docdb.py index 007e45ab3..88b6f9f45 100644 --- a/troposphere/docdb.py +++ b/troposphere/docdb.py @@ -11,24 +11,24 @@ class DBCluster(AWSObject): resource_type = "AWS::DocDB::DBCluster" props = { - 'AvailabilityZones': ([basestring], False), + 'AvailabilityZones': ([str], False), 'BackupRetentionPeriod': (integer, False), - 'DBClusterIdentifier': (basestring, False), - 'DBClusterParameterGroupName': (basestring, False), - 'DBSubnetGroupName': (basestring, False), + 'DBClusterIdentifier': (str, False), + 'DBClusterParameterGroupName': (str, False), + 'DBSubnetGroupName': (str, False), 'DeletionProtection': (boolean, False), - 'EnableCloudwatchLogsExports': ([basestring], False), - 'EngineVersion': (basestring, False), - 'KmsKeyId': (basestring, False), - 'MasterUserPassword': (basestring, False), - 'MasterUsername': (basestring, False), + 'EnableCloudwatchLogsExports': ([str], False), + 'EngineVersion': (str, False), + 'KmsKeyId': (str, False), + 'MasterUserPassword': (str, False), + 'MasterUsername': (str, False), 'Port': (integer, False), - 'PreferredBackupWindow': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), - 'SnapshotIdentifier': (basestring, False), + 'PreferredBackupWindow': (str, False), + 'PreferredMaintenanceWindow': (str, False), + 'SnapshotIdentifier': (str, False), 'StorageEncrypted': (boolean, False), 'Tags': (Tags, False), - 'VpcSecurityGroupIds': ([basestring], False), + 'VpcSecurityGroupIds': ([str], False), } @@ -36,9 +36,9 @@ class DBClusterParameterGroup(AWSObject): resource_type = "AWS::DocDB::DBClusterParameterGroup" props = { - 'Description': (basestring, True), - 'Family': (basestring, True), - 'Name': (basestring, False), + 'Description': (str, True), + 'Family': (str, True), + 'Name': (str, False), 'Parameters': (dict, True), 'Tags': (Tags, False), } @@ -49,11 +49,11 @@ class DBInstance(AWSObject): props = { 'AutoMinorVersionUpgrade': (boolean, False), - 'AvailabilityZone': (basestring, False), - 'DBClusterIdentifier': (basestring, True), - 'DBInstanceClass': (basestring, True), - 'DBInstanceIdentifier': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), + 'AvailabilityZone': (str, False), + 'DBClusterIdentifier': (str, True), + 'DBInstanceClass': (str, True), + 'DBInstanceIdentifier': (str, False), + 'PreferredMaintenanceWindow': (str, False), 'Tags': (Tags, False), } @@ -62,8 +62,8 @@ class DBSubnetGroup(AWSObject): resource_type = "AWS::DocDB::DBSubnetGroup" props = { - 'DBSubnetGroupDescription': (basestring, True), - 'DBSubnetGroupName': (basestring, False), - 'SubnetIds': ([basestring], True), + 'DBSubnetGroupDescription': (str, True), + 'DBSubnetGroupName': (str, False), + 'SubnetIds': ([str], True), 'Tags': (Tags, False), } diff --git a/troposphere/dynamodb.py b/troposphere/dynamodb.py index 622d5df21..92357adb0 100644 --- a/troposphere/dynamodb.py +++ b/troposphere/dynamodb.py @@ -40,7 +40,7 @@ def billing_mode_validator(x): class AttributeDefinition(AWSProperty): props = { - "AttributeName": (basestring, True), + "AttributeName": (str, True), "AttributeType": (attribute_type_validator, True), } @@ -53,7 +53,7 @@ class ContributorInsightsSpecification(AWSProperty): class KeySchema(AWSProperty): props = { - "AttributeName": (basestring, True), + "AttributeName": (str, True), "KeyType": (key_type_validator, True) } @@ -72,22 +72,22 @@ class ProvisionedThroughput(AWSProperty): class Projection(AWSProperty): props = { - "NonKeyAttributes": ([basestring], False), + "NonKeyAttributes": ([str], False), "ProjectionType": (projection_type_validator, False) } class SSESpecification(AWSProperty): props = { - 'KMSMasterKeyId': (basestring, False), + 'KMSMasterKeyId': (str, False), 'SSEEnabled': (boolean, True), - 'SSEType': (basestring, False), + 'SSEType': (str, False), } class GlobalSecondaryIndex(AWSProperty): props = { - "IndexName": (basestring, True), + "IndexName": (str, True), "KeySchema": ([KeySchema], True), "Projection": (Projection, True), "ProvisionedThroughput": (ProvisionedThroughput, False) @@ -96,7 +96,7 @@ class GlobalSecondaryIndex(AWSProperty): class LocalSecondaryIndex(AWSProperty): props = { - "IndexName": (basestring, True), + "IndexName": (str, True), "KeySchema": ([KeySchema], True), "Projection": (Projection, True), } @@ -110,13 +110,13 @@ class PointInTimeRecoverySpecification(AWSProperty): class StreamSpecification(AWSProperty): props = { - 'StreamViewType': (basestring, True), + 'StreamViewType': (str, True), } class TimeToLiveSpecification(AWSProperty): props = { - 'AttributeName': (basestring, True), + 'AttributeName': (str, True), 'Enabled': (boolean, True), } @@ -137,7 +137,7 @@ class Table(AWSObject): 'ProvisionedThroughput': (ProvisionedThroughput, False), 'SSESpecification': (SSESpecification, False), 'StreamSpecification': (StreamSpecification, False), - 'TableName': (basestring, False), + 'TableName': (str, False), 'Tags': (Tags, False), 'TimeToLiveSpecification': (TimeToLiveSpecification, False), } diff --git a/troposphere/ec2.py b/troposphere/ec2.py index d714e0310..3ba6571d1 100644 --- a/troposphere/ec2.py +++ b/troposphere/ec2.py @@ -49,8 +49,8 @@ def validate_clientvpnendpoint_vpnport(vpnport): class Tag(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True) + 'Key': (str, True), + 'Value': (str, True) } def __init__(self, key=None, value=None, **kwargs): @@ -67,7 +67,7 @@ class CarrierGateway(AWSObject): props = { 'Tags': (Tags, False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } @@ -76,9 +76,9 @@ class CustomerGateway(AWSObject): props = { 'BgpAsn': (integer, True), - 'IpAddress': (basestring, True), + 'IpAddress': (str, True), 'Tags': ((Tags, list), False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -86,7 +86,7 @@ class DHCPOptions(AWSObject): resource_type = "AWS::EC2::DHCPOptions" props = { - 'DomainName': (basestring, False), + 'DomainName': (str, False), 'DomainNameServers': (list, False), 'NetbiosNameServers': (list, False), 'NetbiosNodeType': (integer, False), @@ -99,7 +99,7 @@ class EgressOnlyInternetGateway(AWSObject): resource_type = "AWS::EC2::EgressOnlyInternetGateway" props = { - 'VpcId': (basestring, True), + 'VpcId': (str, True), } @@ -107,9 +107,9 @@ class EIP(AWSObject): resource_type = "AWS::EC2::EIP" props = { - 'InstanceId': (basestring, False), - 'Domain': (basestring, False), - 'PublicIpv4Pool': (basestring, False), + 'InstanceId': (str, False), + 'Domain': (str, False), + 'PublicIpv4Pool': (str, False), 'Tags': (Tags, False), } @@ -118,11 +118,11 @@ class EIPAssociation(AWSObject): resource_type = "AWS::EC2::EIPAssociation" props = { - 'AllocationId': (basestring, False), - 'EIP': (basestring, False), - 'InstanceId': (basestring, False), - 'NetworkInterfaceId': (basestring, False), - 'PrivateIpAddress': (basestring, False), + 'AllocationId': (str, False), + 'EIP': (str, False), + 'InstanceId': (str, False), + 'NetworkInterfaceId': (str, False), + 'PrivateIpAddress': (str, False), } @@ -130,16 +130,16 @@ class FlowLog(AWSObject): resource_type = "AWS::EC2::FlowLog" props = { - 'DeliverLogsPermissionArn': (basestring, False), - 'LogDestination': (basestring, False), - 'LogDestinationType': (basestring, False), - 'LogFormat': (basestring, False), - 'LogGroupName': (basestring, False), + 'DeliverLogsPermissionArn': (str, False), + 'LogDestination': (str, False), + 'LogDestinationType': (str, False), + 'LogFormat': (str, False), + 'LogGroupName': (str, False), 'MaxAggregationInterval': (integer, False), - 'ResourceId': (basestring, True), - 'ResourceType': (basestring, True), + 'ResourceId': (str, True), + 'ResourceType': (str, True), 'Tags': (Tags, False), - 'TrafficType': (basestring, True), + 'TrafficType': (str, True), } @@ -147,8 +147,8 @@ class NatGateway(AWSObject): resource_type = "AWS::EC2::NatGateway" props = { - 'AllocationId': (basestring, True), - 'SubnetId': (basestring, True), + 'AllocationId': (str, True), + 'SubnetId': (str, True), 'Tags': ((Tags, list), False), } @@ -157,12 +157,12 @@ class EBSBlockDevice(AWSProperty): props = { 'DeleteOnTermination': (boolean, False), 'Encrypted': (boolean, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'Iops': (integer, False), # Conditional 'Throughput': (integer, False), # Conditional - 'SnapshotId': (basestring, False), # Conditional + 'SnapshotId': (str, False), # Conditional 'VolumeSize': (integer, False), # Conditional - 'VolumeType': (basestring, False), + 'VolumeType': (str, False), } @@ -171,38 +171,38 @@ class EBSBlockDevice(AWSProperty): class BlockDeviceMapping(AWSProperty): props = { - 'DeviceName': (basestring, True), + 'DeviceName': (str, True), 'Ebs': (EBSBlockDevice, False), # Conditional - 'VirtualName': (basestring, False), # Conditional + 'VirtualName': (str, False), # Conditional 'NoDevice': (dict, False) } class LaunchTemplateBlockDeviceMapping(AWSProperty): props = { - 'DeviceName': (basestring, True), + 'DeviceName': (str, True), 'Ebs': (EBSBlockDevice, False), # Conditional - 'VirtualName': (basestring, False), # Conditional - 'NoDevice': (basestring, False) + 'VirtualName': (str, False), # Conditional + 'NoDevice': (str, False) } class MountPoint(AWSProperty): props = { - 'Device': (basestring, True), - 'VolumeId': (basestring, True), + 'Device': (str, True), + 'VolumeId': (str, True), } class Placement(AWSProperty): props = { - 'Affinity': (basestring, False), - 'AvailabilityZone': (basestring, False), - 'GroupName': (basestring, False), - 'HostId': (basestring, False), - 'HostResourceGroupArn': (basestring, False), + 'Affinity': (str, False), + 'AvailabilityZone': (str, False), + 'GroupName': (str, False), + 'HostId': (str, False), + 'HostResourceGroupArn': (str, False), 'PartitionNumber': (integer, False), - 'Tenancy': (basestring, False) + 'Tenancy': (str, False) } @@ -215,13 +215,13 @@ class CpuOptions(AWSProperty): class CreditSpecification(AWSProperty): props = { - 'CPUCredits': (basestring, False), + 'CPUCredits': (str, False), } class ElasticGpuSpecification(AWSProperty): props = { - 'Type': (basestring, True), + 'Type': (str, True), } @@ -234,9 +234,9 @@ def __init__(self, address): class LaunchTemplateSpecification(AWSProperty): props = { - 'LaunchTemplateId': (basestring, False), - 'LaunchTemplateName': (basestring, False), - 'Version': (basestring, True), + 'LaunchTemplateId': (str, False), + 'LaunchTemplateName': (str, False), + 'Version': (str, True), } @@ -244,8 +244,8 @@ class NetworkInsightsAnalysis(AWSObject): resource_type = "AWS::EC2::NetworkInsightsAnalysis" props = { - 'FilterInArns': ([basestring], False), - 'NetworkInsightsPathId': (basestring, True), + 'FilterInArns': ([str], False), + 'NetworkInsightsPathId': (str, True), 'Tags': (Tags, False), } @@ -254,12 +254,12 @@ class NetworkInsightsPath(AWSObject): resource_type = "AWS::EC2::NetworkInsightsPath" props = { - 'Destination': (basestring, True), - 'DestinationIp': (basestring, False), + 'Destination': (str, True), + 'DestinationIp': (str, False), 'DestinationPort': (integer, False), - 'Protocol': (basestring, True), - 'Source': (basestring, True), - 'SourceIp': (basestring, False), + 'Protocol': (str, True), + 'Source': (str, True), + 'SourceIp': (str, False), 'Tags': (Tags, False), } @@ -267,7 +267,7 @@ class NetworkInsightsPath(AWSObject): class PrivateIpAddressSpecification(AWSProperty): props = { 'Primary': (boolean, True), - 'PrivateIpAddress': (basestring, True), + 'PrivateIpAddress': (str, True), } @@ -276,31 +276,31 @@ class NetworkInterfaceProperty(AWSProperty): 'AssociateCarrierIpAddress': (boolean, False), 'AssociatePublicIpAddress': (boolean, False), 'DeleteOnTermination': (boolean, False), - 'Description': (basestring, False), + 'Description': (str, False), 'DeviceIndex': (integer, True), - 'GroupSet': ([basestring], False), + 'GroupSet': ([str], False), 'Ipv6AddressCount': (integer, False), 'Ipv6Addresses': ([Ipv6Addresses], False), 'NetworkCardIndex': (integer, False), - 'NetworkInterfaceId': (basestring, False), - 'PrivateIpAddress': (basestring, False), + 'NetworkInterfaceId': (str, False), + 'PrivateIpAddress': (str, False), 'PrivateIpAddresses': ([PrivateIpAddressSpecification], False), 'SecondaryPrivateIpAddressCount': (integer, False), - 'SubnetId': (basestring, False), + 'SubnetId': (str, False), } class AssociationParameters(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': ([basestring], True), + 'Key': (str, True), + 'Value': ([str], True), } class SsmAssociations(AWSProperty): props = { 'AssociationParameters': ([AssociationParameters], False), - 'DocumentName': (basestring, True), + 'DocumentName': (str, True), } @@ -308,8 +308,8 @@ class GatewayRouteTableAssociation(AWSObject): resource_type = "AWS::EC2::GatewayRouteTableAssociation" props = { - 'GatewayId': (basestring, True), - 'RouteTableId': (basestring, True), + 'GatewayId': (str, True), + 'RouteTableId': (str, True), } @@ -317,10 +317,10 @@ class Host(AWSObject): resource_type = "AWS::EC2::Host" props = { - 'AutoPlacement': (basestring, False), - 'AvailabilityZone': (basestring, True), - 'HostRecovery': (basestring, False), - 'InstanceType': (basestring, True), + 'AutoPlacement': (str, False), + 'AvailabilityZone': (str, True), + 'HostRecovery': (str, False), + 'InstanceType': (str, True), } @@ -333,7 +333,7 @@ class ElasticInferenceAccelerator(AWSProperty): class LicenseSpecification(AWSProperty): props = { - 'LicenseConfigurationArn': (basestring, True), + 'LicenseConfigurationArn': (str, True), } @@ -353,8 +353,8 @@ class Instance(AWSObject): resource_type = "AWS::EC2::Instance" props = { - 'Affinity': (basestring, False), - 'AvailabilityZone': (basestring, False), + 'Affinity': (str, False), + 'AvailabilityZone': (str, False), 'BlockDeviceMappings': (list, False), 'CpuOptions': (CpuOptions, False), 'CreditSpecification': (CreditSpecification, False), @@ -364,31 +364,31 @@ class Instance(AWSObject): 'ElasticInferenceAccelerators': ([ElasticInferenceAccelerator], False), 'EnclaveOptions': (EnclaveOptions, False), 'HibernationOptions': (HibernationOptions, False), - 'HostId': (basestring, False), - 'HostResourceGroupArn': (basestring, False), - 'IamInstanceProfile': (basestring, False), - 'ImageId': (basestring, False), - 'InstanceInitiatedShutdownBehavior': (basestring, False), - 'InstanceType': (basestring, False), + 'HostId': (str, False), + 'HostResourceGroupArn': (str, False), + 'IamInstanceProfile': (str, False), + 'ImageId': (str, False), + 'InstanceInitiatedShutdownBehavior': (str, False), + 'InstanceType': (str, False), 'Ipv6AddressCount': (integer, False), 'Ipv6Addresses': ([Ipv6Addresses], False), - 'KernelId': (basestring, False), - 'KeyName': (basestring, False), + 'KernelId': (str, False), + 'KeyName': (str, False), 'LaunchTemplate': (LaunchTemplateSpecification, False), 'LicenseSpecifications': ([LicenseSpecification], False), 'Monitoring': (boolean, False), 'NetworkInterfaces': ([NetworkInterfaceProperty], False), - 'PlacementGroupName': (basestring, False), - 'PrivateIpAddress': (basestring, False), - 'RamdiskId': (basestring, False), + 'PlacementGroupName': (str, False), + 'PrivateIpAddress': (str, False), + 'RamdiskId': (str, False), 'SecurityGroupIds': (list, False), 'SecurityGroups': (list, False), 'SsmAssociations': ([SsmAssociations], False), 'SourceDestCheck': (boolean, False), - 'SubnetId': (basestring, False), + 'SubnetId': (str, False), 'Tags': ((Tags, list), False), - 'Tenancy': (basestring, False), - 'UserData': (basestring, False), + 'Tenancy': (str, False), + 'UserData': (str, False), 'Volumes': (list, False), } @@ -406,7 +406,7 @@ class NetworkAcl(AWSObject): props = { 'Tags': ((Tags, list), False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } @@ -428,14 +428,14 @@ class NetworkAclEntry(AWSObject): resource_type = "AWS::EC2::NetworkAclEntry" props = { - 'CidrBlock': (basestring, False), + 'CidrBlock': (str, False), 'Egress': (boolean, False), 'Icmp': (ICMP, False), # Conditional - 'Ipv6CidrBlock': (basestring, False), - 'NetworkAclId': (basestring, True), + 'Ipv6CidrBlock': (str, False), + 'NetworkAclId': (str, True), 'PortRange': (PortRange, False), # Conditional 'Protocol': (network_port, True), - 'RuleAction': (basestring, True), + 'RuleAction': (str, True), 'RuleNumber': (integer_range(1, 32766), True), } @@ -451,15 +451,15 @@ class NetworkInterface(AWSObject): resource_type = "AWS::EC2::NetworkInterface" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'GroupSet': (list, False), 'Ipv6AddressCount': (integer, False), 'Ipv6Addresses': ([Ipv6Addresses], False), - 'PrivateIpAddress': (basestring, False), + 'PrivateIpAddress': (str, False), 'PrivateIpAddresses': ([PrivateIpAddressSpecification], False), 'SecondaryPrivateIpAddressCount': (integer, False), 'SourceDestCheck': (boolean, False), - 'SubnetId': (basestring, True), + 'SubnetId': (str, True), 'Tags': ((Tags, list), False), } @@ -470,8 +470,8 @@ class NetworkInterfaceAttachment(AWSObject): props = { 'DeleteOnTermination': (boolean, False), 'DeviceIndex': (integer, True), - 'InstanceId': (basestring, True), - 'NetworkInterfaceId': (basestring, True), + 'InstanceId': (str, True), + 'NetworkInterfaceId': (str, True), } @@ -483,16 +483,16 @@ class NetworkInterfacePermission(AWSObject): resource_type = "AWS::EC2::NetworkInterfacePermission" props = { - 'AwsAccountId': (basestring, True), - 'NetworkInterfaceId': (basestring, True), - 'Permission': (basestring, True), + 'AwsAccountId': (str, True), + 'NetworkInterfaceId': (str, True), + 'Permission': (str, True), } class Entry(AWSProperty): props = { - 'Cidr': (basestring, True), - 'Description': (basestring, False), + 'Cidr': (str, True), + 'Description': (str, False), } @@ -500,10 +500,10 @@ class PrefixList(AWSObject): resource_type = "AWS::EC2::PrefixList" props = { - 'AddressFamily': (basestring, True), + 'AddressFamily': (str, True), 'Entries': ([Entry], False), 'MaxEntries': (integer, True), - 'PrefixListName': (basestring, True), + 'PrefixListName': (str, True), 'Tags': (Tags, False), } @@ -512,19 +512,19 @@ class Route(AWSObject): resource_type = "AWS::EC2::Route" props = { - 'CarrierGatewayId': (basestring, False), - 'DestinationCidrBlock': (basestring, False), - 'DestinationIpv6CidrBlock': (basestring, False), - 'EgressOnlyInternetGatewayId': (basestring, False), - 'GatewayId': (basestring, False), - 'InstanceId': (basestring, False), - 'LocalGatewayId': (basestring, False), - 'NatGatewayId': (basestring, False), - 'NetworkInterfaceId': (basestring, False), - 'RouteTableId': (basestring, True), - 'TransitGatewayId': (basestring, False), - 'VpcEndpointId': (basestring, False), - 'VpcPeeringConnectionId': (basestring, False), + 'CarrierGatewayId': (str, False), + 'DestinationCidrBlock': (str, False), + 'DestinationIpv6CidrBlock': (str, False), + 'EgressOnlyInternetGatewayId': (str, False), + 'GatewayId': (str, False), + 'InstanceId': (str, False), + 'LocalGatewayId': (str, False), + 'NatGatewayId': (str, False), + 'NetworkInterfaceId': (str, False), + 'RouteTableId': (str, True), + 'TransitGatewayId': (str, False), + 'VpcEndpointId': (str, False), + 'VpcPeeringConnectionId': (str, False), } def validate(self): @@ -553,7 +553,7 @@ class RouteTable(AWSObject): props = { 'Tags': ((Tags, list), False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } @@ -576,14 +576,14 @@ class SecurityGroupEgress(AWSObject): resource_type = "AWS::EC2::SecurityGroupEgress" props = { - 'CidrIp': (basestring, False), - 'CidrIpv6': (basestring, False), - 'Description': (basestring, False), - 'DestinationPrefixListId': (basestring, False), - 'DestinationSecurityGroupId': (basestring, False), + 'CidrIp': (str, False), + 'CidrIpv6': (str, False), + 'Description': (str, False), + 'DestinationPrefixListId': (str, False), + 'DestinationSecurityGroupId': (str, False), 'FromPort': (network_port, False), - 'GroupId': (basestring, True), - 'IpProtocol': (basestring, True), + 'GroupId': (str, True), + 'IpProtocol': (str, True), 'ToPort': (network_port, False), # # Workaround for a bug in CloudFormation and EC2 where the @@ -592,7 +592,7 @@ class SecurityGroupEgress(AWSObject): # Using SourceSecurityGroupId instead works fine even in # egress rules. AWS have known about this bug for a while. # - 'SourceSecurityGroupId': (basestring, False), + 'SourceSecurityGroupId': (str, False), } def validate(self): @@ -610,17 +610,17 @@ class SecurityGroupIngress(AWSObject): resource_type = "AWS::EC2::SecurityGroupIngress" props = { - 'CidrIp': (basestring, False), - 'CidrIpv6': (basestring, False), - 'Description': (basestring, False), + 'CidrIp': (str, False), + 'CidrIpv6': (str, False), + 'Description': (str, False), 'FromPort': (network_port, False), - 'GroupName': (basestring, False), - 'GroupId': (basestring, False), - 'IpProtocol': (basestring, True), - 'SourcePrefixListId': (basestring, False), - 'SourceSecurityGroupName': (basestring, False), - 'SourceSecurityGroupId': (basestring, False), - 'SourceSecurityGroupOwnerId': (basestring, False), + 'GroupName': (str, False), + 'GroupId': (str, False), + 'IpProtocol': (str, True), + 'SourcePrefixListId': (str, False), + 'SourceSecurityGroupName': (str, False), + 'SourceSecurityGroupId': (str, False), + 'SourceSecurityGroupOwnerId': (str, False), 'ToPort': (network_port, False), } @@ -638,17 +638,17 @@ def validate(self): class SecurityGroupRule(AWSProperty): props = { - 'CidrIp': (basestring, False), - 'CidrIpv6': (basestring, False), - 'Description': (basestring, False), - 'DestinationPrefixListId': (basestring, False), - 'DestinationSecurityGroupId': (basestring, False), + 'CidrIp': (str, False), + 'CidrIpv6': (str, False), + 'Description': (str, False), + 'DestinationPrefixListId': (str, False), + 'DestinationSecurityGroupId': (str, False), 'FromPort': (network_port, False), - 'IpProtocol': (basestring, True), - 'SourcePrefixListId': (basestring, False), - 'SourceSecurityGroupId': (basestring, False), - 'SourceSecurityGroupName': (basestring, False), - 'SourceSecurityGroupOwnerId': (basestring, False), + 'IpProtocol': (str, True), + 'SourcePrefixListId': (str, False), + 'SourceSecurityGroupId': (str, False), + 'SourceSecurityGroupName': (str, False), + 'SourceSecurityGroupOwnerId': (str, False), 'ToPort': (network_port, False), } @@ -657,11 +657,11 @@ class SecurityGroup(AWSObject): resource_type = "AWS::EC2::SecurityGroup" props = { - 'GroupName': (basestring, False), - 'GroupDescription': (basestring, True), + 'GroupName': (str, False), + 'GroupDescription': (str, True), 'SecurityGroupEgress': (list, False), 'SecurityGroupIngress': (list, False), - 'VpcId': (basestring, False), + 'VpcId': (str, False), 'Tags': ((Tags, list), False), } @@ -671,13 +671,13 @@ class Subnet(AWSObject): props = { 'AssignIpv6AddressOnCreation': (boolean, False), - 'AvailabilityZone': (basestring, False), - 'CidrBlock': (basestring, True), - 'Ipv6CidrBlock': (basestring, False), + 'AvailabilityZone': (str, False), + 'CidrBlock': (str, True), + 'Ipv6CidrBlock': (str, False), 'MapPublicIpOnLaunch': (boolean, False), - 'OutpostArn': (basestring, False), + 'OutpostArn': (str, False), 'Tags': ((Tags, list), False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } def validate(self): @@ -693,8 +693,8 @@ class SubnetNetworkAclAssociation(AWSObject): resource_type = "AWS::EC2::SubnetNetworkAclAssociation" props = { - 'SubnetId': (basestring, True), - 'NetworkAclId': (basestring, True), + 'SubnetId': (str, True), + 'NetworkAclId': (str, True), } @@ -702,8 +702,8 @@ class SubnetRouteTableAssociation(AWSObject): resource_type = "AWS::EC2::SubnetRouteTableAssociation" props = { - 'RouteTableId': (basestring, True), - 'SubnetId': (basestring, True), + 'RouteTableId': (str, True), + 'SubnetId': (str, True), } @@ -712,16 +712,16 @@ class Volume(AWSObject): props = { 'AutoEnableIO': (boolean, False), - 'AvailabilityZone': (basestring, True), + 'AvailabilityZone': (str, True), 'Encrypted': (boolean, False), 'Iops': (positive_integer, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'MultiAttachEnabled': (boolean, False), - 'OutpostArn': (basestring, False), + 'OutpostArn': (str, False), 'Size': (positive_integer, False), - 'SnapshotId': (basestring, False), + 'SnapshotId': (str, False), 'Tags': ((Tags, list), False), - 'VolumeType': (basestring, False), + 'VolumeType': (str, False), } @@ -729,9 +729,9 @@ class VolumeAttachment(AWSObject): resource_type = "AWS::EC2::VolumeAttachment" props = { - 'Device': (basestring, True), - 'InstanceId': (basestring, True), - 'VolumeId': (basestring, True), + 'Device': (str, True), + 'InstanceId': (str, True), + 'VolumeId': (str, True), } @@ -746,7 +746,7 @@ class VPC(AWSObject): resource_type = "AWS::EC2::VPC" props = { - 'CidrBlock': (basestring, True), + 'CidrBlock': (str, True), 'EnableDnsSupport': (boolean, False), 'EnableDnsHostnames': (boolean, False), 'InstanceTenancy': (instance_tenancy, False), @@ -758,8 +758,8 @@ class VPCDHCPOptionsAssociation(AWSObject): resource_type = "AWS::EC2::VPCDHCPOptionsAssociation" props = { - 'DhcpOptionsId': (basestring, True), - 'VpcId': (basestring, True), + 'DhcpOptionsId': (str, True), + 'VpcId': (str, True), } @@ -769,12 +769,12 @@ class VPCEndpoint(AWSObject): props = { 'PolicyDocument': (policytypes, False), 'PrivateDnsEnabled': (boolean, False), - 'RouteTableIds': ([basestring], False), - 'SecurityGroupIds': ([basestring], False), - 'ServiceName': (basestring, True), - 'SubnetIds': ([basestring], False), + 'RouteTableIds': ([str], False), + 'SecurityGroupIds': ([str], False), + 'ServiceName': (str, True), + 'SubnetIds': ([str], False), 'VpcEndpointType': (vpc_endpoint_type, False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } @@ -782,10 +782,10 @@ class VPCEndpointConnectionNotification(AWSObject): resource_type = "AWS::EC2::VPCEndpointConnectionNotification" props = { - 'ConnectionEvents': ([basestring], True), - 'ConnectionNotificationArn': (basestring, True), - 'ServiceId': (basestring, False), - 'VPCEndpointId': (basestring, False), + 'ConnectionEvents': ([str], True), + 'ConnectionNotificationArn': (str, True), + 'ServiceId': (str, False), + 'VPCEndpointId': (str, False), } @@ -794,8 +794,8 @@ class VPCEndpointService(AWSObject): props = { 'AcceptanceRequired': (boolean, False), - 'GatewayLoadBalancerArns': ([basestring], False), - 'NetworkLoadBalancerArns': ([basestring], False), + 'GatewayLoadBalancerArns': ([str], False), + 'NetworkLoadBalancerArns': ([str], False), } @@ -803,8 +803,8 @@ class VPCEndpointServicePermissions(AWSObject): resource_type = "AWS::EC2::VPCEndpointServicePermissions" props = { - 'AllowedPrincipals': ([basestring], False), - 'ServiceId': (basestring, True), + 'AllowedPrincipals': ([str], False), + 'ServiceId': (str, True), } @@ -812,9 +812,9 @@ class VPCGatewayAttachment(AWSObject): resource_type = "AWS::EC2::VPCGatewayAttachment" props = { - 'InternetGatewayId': (basestring, False), - 'VpcId': (basestring, True), - 'VpnGatewayId': (basestring, False), + 'InternetGatewayId': (str, False), + 'VpcId': (str, True), + 'VpnGatewayId': (str, False), } @@ -829,12 +829,12 @@ class VPNConnection(AWSObject): resource_type = "AWS::EC2::VPNConnection" props = { - 'CustomerGatewayId': (basestring, True), + 'CustomerGatewayId': (str, True), 'StaticRoutesOnly': (boolean, False), 'Tags': ((Tags, list), False), - 'TransitGatewayId': (basestring, False), - 'Type': (basestring, True), - 'VpnGatewayId': (basestring, False), + 'TransitGatewayId': (str, False), + 'Type': (str, True), + 'VpnGatewayId': (str, False), 'VpnTunnelOptionsSpecifications': ([VpnTunnelOptionsSpecification], False), } @@ -851,8 +851,8 @@ class VPNConnectionRoute(AWSObject): resource_type = "AWS::EC2::VPNConnectionRoute" props = { - 'DestinationCidrBlock': (basestring, True), - 'VpnConnectionId': (basestring, True), + 'DestinationCidrBlock': (str, True), + 'VpnConnectionId': (str, True), } @@ -861,7 +861,7 @@ class VPNGateway(AWSObject): props = { 'AmazonSideAsn': (positive_integer, False), - 'Type': (basestring, True), + 'Type': (str, True), 'Tags': ((Tags, list), False), } @@ -870,8 +870,8 @@ class VPNGatewayRoutePropagation(AWSObject): resource_type = "AWS::EC2::VPNGatewayRoutePropagation" props = { - 'RouteTableIds': ([basestring], True), - 'VpnGatewayId': (basestring, True), + 'RouteTableIds': ([str], True), + 'VpnGatewayId': (str, True), } @@ -879,12 +879,12 @@ class VPCPeeringConnection(AWSObject): resource_type = "AWS::EC2::VPCPeeringConnection" props = { - 'PeerVpcId': (basestring, True), - 'VpcId': (basestring, True), + 'PeerVpcId': (str, True), + 'VpcId': (str, True), 'Tags': ((Tags, list), False), - 'PeerRegion': (basestring, False), - 'PeerOwnerId': (basestring, False), - 'PeerRoleArn': (basestring, False), + 'PeerRegion': (str, False), + 'PeerOwnerId': (str, False), + 'PeerRoleArn': (str, False), } @@ -898,34 +898,34 @@ class NetworkInterfaces(AWSProperty): props = { 'AssociatePublicIpAddress': (boolean, False), 'DeleteOnTermination': (boolean, False), - 'Description': (basestring, False), + 'Description': (str, False), 'DeviceIndex': (integer, True), - 'Groups': ([basestring], False), - 'InterfaceType': (basestring, False), + 'Groups': ([str], False), + 'InterfaceType': (str, False), 'Ipv6AddressCount': (integer, False), 'Ipv6Addresses': ([Ipv6Addresses], False), - 'NetworkInterfaceId': (basestring, False), + 'NetworkInterfaceId': (str, False), 'PrivateIpAddresses': ([PrivateIpAddressSpecification], False), 'SecondaryPrivateIpAddressCount': (integer, False), - 'SubnetId': (basestring, False), + 'SubnetId': (str, False), } class SecurityGroups(AWSProperty): props = { - 'GroupId': (basestring, False), + 'GroupId': (str, False), } class IamInstanceProfile(AWSProperty): props = { - 'Arn': (basestring, False), + 'Arn': (str, False), } class SpotFleetTagSpecification(AWSProperty): props = { - 'ResourceType': (basestring, True), + 'ResourceType': (str, True), 'Tags': ((Tags, list), False), } @@ -935,29 +935,29 @@ class LaunchSpecifications(AWSProperty): 'BlockDeviceMappings': ([BlockDeviceMapping], False), 'EbsOptimized': (boolean, False), 'IamInstanceProfile': (IamInstanceProfile, False), - 'ImageId': (basestring, True), - 'InstanceType': (basestring, True), - 'KernelId': (basestring, False), - 'KeyName': (basestring, False), + 'ImageId': (str, True), + 'InstanceType': (str, True), + 'KernelId': (str, False), + 'KeyName': (str, False), 'Monitoring': (Monitoring, False), 'NetworkInterfaces': ([NetworkInterfaces], False), 'Placement': (Placement, False), - 'RamdiskId': (basestring, False), + 'RamdiskId': (str, False), 'SecurityGroups': ([SecurityGroups], False), - 'SpotPrice': (basestring, False), - 'SubnetId': (basestring, False), + 'SpotPrice': (str, False), + 'SubnetId': (str, False), 'TagSpecifications': ([SpotFleetTagSpecification], False), - 'UserData': (basestring, False), + 'UserData': (str, False), 'WeightedCapacity': (positive_integer, False), } class LaunchTemplateOverrides(AWSProperty): props = { - 'AvailabilityZone': (basestring, False), - 'InstanceType': (basestring, False), - 'SpotPrice': (basestring, False), - 'SubnetId': (basestring, False), + 'AvailabilityZone': (str, False), + 'InstanceType': (str, False), + 'SpotPrice': (str, False), + 'SubnetId': (str, False), 'WeightedCapacity': (double, False) } @@ -971,7 +971,7 @@ class LaunchTemplateConfigs(AWSProperty): class ClassicLoadBalancer(AWSProperty): props = { - 'Name': (basestring, True) + 'Name': (str, True) } @@ -983,7 +983,7 @@ class ClassicLoadBalancersConfig(AWSProperty): class TargetGroup(AWSProperty): props = { - 'Arn': (basestring, True) + 'Arn': (str, True) } @@ -1002,7 +1002,7 @@ class LoadBalancersConfig(AWSProperty): class SpotCapacityRebalance(AWSProperty): props = { - 'ReplacementStrategy': (basestring, False), + 'ReplacementStrategy': (str, False), } @@ -1015,26 +1015,26 @@ class SpotMaintenanceStrategies(AWSProperty): class SpotFleetRequestConfigData(AWSProperty): props = { - 'AllocationStrategy': (basestring, False), - 'ExcessCapacityTerminationPolicy': (basestring, False), - 'IamFleetRole': (basestring, True), - 'InstanceInterruptionBehavior': (basestring, False), + 'AllocationStrategy': (str, False), + 'ExcessCapacityTerminationPolicy': (str, False), + 'IamFleetRole': (str, True), + 'InstanceInterruptionBehavior': (str, False), 'InstancePoolsToUseCount': (integer, False), 'LaunchSpecifications': ([LaunchSpecifications], False), 'LaunchTemplateConfigs': ([LaunchTemplateConfigs], False), 'LoadBalancersConfig': (LoadBalancersConfig, False), - 'OnDemandAllocationStrategy': (basestring, False), - 'OnDemandMaxTotalPrice': (basestring, False), + 'OnDemandAllocationStrategy': (str, False), + 'OnDemandMaxTotalPrice': (str, False), 'OnDemandTargetCapacity': (integer, False), 'ReplaceUnhealthyInstances': (boolean, False), 'SpotMaintenanceStrategies': (SpotMaintenanceStrategies, False), - 'SpotMaxTotalPrice': (basestring, False), - 'SpotPrice': (basestring, False), + 'SpotMaxTotalPrice': (str, False), + 'SpotPrice': (str, False), 'TargetCapacity': (positive_integer, True), 'TerminateInstancesWithExpiration': (boolean, False), - 'Type': (basestring, False), - 'ValidFrom': (basestring, False), - 'ValidUntil': (basestring, False), + 'Type': (str, False), + 'ValidFrom': (str, False), + 'ValidUntil': (str, False), } def validate(self): @@ -1057,7 +1057,7 @@ class PlacementGroup(AWSObject): resource_type = "AWS::EC2::PlacementGroup" props = { - 'Strategy': (basestring, False), + 'Strategy': (str, False), } @@ -1065,8 +1065,8 @@ class SubnetCidrBlock(AWSObject): resource_type = "AWS::EC2::SubnetCidrBlock" props = { - 'Ipv6CidrBlock': (basestring, True), - 'SubnetId': (basestring, True), + 'Ipv6CidrBlock': (str, True), + 'SubnetId': (str, True), } @@ -1075,27 +1075,27 @@ class VPCCidrBlock(AWSObject): props = { 'AmazonProvidedIpv6CidrBlock': (boolean, False), - 'CidrBlock': (basestring, False), - 'VpcId': (basestring, True), + 'CidrBlock': (str, False), + 'VpcId': (str, True), } class TagSpecifications(AWSProperty): props = { - 'ResourceType': (basestring, False), + 'ResourceType': (str, False), 'Tags': ((Tags, list), False) } class CapacityReservationTarget(AWSProperty): props = { - 'CapacityReservationId': (basestring, False), + 'CapacityReservationId': (str, False), } class CapacityReservationSpecification(AWSProperty): props = { - 'CapacityReservationPreference': (basestring, False), + 'CapacityReservationPreference': (str, False), 'CapacityReservationTarget': (CapacityReservationTarget, False), } @@ -1103,31 +1103,31 @@ class CapacityReservationSpecification(AWSProperty): class SpotOptions(AWSProperty): props = { 'BlockDurationMinutes': (integer, False), - 'InstanceInterruptionBehavior': (basestring, False), - 'MaxPrice': (basestring, False), - 'SpotInstanceType': (basestring, False), - 'ValidUntil': (basestring, False), + 'InstanceInterruptionBehavior': (str, False), + 'MaxPrice': (str, False), + 'SpotInstanceType': (str, False), + 'ValidUntil': (str, False), } class InstanceMarketOptions(AWSProperty): props = { - 'MarketType': (basestring, False), + 'MarketType': (str, False), 'SpotOptions': (SpotOptions, False) } class LaunchTemplateCreditSpecification(AWSProperty): props = { - 'CpuCredits': (basestring, False), + 'CpuCredits': (str, False), } class MetadataOptions(AWSProperty): props = { - 'HttpEndpoint': (basestring, False), + 'HttpEndpoint': (str, False), 'HttpPutResponseHopLimit': (integer, False), - 'HttpTokens': (basestring, False), + 'HttpTokens': (str, False), } @@ -1152,22 +1152,22 @@ class LaunchTemplateData(AWSProperty): 'EnclaveOptions': (EnclaveOptions, False), 'HibernationOptions': (HibernationOptions, False), 'IamInstanceProfile': (IamInstanceProfile, False), - 'ImageId': (basestring, False), - 'InstanceInitiatedShutdownBehavior': (basestring, False), + 'ImageId': (str, False), + 'InstanceInitiatedShutdownBehavior': (str, False), 'InstanceMarketOptions': (InstanceMarketOptions, False), - 'InstanceType': (basestring, False), - 'KernelId': (basestring, False), - 'KeyName': (basestring, False), + 'InstanceType': (str, False), + 'KernelId': (str, False), + 'KeyName': (str, False), 'LicenseSpecifications': ([LicenseSpecification], False), 'MetadataOptions': (MetadataOptions, False), 'Monitoring': (Monitoring, False), 'NetworkInterfaces': ([NetworkInterfaces], False), 'Placement': (Placement, False), - 'RamDiskId': (basestring, False), + 'RamDiskId': (str, False), 'SecurityGroups': (list, False), 'SecurityGroupIds': (list, False), 'TagSpecifications': ([TagSpecifications], False), - 'UserData': (basestring, False) + 'UserData': (str, False) } @@ -1175,7 +1175,7 @@ class LaunchTemplate(AWSObject): resource_type = "AWS::EC2::LaunchTemplate" props = { 'LaunchTemplateData': (LaunchTemplateData, False), - 'LaunchTemplateName': (basestring, False), + 'LaunchTemplateName': (str, False), 'TagSpecifications': ([TagSpecifications], False), } @@ -1184,8 +1184,8 @@ class TrafficMirrorFilter(AWSObject): resource_type = "AWS::EC2::TrafficMirrorFilter" props = { - 'Description': (basestring, False), - 'NetworkServices': ([basestring], False), + 'Description': (str, False), + 'NetworkServices': ([str], False), 'Tags': (Tags, False), } @@ -1201,16 +1201,16 @@ class TrafficMirrorFilterRule(AWSObject): resource_type = "AWS::EC2::TrafficMirrorFilterRule" props = { - 'Description': (basestring, False), - 'DestinationCidrBlock': (basestring, True), + 'Description': (str, False), + 'DestinationCidrBlock': (str, True), 'DestinationPortRange': (TrafficMirrorPortRange, False), 'Protocol': (integer, False), - 'RuleAction': (basestring, True), + 'RuleAction': (str, True), 'RuleNumber': (integer, True), - 'SourceCidrBlock': (basestring, True), + 'SourceCidrBlock': (str, True), 'SourcePortRange': (TrafficMirrorPortRange, False), - 'TrafficDirection': (basestring, True), - 'TrafficMirrorFilterId': (basestring, True), + 'TrafficDirection': (str, True), + 'TrafficMirrorFilterId': (str, True), } @@ -1218,13 +1218,13 @@ class TrafficMirrorSession(AWSObject): resource_type = "AWS::EC2::TrafficMirrorSession" props = { - 'Description': (basestring, False), - 'NetworkInterfaceId': (basestring, True), + 'Description': (str, False), + 'NetworkInterfaceId': (str, True), 'PacketLength': (integer, False), 'SessionNumber': (integer, True), 'Tags': (Tags, False), - 'TrafficMirrorFilterId': (basestring, True), - 'TrafficMirrorTargetId': (basestring, True), + 'TrafficMirrorFilterId': (str, True), + 'TrafficMirrorTargetId': (str, True), 'VirtualNetworkId': (integer, False), } @@ -1233,9 +1233,9 @@ class TrafficMirrorTarget(AWSObject): resource_type = "AWS::EC2::TrafficMirrorTarget" props = { - 'Description': (basestring, False), - 'NetworkInterfaceId': (basestring, False), - 'NetworkLoadBalancerArn': (basestring, False), + 'Description': (str, False), + 'NetworkInterfaceId': (str, False), + 'NetworkLoadBalancerArn': (str, False), 'Tags': (Tags, False), } @@ -1244,29 +1244,29 @@ class TransitGateway(AWSObject): resource_type = "AWS::EC2::TransitGateway" props = { 'AmazonSideAsn': (integer, False), - 'AutoAcceptSharedAttachments': (basestring, False), - 'DefaultRouteTableAssociation': (basestring, False), - 'DefaultRouteTablePropagation': (basestring, False), - 'Description': (basestring, False), - 'DnsSupport': (basestring, False), + 'AutoAcceptSharedAttachments': (str, False), + 'DefaultRouteTableAssociation': (str, False), + 'DefaultRouteTablePropagation': (str, False), + 'Description': (str, False), + 'DnsSupport': (str, False), 'Tags': ((Tags, list), False), - 'VpnEcmpSupport': (basestring, False), + 'VpnEcmpSupport': (str, False), } class TransitGatewayAttachment(AWSObject): resource_type = "AWS::EC2::TransitGatewayAttachment" props = { - 'SubnetIds': ([basestring], True), + 'SubnetIds': ([str], True), 'Tags': ((Tags, list), False), - 'TransitGatewayId': (basestring, True), - 'VpcId': (basestring, True), + 'TransitGatewayId': (str, True), + 'VpcId': (str, True), } class TransitGatewayConnectOptions(AWSProperty): props = { - 'Protocol': (basestring, False), + 'Protocol': (str, False), } @@ -1276,7 +1276,7 @@ class TransitGatewayConnect(AWSObject): props = { 'Options': (TransitGatewayConnectOptions, True), 'Tags': (Tags, False), - 'TransportTransitGatewayAttachmentId': (basestring, True), + 'TransportTransitGatewayAttachmentId': (str, True), } @@ -1286,7 +1286,7 @@ class TransitGatewayMulticastDomain(AWSObject): props = { 'Options': (dict, False), 'Tags': (Tags, False), - 'TransitGatewayId': (basestring, True), + 'TransitGatewayId': (str, True), } @@ -1294,9 +1294,9 @@ class TransitGatewayMulticastDomainAssociation(AWSObject): resource_type = "AWS::EC2::TransitGatewayMulticastDomainAssociation" props = { - 'SubnetId': (basestring, True), - 'TransitGatewayAttachmentId': (basestring, True), - 'TransitGatewayMulticastDomainId': (basestring, True), + 'SubnetId': (str, True), + 'TransitGatewayAttachmentId': (str, True), + 'TransitGatewayMulticastDomainId': (str, True), } @@ -1304,9 +1304,9 @@ class TransitGatewayMulticastGroupMember(AWSObject): resource_type = "AWS::EC2::TransitGatewayMulticastGroupMember" props = { - 'GroupIpAddress': (basestring, True), - 'NetworkInterfaceId': (basestring, True), - 'TransitGatewayMulticastDomainId': (basestring, True), + 'GroupIpAddress': (str, True), + 'NetworkInterfaceId': (str, True), + 'TransitGatewayMulticastDomainId': (str, True), } @@ -1314,9 +1314,9 @@ class TransitGatewayMulticastGroupSource(AWSObject): resource_type = "AWS::EC2::TransitGatewayMulticastGroupSource" props = { - 'GroupIpAddress': (basestring, True), - 'NetworkInterfaceId': (basestring, True), - 'TransitGatewayMulticastDomainId': (basestring, True), + 'GroupIpAddress': (str, True), + 'NetworkInterfaceId': (str, True), + 'TransitGatewayMulticastDomainId': (str, True), } @@ -1324,9 +1324,9 @@ class TransitGatewayRoute(AWSObject): resource_type = "AWS::EC2::TransitGatewayRoute" props = { 'Blackhole': (boolean, False), - 'DestinationCidrBlock': (basestring, False), - 'TransitGatewayAttachmentId': (basestring, False), - 'TransitGatewayRouteTableId': (basestring, True), + 'DestinationCidrBlock': (str, False), + 'TransitGatewayAttachmentId': (str, False), + 'TransitGatewayRouteTableId': (str, True), } @@ -1334,41 +1334,41 @@ class TransitGatewayRouteTable(AWSObject): resource_type = "AWS::EC2::TransitGatewayRouteTable" props = { 'Tags': ((Tags, list), False), - 'TransitGatewayId': (basestring, True), + 'TransitGatewayId': (str, True), } class TransitGatewayRouteTableAssociation(AWSObject): resource_type = "AWS::EC2::TransitGatewayRouteTableAssociation" props = { - 'TransitGatewayAttachmentId': (basestring, True), - 'TransitGatewayRouteTableId': (basestring, True), + 'TransitGatewayAttachmentId': (str, True), + 'TransitGatewayRouteTableId': (str, True), } class TransitGatewayRouteTablePropagation(AWSObject): resource_type = "AWS::EC2::TransitGatewayRouteTablePropagation" props = { - 'TransitGatewayAttachmentId': (basestring, True), - 'TransitGatewayRouteTableId': (basestring, True), + 'TransitGatewayAttachmentId': (str, True), + 'TransitGatewayRouteTableId': (str, True), } class FleetLaunchTemplateSpecificationRequest(AWSProperty): props = { - 'LaunchTemplateId': (basestring, False), - 'LaunchTemplateName': (basestring, False), - 'Version': (basestring, False), + 'LaunchTemplateId': (str, False), + 'LaunchTemplateName': (str, False), + 'Version': (str, False), } class FleetLaunchTemplateOverridesRequest(AWSProperty): props = { - 'AvailabilityZone': (basestring, False), - 'InstanceType': (basestring, False), - 'MaxPrice': (basestring, False), + 'AvailabilityZone': (str, False), + 'InstanceType': (str, False), + 'MaxPrice': (str, False), 'Priority': (double, False), - 'SubnetId': (basestring, False), + 'SubnetId': (str, False), 'WeightedCapacity': (double, False), } @@ -1385,21 +1385,21 @@ class FleetLaunchTemplateConfigRequest(AWSProperty): class OnDemandOptionsRequest(AWSProperty): props = { - 'AllocationStrategy': (basestring, False), + 'AllocationStrategy': (str, False), } class SpotOptionsRequest(AWSProperty): props = { - 'AllocationStrategy': (basestring, False), - 'InstanceInterruptionBehavior': (basestring, False), + 'AllocationStrategy': (str, False), + 'InstanceInterruptionBehavior': (str, False), 'InstancePoolsToUseCount': (integer, False), } class TargetCapacitySpecificationRequest(AWSProperty): props = { - 'DefaultTargetCapacityType': (basestring, False), + 'DefaultTargetCapacityType': (str, False), 'OnDemandTargetCapacity': (integer, False), 'SpotTargetCapacity': (integer, False), 'TotalTargetCapacity': (integer, False), @@ -1409,7 +1409,7 @@ class TargetCapacitySpecificationRequest(AWSProperty): class EC2Fleet(AWSObject): resource_type = "AWS::EC2::EC2Fleet" props = { - 'ExcessCapacityTerminationPolicy': (basestring, False), + 'ExcessCapacityTerminationPolicy': (str, False), 'LaunchTemplateConfigs': ([FleetLaunchTemplateConfigRequest], True), 'OnDemandOptions': (OnDemandOptionsRequest, False), 'ReplaceUnhealthyInstances': (boolean, False), @@ -1418,7 +1418,7 @@ class EC2Fleet(AWSObject): 'TargetCapacitySpecification': (TargetCapacitySpecificationRequest, False), 'TerminateInstancesWithExpiration': (boolean, False), - 'Type': (basestring, False), + 'Type': (str, False), 'ValidFrom': (str, False), 'ValidUntil': (str, False), } @@ -1427,17 +1427,17 @@ class EC2Fleet(AWSObject): class CapacityReservation(AWSObject): resource_type = "AWS::EC2::CapacityReservation" props = { - 'AvailabilityZone': (basestring, True), + 'AvailabilityZone': (str, True), 'EbsOptimized': (boolean, False), - 'EndDate': (basestring, False), - 'EndDateType': (basestring, False), + 'EndDate': (str, False), + 'EndDateType': (str, False), 'EphemeralStorage': (boolean, False), 'InstanceCount': (integer, True), - 'InstanceMatchCriteria': (basestring, False), - 'InstancePlatform': (basestring, True), - 'InstanceType': (basestring, True), + 'InstanceMatchCriteria': (str, False), + 'InstancePlatform': (str, True), + 'InstanceType': (str, True), 'TagSpecifications': ([TagSpecifications], False), - 'Tenancy': (basestring, False), + 'Tenancy': (str, False), } @@ -1445,30 +1445,30 @@ class ClientVpnAuthorizationRule(AWSObject): resource_type = "AWS::EC2::ClientVpnAuthorizationRule" props = { - 'AccessGroupId': (basestring, False), + 'AccessGroupId': (str, False), 'AuthorizeAllGroups': (boolean, False), - 'ClientVpnEndpointId': (basestring, True), - 'Description': (basestring, False), - 'TargetNetworkCidr': (basestring, True), + 'ClientVpnEndpointId': (str, True), + 'Description': (str, False), + 'TargetNetworkCidr': (str, True), } class CertificateAuthenticationRequest(AWSProperty): props = { - 'ClientRootCertificateChainArn': (basestring, True), + 'ClientRootCertificateChainArn': (str, True), } class DirectoryServiceAuthenticationRequest(AWSProperty): props = { - 'DirectoryId': (basestring, True) + 'DirectoryId': (str, True) } class FederatedAuthenticationRequest(AWSProperty): props = { - 'SAMLProviderArn': (basestring, True), - 'SelfServiceSAMLProviderArn': (basestring, False) + 'SAMLProviderArn': (str, True), + 'SelfServiceSAMLProviderArn': (str, False) } @@ -1477,21 +1477,21 @@ class ClientAuthenticationRequest(AWSProperty): 'ActiveDirectory': (DirectoryServiceAuthenticationRequest, False), 'FederatedAuthentication': (FederatedAuthenticationRequest, False), 'MutualAuthentication': (CertificateAuthenticationRequest, False), - 'Type': (basestring, True), + 'Type': (str, True), } class ClientConnectOptions(AWSProperty): props = { 'Enabled': (bool, True), - 'LambdaFunctionArn': (basestring, False) + 'LambdaFunctionArn': (str, False) } class ConnectionLogOptions(AWSProperty): props = { - 'CloudwatchLogGroup': (basestring, False), - 'CloudwatchLogStream': (basestring, False), + 'CloudwatchLogGroup': (str, False), + 'CloudwatchLogStream': (str, False), 'Enabled': (boolean, True), } @@ -1501,20 +1501,20 @@ class ClientVpnEndpoint(AWSObject): props = { 'AuthenticationOptions': ([ClientAuthenticationRequest], True), - 'ClientCidrBlock': (basestring, True), + 'ClientCidrBlock': (str, True), 'ClientConnectOptions': (ClientConnectOptions, False), 'ConnectionLogOptions': (ConnectionLogOptions, True), - 'Description': (basestring, False), - 'DnsServers': ([basestring], False), - 'SecurityGroupIds': ([basestring], False), + 'Description': (str, False), + 'DnsServers': ([str], False), + 'SecurityGroupIds': ([str], False), 'SelfServicePortal': ( validate_clientvpnendpoint_selfserviceportal, False ), - 'ServerCertificateArn': (basestring, True), + 'ServerCertificateArn': (str, True), 'SplitTunnel': (boolean, False), 'TagSpecifications': ([TagSpecifications], False), - 'TransportProtocol': (basestring, False), - 'VpcId': (basestring, False), + 'TransportProtocol': (str, False), + 'VpcId': (str, False), 'VpnPort': (validate_clientvpnendpoint_vpnport, False), } @@ -1523,10 +1523,10 @@ class ClientVpnRoute(AWSObject): resource_type = "AWS::EC2::ClientVpnRoute" props = { - 'ClientVpnEndpointId': (basestring, True), - 'Description': (basestring, False), - 'DestinationCidrBlock': (basestring, True), - 'TargetVpcSubnetId': (basestring, True), + 'ClientVpnEndpointId': (str, True), + 'Description': (str, False), + 'DestinationCidrBlock': (str, True), + 'TargetVpcSubnetId': (str, True), } @@ -1534,8 +1534,8 @@ class ClientVpnTargetNetworkAssociation(AWSObject): resource_type = "AWS::EC2::ClientVpnTargetNetworkAssociation" props = { - 'ClientVpnEndpointId': (basestring, True), - 'SubnetId': (basestring, True), + 'ClientVpnEndpointId': (str, True), + 'SubnetId': (str, True), } @@ -1543,9 +1543,9 @@ class LocalGatewayRoute(AWSObject): resource_type = "AWS::EC2::LocalGatewayRoute" props = { - 'DestinationCidrBlock': (basestring, True), - 'LocalGatewayRouteTableId': (basestring, True), - 'LocalGatewayVirtualInterfaceGroupId': (basestring, True), + 'DestinationCidrBlock': (str, True), + 'LocalGatewayRouteTableId': (str, True), + 'LocalGatewayVirtualInterfaceGroupId': (str, True), } @@ -1553,7 +1553,7 @@ class LocalGatewayRouteTableVPCAssociation(AWSObject): resource_type = "AWS::EC2::LocalGatewayRouteTableVPCAssociation" props = { - 'LocalGatewayRouteTableId': (basestring, True), + 'LocalGatewayRouteTableId': (str, True), 'Tags': ((Tags, list), False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } diff --git a/troposphere/ecr.py b/troposphere/ecr.py index fbb1685f0..8883f6a42 100644 --- a/troposphere/ecr.py +++ b/troposphere/ecr.py @@ -16,7 +16,7 @@ class PublicRepository(AWSObject): props = { 'RepositoryCatalogData': (dict, False), - 'RepositoryName': (basestring, False), + 'RepositoryName': (str, False), 'RepositoryPolicyText': (policytypes, False), 'Tags': (Tags, False), } @@ -32,8 +32,8 @@ class RegistryPolicy(AWSObject): class ReplicationDestination(AWSProperty): props = { - 'Region': (basestring, True), - 'RegistryId': (basestring, True), + 'Region': (str, True), + 'RegistryId': (str, True), } @@ -60,8 +60,8 @@ class ReplicationConfiguration(AWSObject): class LifecyclePolicy(AWSProperty): props = { - 'LifecyclePolicyText': (basestring, False), - 'RegistryId': (basestring, False), + 'LifecyclePolicyText': (str, False), + 'RegistryId': (str, False), } @@ -70,9 +70,9 @@ class Repository(AWSObject): props = { 'ImageScanningConfiguration': (dict, False), - 'ImageTagMutability': (basestring, False), + 'ImageTagMutability': (str, False), 'LifecyclePolicy': (LifecyclePolicy, False), - 'RepositoryName': (basestring, False), + 'RepositoryName': (str, False), 'RepositoryPolicyText': (policytypes, False), 'Tags': (Tags, False), } diff --git a/troposphere/ecs.py b/troposphere/ecs.py index 8eeef9e92..48749efe4 100644 --- a/troposphere/ecs.py +++ b/troposphere/ecs.py @@ -18,7 +18,7 @@ class ManagedScaling(AWSProperty): props = { "MaximumScalingStepSize": (integer_range(1, 10000), False), "MinimumScalingStepSize": (integer_range(1, 10000), False), - "Status": (basestring, False), + "Status": (str, False), "TargetCapacity": (integer_range(1, 100), False), } @@ -28,9 +28,9 @@ class AutoScalingGroupProvider(AWSProperty): Class for property AutoScalingGroupProvider in AWS::ECS::CpacityProvider """ props = { - 'AutoScalingGroupArn': (basestring, True), + 'AutoScalingGroupArn': (str, True), 'ManagedScaling': (ManagedScaling, False), - 'ManagedTerminationProtection': (basestring, False), + 'ManagedTerminationProtection': (str, False), } @@ -41,7 +41,7 @@ class CapacityProvider(AWSObject): resource_type = "AWS::ECS::CapacityProvider" props = { 'AutoScalingGroupProvider': (AutoScalingGroupProvider, True), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), } @@ -52,7 +52,7 @@ class CapacityProviderStrategyItem(AWSProperty): """ props = { 'Base': (integer, False), - 'CapacityProvider': (basestring, False), + 'CapacityProvider': (str, False), 'Weight': (integer, False), } @@ -60,18 +60,18 @@ class CapacityProviderStrategyItem(AWSProperty): class ExecuteCommandLogConfiguration(AWSProperty): props = { 'CloudWatchEncryptionEnabled': (boolean, False), - 'CloudWatchLogGroupName': (basestring, False), - 'S3BucketName': (basestring, False), + 'CloudWatchLogGroupName': (str, False), + 'S3BucketName': (str, False), 'S3EncryptionEnabled': (boolean, False), - 'S3KeyPrefix': (basestring, False), + 'S3KeyPrefix': (str, False), } class ExecuteCommandConfiguration(AWSProperty): props = { - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'LogConfiguration': (ExecuteCommandLogConfiguration, False), - 'Logging': (basestring, False), + 'Logging': (str, False), } @@ -83,8 +83,8 @@ class ClusterConfiguration(AWSProperty): class ClusterSetting(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } @@ -92,8 +92,8 @@ class Cluster(AWSObject): resource_type = "AWS::ECS::Cluster" props = { - 'CapacityProviders': ([basestring], False), - 'ClusterName': (basestring, False), + 'CapacityProviders': ([str], False), + 'ClusterName': (str, False), 'ClusterSettings': ([ClusterSetting], False), 'Configuration': (ClusterConfiguration, False), 'DefaultCapacityProviderStrategy': ( @@ -105,7 +105,7 @@ class Cluster(AWSObject): class CapacityProviderStrategy(AWSProperty): props = { 'Base': (integer, False), - 'CapacityProvider': (basestring, True), + 'CapacityProvider': (str, True), 'Weight': (integer, False), } @@ -114,8 +114,8 @@ class ClusterCapacityProviderAssociations(AWSObject): resource_type = "AWS::ECS::ClusterCapacityProviderAssociations" props = { - 'CapacityProviders': ([basestring], True), - 'Cluster': (basestring, True), + 'CapacityProviders': ([str], True), + 'Cluster': (str, True), 'DefaultCapacityProviderStrategy': ([CapacityProviderStrategy], True), } @@ -125,18 +125,18 @@ class PrimaryTaskSet(AWSObject): resource_type = "AWS::ECS::PrimaryTaskSet" props = { - 'Cluster': (basestring, True), - 'Service': (basestring, True), - 'TaskSetId': (basestring, True), + 'Cluster': (str, True), + 'Service': (str, True), + 'TaskSetId': (str, True), } class LoadBalancer(AWSProperty): props = { - 'ContainerName': (basestring, False), + 'ContainerName': (str, False), 'ContainerPort': (network_port, True), - 'LoadBalancerName': (basestring, False), - 'TargetGroupArn': (basestring, False), + 'LoadBalancerName': (str, False), + 'TargetGroupArn': (str, False), } @@ -160,7 +160,7 @@ class DeploymentConfiguration(AWSProperty): class DeploymentController(AWSProperty): props = { - 'Type': (basestring, False), + 'Type': (str, False), } @@ -191,20 +191,20 @@ def scope_validator(x): class PlacementConstraint(AWSProperty): props = { 'Type': (placement_constraint_validator, True), - 'Expression': (basestring, False), + 'Expression': (str, False), } class PlacementStrategy(AWSProperty): props = { 'Type': (placement_strategy_validator, True), - 'Field': (basestring, False), + 'Field': (str, False), } class AwsvpcConfiguration(AWSProperty): props = { - 'AssignPublicIp': (basestring, False), + 'AssignPublicIp': (str, False), 'SecurityGroups': (list, False), 'Subnets': (list, True), } @@ -226,10 +226,10 @@ def launch_type_validator(x): class ServiceRegistry(AWSProperty): props = { - 'ContainerName': (basestring, False), + 'ContainerName': (str, False), 'ContainerPort': (integer, False), 'Port': (integer, False), - 'RegistryArn': (basestring, False), + 'RegistryArn': (str, False), } @@ -238,7 +238,7 @@ class Service(AWSObject): props = { 'CapacityProviderStrategy': ([CapacityProviderStrategyItem], False), - 'Cluster': (basestring, False), + 'Cluster': (str, False), 'DeploymentConfiguration': (DeploymentConfiguration, False), 'DeploymentController': (DeploymentController, False), 'DesiredCount': (positive_integer, False), @@ -248,30 +248,30 @@ class Service(AWSObject): 'LaunchType': (launch_type_validator, False), 'LoadBalancers': ([LoadBalancer], False), 'NetworkConfiguration': (NetworkConfiguration, False), - 'Role': (basestring, False), + 'Role': (str, False), 'PlacementConstraints': ([PlacementConstraint], False), 'PlacementStrategies': ([PlacementStrategy], False), - 'PlatformVersion': (basestring, False), - 'PropagateTags': (basestring, False), - 'SchedulingStrategy': (basestring, False), - 'ServiceName': (basestring, False), + 'PlatformVersion': (str, False), + 'PropagateTags': (str, False), + 'SchedulingStrategy': (str, False), + 'ServiceName': (str, False), 'ServiceRegistries': ([ServiceRegistry], False), 'Tags': (Tags, False), - 'TaskDefinition': (basestring, True), + 'TaskDefinition': (str, True), } class Environment(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class MountPoint(AWSProperty): props = { - 'ContainerPath': (basestring, True), - 'SourceVolume': (basestring, True), + 'ContainerPath': (str, True), + 'SourceVolume': (str, True), 'ReadOnly': (boolean, False), } @@ -280,42 +280,42 @@ class PortMapping(AWSProperty): props = { 'ContainerPort': (network_port, True), 'HostPort': (network_port, False), - 'Protocol': (basestring, False), + 'Protocol': (str, False), } class VolumesFrom(AWSProperty): props = { - 'SourceContainer': (basestring, True), + 'SourceContainer': (str, True), 'ReadOnly': (boolean, False), } class HostEntry(AWSProperty): props = { - 'Hostname': (basestring, True), - 'IpAddress': (basestring, True), + 'Hostname': (str, True), + 'IpAddress': (str, True), } class Device(AWSProperty): props = { - 'ContainerPath': (basestring, False), - 'HostPath': (basestring, False), - 'Permissions': ([basestring], False), + 'ContainerPath': (str, False), + 'HostPath': (str, False), + 'Permissions': ([str], False), } class FirelensConfiguration(AWSProperty): props = { 'Options': (dict, False), - 'Type': (basestring, True), + 'Type': (str, True), } class HealthCheck(AWSProperty): props = { - 'Command': ([basestring], True), + 'Command': ([str], True), 'Interval': (integer, False), 'Retries': (integer, False), 'StartPeriod': (integer, False), @@ -325,15 +325,15 @@ class HealthCheck(AWSProperty): class KernelCapabilities(AWSProperty): props = { - 'Add': ([basestring], False), - 'Drop': ([basestring], False), + 'Add': ([str], False), + 'Drop': ([str], False), } class Tmpfs(AWSProperty): props = { - 'ContainerPath': (basestring, False), - 'MountOptions': ([basestring], False), + 'ContainerPath': (str, False), + 'MountOptions': ([str], False), 'Size': (integer, False), } @@ -350,14 +350,14 @@ class LinuxParameters(AWSProperty): class Secret(AWSProperty): props = { - 'Name': (basestring, True), - 'ValueFrom': (basestring, True), + 'Name': (str, True), + 'ValueFrom': (str, True), } class LogConfiguration(AWSProperty): props = { - 'LogDriver': (basestring, True), + 'LogDriver': (str, True), 'Options': (dict, False), 'SecretOptions': ([Secret], False), } @@ -365,73 +365,73 @@ class LogConfiguration(AWSProperty): class RepositoryCredentials(AWSProperty): props = { - 'CredentialsParameter': (basestring, False) + 'CredentialsParameter': (str, False) } class ResourceRequirement(AWSProperty): props = { - 'Type': (basestring, True), - 'Value': (basestring, True), + 'Type': (str, True), + 'Value': (str, True), } class SystemControl(AWSProperty): props = { - 'Namespace': (basestring, True), - 'Value': (basestring, True), + 'Namespace': (str, True), + 'Value': (str, True), } class Ulimit(AWSProperty): props = { 'HardLimit': (integer, True), - 'Name': (basestring, True), + 'Name': (str, True), 'SoftLimit': (integer, True), } class ContainerDependency(AWSProperty): props = { - 'Condition': (basestring, True), - 'ContainerName': (basestring, True) + 'Condition': (str, True), + 'ContainerName': (str, True) } class EnvironmentFile(AWSProperty): props = { - 'Type': (basestring, False), - 'Value': (basestring, False), + 'Type': (str, False), + 'Value': (str, False), } class ContainerDefinition(AWSProperty): props = { - 'Command': ([basestring], False), + 'Command': ([str], False), 'Cpu': (integer, False), 'DependsOn': ([ContainerDependency], False), 'DisableNetworking': (boolean, False), - 'DnsSearchDomains': ([basestring], False), - 'DnsServers': ([basestring], False), + 'DnsSearchDomains': ([str], False), + 'DnsServers': ([str], False), 'DockerLabels': (dict, False), - 'DockerSecurityOptions': ([basestring], False), - 'EntryPoint': ([basestring], False), + 'DockerSecurityOptions': ([str], False), + 'EntryPoint': ([str], False), 'Environment': ([Environment], False), 'EnvironmentFiles': ([EnvironmentFile], False), 'Essential': (boolean, False), 'ExtraHosts': ([HostEntry], False), 'FirelensConfiguration': (FirelensConfiguration, False), 'HealthCheck': (HealthCheck, False), - 'Hostname': (basestring, False), - 'Image': (basestring, False), + 'Hostname': (str, False), + 'Image': (str, False), 'Interactive': (boolean, False), - 'Links': ([basestring], False), + 'Links': ([str], False), 'LinuxParameters': (LinuxParameters, False), 'LogConfiguration': (LogConfiguration, False), 'Memory': (integer, False), 'MemoryReservation': (integer, False), 'MountPoints': ([MountPoint], False), - 'Name': (basestring, False), + 'Name': (str, False), 'PortMappings': ([PortMapping], False), 'Privileged': (boolean, False), 'PseudoTerminal': (boolean, False), @@ -443,22 +443,22 @@ class ContainerDefinition(AWSProperty): 'StopTimeout': (integer, False), 'SystemControls': ([SystemControl], False), 'Ulimits': ([Ulimit], False), - 'User': (basestring, False), + 'User': (str, False), 'VolumesFrom': ([VolumesFrom], False), - 'WorkingDirectory': (basestring, False), + 'WorkingDirectory': (str, False), } class Host(AWSProperty): props = { - 'SourcePath': (basestring, False), + 'SourcePath': (str, False), } class DockerVolumeConfiguration(AWSProperty): props = { 'Autoprovision': (boolean, False), - 'Driver': (basestring, False), + 'Driver': (str, False), 'DriverOpts': (dict, False), 'Labels': (dict, False), 'Scope': (scope_validator, False) @@ -467,16 +467,16 @@ class DockerVolumeConfiguration(AWSProperty): class AuthorizationConfig(AWSProperty): props = { - 'AccessPointId': (basestring, False), - 'IAM': (basestring, False) + 'AccessPointId': (str, False), + 'IAM': (str, False) } class EFSVolumeConfiguration(AWSProperty): props = { 'AuthorizationConfig': (AuthorizationConfig, False), - 'FilesystemId': (basestring, True), - 'RootDirectory': (basestring, False), + 'FilesystemId': (str, True), + 'RootDirectory': (str, False), 'TransitEncryption': (ecs_efs_encryption_status, False), 'TransitEncryptionPort': (integer_range(1, (2 ** 16) - 1), False) } @@ -485,7 +485,7 @@ class EFSVolumeConfiguration(AWSProperty): class Volume(AWSProperty): props = { 'DockerVolumeConfiguration': (DockerVolumeConfiguration, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Host': (Host, False), 'EFSVolumeConfiguration': (EFSVolumeConfiguration, False) } @@ -493,14 +493,14 @@ class Volume(AWSProperty): class InferenceAccelerator(AWSProperty): props = { - 'DeviceName': (basestring, False), - 'DeviceType': (basestring, False), + 'DeviceName': (str, False), + 'DeviceType': (str, False), } class ProxyConfiguration(AWSProperty): props = { - 'ContainerName': (basestring, True), + 'ContainerName': (str, True), 'ProxyConfigurationProperties': (list, False), 'Type': (ecs_proxy_type, False) } @@ -511,26 +511,26 @@ class TaskDefinition(AWSObject): props = { 'ContainerDefinitions': ([ContainerDefinition], False), - 'Cpu': (basestring, False), - 'ExecutionRoleArn': (basestring, False), - 'Family': (basestring, False), + 'Cpu': (str, False), + 'ExecutionRoleArn': (str, False), + 'Family': (str, False), 'InferenceAccelerators': ([InferenceAccelerator], False), - 'IpcMode': (basestring, False), - 'Memory': (basestring, False), - 'NetworkMode': (basestring, False), - 'PidMode': (basestring, False), + 'IpcMode': (str, False), + 'Memory': (str, False), + 'NetworkMode': (str, False), + 'PidMode': (str, False), 'PlacementConstraints': ([PlacementConstraint], False), 'ProxyConfiguration': (ProxyConfiguration, False), - 'RequiresCompatibilities': ([basestring], False), + 'RequiresCompatibilities': ([str], False), 'Tags': (Tags, False), - 'TaskRoleArn': (basestring, False), + 'TaskRoleArn': (str, False), 'Volumes': ([Volume], False), } class Scale(AWSProperty): props = { - 'Unit': (basestring, False), + 'Unit': (str, False), 'Value': (double, False), } @@ -539,14 +539,14 @@ class TaskSet(AWSObject): resource_type = "AWS::ECS::TaskSet" props = { - 'Cluster': (basestring, True), - 'ExternalId': (basestring, False), - 'LaunchType': (basestring, False), + 'Cluster': (str, True), + 'ExternalId': (str, False), + 'LaunchType': (str, False), 'LoadBalancers': ([LoadBalancer], False), 'NetworkConfiguration': (NetworkConfiguration, False), - 'PlatformVersion': (basestring, False), + 'PlatformVersion': (str, False), 'Scale': (Scale, False), - 'Service': (basestring, True), + 'Service': (str, True), 'ServiceRegistries': ([ServiceRegistry], False), - 'TaskDefinition': (basestring, True), + 'TaskDefinition': (str, True), } diff --git a/troposphere/efs.py b/troposphere/efs.py index 9688559c1..dd76dec53 100644 --- a/troposphere/efs.py +++ b/troposphere/efs.py @@ -24,24 +24,24 @@ def provisioned_throughput_validator(throughput): class PosixUser(AWSProperty): props = { - 'Gid': (basestring, True), - 'SecondaryGids': ([basestring], False), - 'Uid': (basestring, True), + 'Gid': (str, True), + 'SecondaryGids': ([str], False), + 'Uid': (str, True), } class CreationInfo(AWSProperty): props = { - 'OwnerGid': (basestring, True), - 'OwnerUid': (basestring, True), - 'Permissions': (basestring, True), + 'OwnerGid': (str, True), + 'OwnerUid': (str, True), + 'Permissions': (str, True), } class RootDirectory(AWSProperty): props = { 'CreationInfo': (CreationInfo, False), - 'Path': (basestring, False), + 'Path': (str, False), } @@ -50,8 +50,8 @@ class AccessPoint(AWSObject): props = { 'AccessPointTags': (Tags, False), - 'ClientToken': (basestring, False), - 'FileSystemId': (basestring, True), + 'ClientToken': (str, False), + 'FileSystemId': (str, True), 'PosixUser': (PosixUser, False), 'RootDirectory': (RootDirectory, False), } @@ -59,13 +59,13 @@ class AccessPoint(AWSObject): class LifecyclePolicy(AWSProperty): props = { - 'TransitionToIA': (basestring, True), + 'TransitionToIA': (str, True), } class BackupPolicy(AWSProperty): props = { - 'Status': (basestring, True), + 'Status': (str, True), } def validate(self): @@ -82,14 +82,14 @@ class FileSystem(AWSObject): resource_type = "AWS::EFS::FileSystem" props = { - 'AvailabilityZoneName': (basestring, False), + 'AvailabilityZoneName': (str, False), 'BackupPolicy': (BackupPolicy, False), 'Encrypted': (boolean, False), 'FileSystemPolicy': (dict, False), 'FileSystemTags': (Tags, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'LifecyclePolicies': ([LifecyclePolicy], False), - 'PerformanceMode': (basestring, False), + 'PerformanceMode': (str, False), 'ProvisionedThroughputInMibps': (float, False), 'ThroughputMode': (throughput_mode_validator, False), } @@ -99,8 +99,8 @@ class MountTarget(AWSObject): resource_type = "AWS::EFS::MountTarget" props = { - 'FileSystemId': (basestring, True), - 'IpAddress': (basestring, False), - 'SecurityGroups': ([basestring], True), - 'SubnetId': (basestring, True), + 'FileSystemId': (str, True), + 'IpAddress': (str, False), + 'SecurityGroups': ([str], True), + 'SubnetId': (str, True), } diff --git a/troposphere/eks.py b/troposphere/eks.py index 68bd5c263..2917564b7 100644 --- a/troposphere/eks.py +++ b/troposphere/eks.py @@ -11,11 +11,11 @@ class Addon(AWSObject): resource_type = "AWS::EKS::Addon" props = { - 'AddonName': (basestring, True), - 'AddonVersion': (basestring, False), - 'ClusterName': (basestring, True), - 'ResolveConflicts': (basestring, False), - 'ServiceAccountRoleArn': (basestring, False), + 'AddonName': (str, True), + 'AddonVersion': (str, False), + 'ClusterName': (str, True), + 'ResolveConflicts': (str, False), + 'ServiceAccountRoleArn': (str, False), 'Tags': (Tags, False), } @@ -23,7 +23,7 @@ class Addon(AWSObject): class LogSetup(AWSProperty): props = { 'Enable': (bool, False), - 'Types': ([basestring], False) + 'Types': ([str], False) } def validate(self): @@ -44,27 +44,27 @@ class Logging(AWSProperty): class Provider(AWSProperty): props = { - 'KeyArn': (basestring, False), + 'KeyArn': (str, False), } class EncryptionConfig(AWSProperty): props = { 'Provider': (Provider, False), - 'Resources': ([basestring], False), + 'Resources': ([str], False), } class KubernetesNetworkConfig(AWSProperty): props = { - 'ServiceIpv4Cidr': (basestring, False), + 'ServiceIpv4Cidr': (str, False), } class ResourcesVpcConfig(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], True), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], True), } @@ -74,25 +74,25 @@ class Cluster(AWSObject): props = { 'EncryptionConfig': ([EncryptionConfig], False), 'KubernetesNetworkConfig': (KubernetesNetworkConfig, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Logging': (Logging, False), 'ResourcesVpcConfig': (ResourcesVpcConfig, True), - 'RoleArn': (basestring, True), - 'Version': (basestring, False), + 'RoleArn': (str, True), + 'Version': (str, False), } class Label(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } class Selector(AWSProperty): props = { 'Labels': ([Label], False), - 'Namespace': (basestring, True), + 'Namespace': (str, True), } @@ -100,19 +100,19 @@ class FargateProfile(AWSObject): resource_type = "AWS::EKS::FargateProfile" props = { - 'ClusterName': (basestring, True), - 'FargateProfileName': (basestring, False), - 'PodExecutionRoleArn': (basestring, True), + 'ClusterName': (str, True), + 'FargateProfileName': (str, False), + 'PodExecutionRoleArn': (str, True), 'Selectors': ([Selector], True), - 'Subnets': ([basestring], False), + 'Subnets': ([str], False), 'Tags': (Tags, False), } class RemoteAccess(AWSProperty): props = { - 'Ec2SshKey': (basestring, True), - 'SourceSecurityGroups': ([basestring], False), + 'Ec2SshKey': (str, True), + 'SourceSecurityGroups': ([str], False), } @@ -126,9 +126,9 @@ class ScalingConfig(AWSProperty): class LaunchTemplateSpecification(AWSProperty): props = { - 'Id': (basestring, False), - 'Name': (basestring, False), - 'Version': (basestring, False), + 'Id': (str, False), + 'Name': (str, False), + 'Version': (str, False), } @@ -136,20 +136,20 @@ class Nodegroup(AWSObject): resource_type = "AWS::EKS::Nodegroup" props = { - 'AmiType': (basestring, False), - 'CapacityType': (basestring, False), - 'ClusterName': (basestring, True), + 'AmiType': (str, False), + 'CapacityType': (str, False), + 'ClusterName': (str, True), 'DiskSize': (double, False), 'ForceUpdateEnabled': (boolean, False), - 'InstanceTypes': ([basestring], False), + 'InstanceTypes': ([str], False), 'Labels': (dict, False), 'LaunchTemplate': (LaunchTemplateSpecification, False), - 'NodegroupName': (basestring, False), - 'NodeRole': (basestring, True), - 'ReleaseVersion': (basestring, False), + 'NodegroupName': (str, False), + 'NodeRole': (str, True), + 'ReleaseVersion': (str, False), 'RemoteAccess': (RemoteAccess, False), 'ScalingConfig': (ScalingConfig, False), - 'Subnets': ([basestring], False), + 'Subnets': ([str], False), 'Tags': (dict, False), - 'Version': (basestring, False), + 'Version': (str, False), } diff --git a/troposphere/elasticache.py b/troposphere/elasticache.py index 3570cb483..c31d7ea64 100644 --- a/troposphere/elasticache.py +++ b/troposphere/elasticache.py @@ -20,26 +20,26 @@ class CacheCluster(AWSObject): props = { 'AutoMinorVersionUpgrade': (boolean, False), - 'AZMode': (basestring, False), - 'CacheNodeType': (basestring, True), - 'CacheParameterGroupName': (basestring, False), - 'CacheSecurityGroupNames': ([basestring], False), - 'CacheSubnetGroupName': (basestring, False), - 'ClusterName': (basestring, False), - 'Engine': (basestring, True), - 'EngineVersion': (basestring, False), - 'NotificationTopicArn': (basestring, False), + 'AZMode': (str, False), + 'CacheNodeType': (str, True), + 'CacheParameterGroupName': (str, False), + 'CacheSecurityGroupNames': ([str], False), + 'CacheSubnetGroupName': (str, False), + 'ClusterName': (str, False), + 'Engine': (str, True), + 'EngineVersion': (str, False), + 'NotificationTopicArn': (str, False), 'NumCacheNodes': (integer, True), 'Port': (integer, False), - 'PreferredAvailabilityZone': (basestring, False), - 'PreferredAvailabilityZones': ([basestring], False), - 'PreferredMaintenanceWindow': (basestring, False), - 'SnapshotArns': ([basestring], False), - 'SnapshotName': (basestring, False), + 'PreferredAvailabilityZone': (str, False), + 'PreferredAvailabilityZones': ([str], False), + 'PreferredMaintenanceWindow': (str, False), + 'SnapshotArns': ([str], False), + 'SnapshotName': (str, False), 'SnapshotRetentionLimit': (integer, False), - 'SnapshotWindow': (basestring, False), + 'SnapshotWindow': (str, False), 'Tags': (Tags, False), - 'VpcSecurityGroupIds': ([basestring], False), + 'VpcSecurityGroupIds': ([str], False), } def validate(self): @@ -62,23 +62,23 @@ def validate(self): class GlobalReplicationGroupMember(AWSProperty): props = { - 'ReplicationGroupId': (basestring, False), - 'ReplicationGroupRegion': (basestring, False), - 'Role': (basestring, False), + 'ReplicationGroupId': (str, False), + 'ReplicationGroupRegion': (str, False), + 'Role': (str, False), } class ReshardingConfiguration(AWSProperty): props = { - 'NodeGroupId': (basestring, False), - 'PreferredAvailabilityZones': ([basestring], False), + 'NodeGroupId': (str, False), + 'PreferredAvailabilityZones': ([str], False), } class RegionalConfiguration(AWSProperty): props = { - 'ReplicationGroupId': (basestring, False), - 'ReplicationGroupRegion': (basestring, False), + 'ReplicationGroupId': (str, False), + 'ReplicationGroupRegion': (str, False), 'ReshardingConfigurations': ([ReshardingConfiguration], False), } @@ -88,12 +88,12 @@ class GlobalReplicationGroup(AWSObject): props = { 'AutomaticFailoverEnabled': (boolean, False), - 'CacheNodeType': (basestring, False), - 'CacheParameterGroupName': (basestring, False), - 'EngineVersion': (basestring, False), + 'CacheNodeType': (str, False), + 'CacheParameterGroupName': (str, False), + 'EngineVersion': (str, False), 'GlobalNodeGroupCount': (integer, False), - 'GlobalReplicationGroupDescription': (basestring, False), - 'GlobalReplicationGroupIdSuffix': (basestring, False), + 'GlobalReplicationGroupDescription': (str, False), + 'GlobalReplicationGroupIdSuffix': (str, False), 'Members': ([GlobalReplicationGroupMember], True), 'RegionalConfigurations': ([RegionalConfiguration], False), } @@ -103,8 +103,8 @@ class ParameterGroup(AWSObject): resource_type = "AWS::ElastiCache::ParameterGroup" props = { - 'CacheParameterGroupFamily': (basestring, True), - 'Description': (basestring, True), + 'CacheParameterGroupFamily': (str, True), + 'Description': (str, True), 'Properties': (dict, True), } @@ -113,7 +113,7 @@ class SecurityGroup(AWSObject): resource_type = "AWS::ElastiCache::SecurityGroup" props = { - 'Description': (basestring, False), + 'Description': (str, False), } @@ -121,9 +121,9 @@ class SecurityGroupIngress(AWSObject): resource_type = "AWS::ElastiCache::SecurityGroupIngress" props = { - 'CacheSecurityGroupName': (basestring, True), - 'EC2SecurityGroupName': (basestring, True), - 'EC2SecurityGroupOwnerId': (basestring, False), + 'CacheSecurityGroupName': (str, True), + 'EC2SecurityGroupName': (str, True), + 'EC2SecurityGroupOwnerId': (str, False), } @@ -131,8 +131,8 @@ class SubnetGroup(AWSObject): resource_type = "AWS::ElastiCache::SubnetGroup" props = { - 'CacheSubnetGroupName': (basestring, False), - 'Description': (basestring, True), + 'CacheSubnetGroupName': (str, False), + 'Description': (str, True), 'SubnetIds': (list, True), } @@ -140,10 +140,10 @@ class SubnetGroup(AWSObject): class NodeGroupConfiguration(AWSProperty): props = { 'NodeGroupId': (validate_node_group_id, False), - 'PrimaryAvailabilityZone': (basestring, False), - 'ReplicaAvailabilityZones': ([basestring], False), + 'PrimaryAvailabilityZone': (str, False), + 'ReplicaAvailabilityZones': ([str], False), 'ReplicaCount': (integer, False), - 'Slots': (basestring, False), + 'Slots': (str, False), } @@ -152,37 +152,37 @@ class ReplicationGroup(AWSObject): props = { 'AtRestEncryptionEnabled': (boolean, False), - 'AuthToken': (basestring, False), + 'AuthToken': (str, False), 'AutoMinorVersionUpgrade': (boolean, False), 'AutomaticFailoverEnabled': (boolean, False), - 'CacheNodeType': (basestring, False), - 'CacheParameterGroupName': (basestring, False), - 'CacheSecurityGroupNames': ([basestring], False), - 'CacheSubnetGroupName': (basestring, False), - 'Engine': (basestring, False), - 'EngineVersion': (basestring, False), - 'KmsKeyId': (basestring, False), + 'CacheNodeType': (str, False), + 'CacheParameterGroupName': (str, False), + 'CacheSecurityGroupNames': ([str], False), + 'CacheSubnetGroupName': (str, False), + 'Engine': (str, False), + 'EngineVersion': (str, False), + 'KmsKeyId': (str, False), 'MultiAZEnabled': (boolean, False), 'NodeGroupConfiguration': ([NodeGroupConfiguration], False), - 'NotificationTopicArn': (basestring, False), + 'NotificationTopicArn': (str, False), 'NumCacheClusters': (integer, False), 'NumNodeGroups': (integer, False), 'Port': (network_port, False), - 'PreferredCacheClusterAZs': ([basestring], False), - 'PreferredMaintenanceWindow': (basestring, False), - 'PrimaryClusterId': (basestring, False), + 'PreferredCacheClusterAZs': ([str], False), + 'PreferredMaintenanceWindow': (str, False), + 'PrimaryClusterId': (str, False), 'ReplicasPerNodeGroup': (integer, False), - 'ReplicationGroupDescription': (basestring, True), - 'ReplicationGroupId': (basestring, False), - 'SecurityGroupIds': ([basestring], False), - 'SnapshotArns': ([basestring], False), - 'SnapshotName': (basestring, False), + 'ReplicationGroupDescription': (str, True), + 'ReplicationGroupId': (str, False), + 'SecurityGroupIds': ([str], False), + 'SnapshotArns': ([str], False), + 'SnapshotName': (str, False), 'SnapshotRetentionLimit': (integer, False), - 'SnapshotWindow': (basestring, False), - 'SnapshottingClusterId': (basestring, False), + 'SnapshotWindow': (str, False), + 'SnapshottingClusterId': (str, False), 'Tags': (Tags, False), 'TransitEncryptionEnabled': (boolean, False), - 'UserGroupIds': ([basestring], False), + 'UserGroupIds': ([str], False), } def validate(self): diff --git a/troposphere/elasticbeanstalk.py b/troposphere/elasticbeanstalk.py index 5049bd2cc..529d400ef 100644 --- a/troposphere/elasticbeanstalk.py +++ b/troposphere/elasticbeanstalk.py @@ -37,31 +37,31 @@ class ApplicationVersionLifecycleConfig(AWSProperty): class SourceBundle(AWSProperty): props = { - 'S3Bucket': (basestring, True), - 'S3Key': (basestring, True), + 'S3Bucket': (str, True), + 'S3Key': (str, True), } class SourceConfiguration(AWSProperty): props = { - 'ApplicationName': (basestring, True), - 'TemplateName': (basestring, True), + 'ApplicationName': (str, True), + 'TemplateName': (str, True), } class ApplicationResourceLifecycleConfig(AWSProperty): props = { - 'ServiceRole': (basestring, False), + 'ServiceRole': (str, False), 'VersionLifecycleConfig': (ApplicationVersionLifecycleConfig, False), } class OptionSettings(AWSProperty): props = { - 'Namespace': (basestring, True), - 'OptionName': (basestring, True), - 'ResourceName': (basestring, False), - 'Value': (basestring, True), + 'Namespace': (str, True), + 'OptionName': (str, True), + 'ResourceName': (str, False), + 'Value': (str, True), } @@ -69,8 +69,8 @@ class Application(AWSObject): resource_type = "AWS::ElasticBeanstalk::Application" props = { - 'ApplicationName': (basestring, False), - 'Description': (basestring, False), + 'ApplicationName': (str, False), + 'Description': (str, False), 'ResourceLifecycleConfig': (ApplicationResourceLifecycleConfig, False), } @@ -79,8 +79,8 @@ class ApplicationVersion(AWSObject): resource_type = "AWS::ElasticBeanstalk::ApplicationVersion" props = { - 'ApplicationName': (basestring, True), - 'Description': (basestring, False), + 'ApplicationName': (str, True), + 'Description': (str, False), 'SourceBundle': (SourceBundle, False), } @@ -89,12 +89,12 @@ class ConfigurationTemplate(AWSObject): resource_type = "AWS::ElasticBeanstalk::ConfigurationTemplate" props = { - 'ApplicationName': (basestring, True), - 'Description': (basestring, False), - 'EnvironmentId': (basestring, False), + 'ApplicationName': (str, True), + 'Description': (str, False), + 'EnvironmentId': (str, False), 'OptionSettings': ([OptionSettings], False), - 'PlatformArn': (basestring, False), - 'SolutionStackName': (basestring, False), + 'PlatformArn': (str, False), + 'SolutionStackName': (str, False), 'SourceConfiguration': (SourceConfiguration, False), } @@ -117,7 +117,7 @@ class Tier(AWSProperty): props = { 'Name': (validate_tier_name, False), 'Type': (validate_tier_type, False), - 'Version': (basestring, False), + 'Version': (str, False), } @@ -125,15 +125,15 @@ class Environment(AWSObject): resource_type = "AWS::ElasticBeanstalk::Environment" props = { - 'ApplicationName': (basestring, True), - 'CNAMEPrefix': (basestring, False), - 'Description': (basestring, False), - 'EnvironmentName': (basestring, False), + 'ApplicationName': (str, True), + 'CNAMEPrefix': (str, False), + 'Description': (str, False), + 'EnvironmentName': (str, False), 'OptionSettings': ([OptionSettings], False), - 'PlatformArn': (basestring, False), - 'SolutionStackName': (basestring, False), + 'PlatformArn': (str, False), + 'SolutionStackName': (str, False), 'Tags': (Tags, False), - 'TemplateName': (basestring, False), + 'TemplateName': (str, False), 'Tier': (Tier, False), - 'VersionLabel': (basestring, False), + 'VersionLabel': (str, False), } diff --git a/troposphere/elasticloadbalancing.py b/troposphere/elasticloadbalancing.py index ac2925256..403610f6e 100644 --- a/troposphere/elasticloadbalancing.py +++ b/troposphere/elasticloadbalancing.py @@ -10,8 +10,8 @@ class AppCookieStickinessPolicy(AWSProperty): props = { - 'CookieName': (basestring, True), - 'PolicyName': (basestring, True), + 'CookieName': (str, True), + 'PolicyName': (str, True), } @@ -19,7 +19,7 @@ class HealthCheck(AWSProperty): props = { 'HealthyThreshold': (integer_range(2, 10), True), 'Interval': (positive_integer, True), - 'Target': (basestring, True), + 'Target': (str, True), 'Timeout': (positive_integer, True), 'UnhealthyThreshold': (integer_range(2, 10), True), } @@ -27,19 +27,19 @@ class HealthCheck(AWSProperty): class LBCookieStickinessPolicy(AWSProperty): props = { - 'CookieExpirationPeriod': (basestring, False), - 'PolicyName': (basestring, False), + 'CookieExpirationPeriod': (str, False), + 'PolicyName': (str, False), } class Listener(AWSProperty): props = { 'InstancePort': (network_port, True), - 'InstanceProtocol': (basestring, False), + 'InstanceProtocol': (str, False), 'LoadBalancerPort': (network_port, True), 'PolicyNames': (list, False), - 'Protocol': (basestring, True), - 'SSLCertificateId': (basestring, False), + 'Protocol': (str, True), + 'SSLCertificateId': (str, False), } @@ -48,8 +48,8 @@ class Policy(AWSProperty): 'Attributes': ([dict], False), 'InstancePorts': (list, False), 'LoadBalancerPorts': (list, False), - 'PolicyName': (basestring, True), - 'PolicyType': (basestring, True), + 'PolicyName': (str, True), + 'PolicyType': (str, True), } @@ -70,8 +70,8 @@ class AccessLoggingPolicy(AWSProperty): props = { 'EmitInterval': (integer, False), 'Enabled': (bool, True), - 'S3BucketName': (basestring, False), - 'S3BucketPrefix': (basestring, False), + 'S3BucketName': (str, False), + 'S3BucketPrefix': (str, False), } @@ -91,7 +91,7 @@ class LoadBalancer(AWSObject): 'LoadBalancerName': (elb_name, False), 'Listeners': (list, True), 'Policies': (list, False), - 'Scheme': (basestring, False), + 'Scheme': (str, False), 'SecurityGroups': (list, False), 'Subnets': (list, False), 'Tags': ((Tags, list), False), diff --git a/troposphere/elasticloadbalancingv2.py b/troposphere/elasticloadbalancingv2.py index ff8c4093a..d391447a0 100644 --- a/troposphere/elasticloadbalancingv2.py +++ b/troposphere/elasticloadbalancingv2.py @@ -13,43 +13,43 @@ class LoadBalancerAttributes(AWSProperty): props = { - 'Key': (basestring, False), - 'Value': (basestring, False) + 'Key': (str, False), + 'Value': (str, False) } class Certificate(AWSProperty): props = { - 'CertificateArn': (basestring, False) + 'CertificateArn': (str, False) } class AuthenticateCognitoConfig(AWSProperty): props = { "AuthenticationRequestExtraParams": (dict, False), - "OnUnauthenticatedRequest": (basestring, False), - "Scope": (basestring, False), - "SessionCookieName": (basestring, False), + "OnUnauthenticatedRequest": (str, False), + "Scope": (str, False), + "SessionCookieName": (str, False), "SessionTimeout": (integer, False), - "UserPoolArn": (basestring, True), - "UserPoolClientId": (basestring, True), - "UserPoolDomain": (basestring, True) + "UserPoolArn": (str, True), + "UserPoolClientId": (str, True), + "UserPoolDomain": (str, True) } class AuthenticateOidcConfig(AWSProperty): props = { "AuthenticationRequestExtraParams": (dict, False), - "AuthorizationEndpoint": (basestring, True), - "ClientId": (basestring, True), - "ClientSecret": (basestring, True), - "Issuer": (basestring, True), - "OnUnauthenticatedRequest": (basestring, False), - "Scope": (basestring, False), - "SessionCookieName": (basestring, False), + "AuthorizationEndpoint": (str, True), + "ClientId": (str, True), + "ClientSecret": (str, True), + "Issuer": (str, True), + "OnUnauthenticatedRequest": (str, False), + "Scope": (str, False), + "SessionCookieName": (str, False), "SessionTimeout": (integer, False), - "TokenEndpoint": (basestring, True), - "UserInfoEndpoint": (basestring, True) + "TokenEndpoint": (str, True), + "UserInfoEndpoint": (str, True) } @@ -58,12 +58,12 @@ class RedirectConfig(AWSProperty): # AWSCloudFormation/latest/UserGuide/ # aws-properties-elasticloadbalancingv2-listener-redirectconfig.html props = { - 'Host': (basestring, False), - 'Path': (basestring, False), - 'Port': (basestring, False), - 'Protocol': (basestring, False), - 'Query': (basestring, False), - 'StatusCode': (basestring, True), + 'Host': (str, False), + 'Path': (str, False), + 'Port': (str, False), + 'Protocol': (str, False), + 'Query': (str, False), + 'StatusCode': (str, True), } def validate(self): @@ -75,9 +75,9 @@ def validate(self): class FixedResponseConfig(AWSProperty): props = { - 'ContentType': (basestring, False), - 'MessageBody': (basestring, False), - 'StatusCode': (basestring, True), + 'ContentType': (str, False), + 'MessageBody': (str, False), + 'StatusCode': (str, True), } def validate(self): @@ -116,9 +116,9 @@ class Action(AWSProperty): "FixedResponseConfig": (FixedResponseConfig, False), "Order": (integer, False), "RedirectConfig": (RedirectConfig, False), - "TargetGroupArn": (basestring, False), + "TargetGroupArn": (str, False), "ForwardConfig": (ForwardConfig, False), - "Type": (basestring, True) + "Type": (str, True) } @staticmethod @@ -134,7 +134,7 @@ def validate(self): def requires(action_type, prop): properties = [definition for definition in - self.properties.keys()] + list(self.properties.keys())] if self.properties.get('Type') == action_type and \ not self.any_property(prop, properties): raise ValueError( @@ -158,33 +158,33 @@ def requires(action_type, prop): class HostHeaderConfig(AWSProperty): props = { - 'Values': ([basestring], False), + 'Values': ([str], False), } class HttpHeaderConfig(AWSProperty): props = { - 'HttpHeaderName': (basestring, False), - 'Values': ([basestring], False), + 'HttpHeaderName': (str, False), + 'Values': ([str], False), } class HttpRequestMethodConfig(AWSProperty): props = { - 'Values': ([basestring], False), + 'Values': ([str], False), } class PathPatternConfig(AWSProperty): props = { - 'Values': ([basestring], False), + 'Values': ([str], False), } class QueryStringKeyValue(AWSProperty): props = { - 'Key': (basestring, False), - 'Value': (basestring, False), + 'Key': (str, False), + 'Value': (str, False), } @@ -196,48 +196,48 @@ class QueryStringConfig(AWSProperty): class SourceIpConfig(AWSProperty): props = { - 'Values': ([basestring], False), + 'Values': ([str], False), } class Condition(AWSProperty): props = { - 'Field': (basestring, False), + 'Field': (str, False), 'HostHeaderConfig': (HostHeaderConfig, False), 'HttpHeaderConfig': (HttpHeaderConfig, False), 'HttpRequestMethodConfig': (HttpRequestMethodConfig, False), 'PathPatternConfig': (PathPatternConfig, False), 'QueryStringConfig': (QueryStringConfig, False), 'SourceIpConfig': (SourceIpConfig, False), - 'Values': ([basestring], False), + 'Values': ([str], False), } class Matcher(AWSProperty): props = { - 'HttpCode': (basestring, True) + 'HttpCode': (str, True) } class SubnetMapping(AWSProperty): props = { - 'AllocationId': (basestring, False), - 'PrivateIPv4Address': (basestring, False), - 'SubnetId': (basestring, True), + 'AllocationId': (str, False), + 'PrivateIPv4Address': (str, False), + 'SubnetId': (str, True), } class TargetGroupAttribute(AWSProperty): props = { - 'Key': (basestring, False), - 'Value': (basestring, False) + 'Key': (str, False), + 'Value': (str, False) } class TargetDescription(AWSProperty): props = { - 'AvailabilityZone': (basestring, False), - 'Id': (basestring, True), + 'AvailabilityZone': (str, False), + 'Id': (str, True), 'Port': (network_port, False) } @@ -246,13 +246,13 @@ class Listener(AWSObject): resource_type = "AWS::ElasticLoadBalancingV2::Listener" props = { - 'AlpnPolicy': ([basestring], False), + 'AlpnPolicy': ([str], False), 'Certificates': ([Certificate], False), 'DefaultActions': ([Action], True), - 'LoadBalancerArn': (basestring, True), + 'LoadBalancerArn': (str, True), 'Port': (network_port, True), - 'Protocol': (basestring, True), - 'SslPolicy': (basestring, False) + 'Protocol': (str, True), + 'SslPolicy': (str, False) } @@ -261,7 +261,7 @@ class ListenerCertificate(AWSObject): props = { 'Certificates': ([Certificate], True), - 'ListenerArn': (basestring, True), + 'ListenerArn': (str, True), } @@ -271,7 +271,7 @@ class ListenerRule(AWSObject): props = { 'Actions': ([Action], True), 'Conditions': ([Condition], True), - 'ListenerArn': (basestring, True), + 'ListenerArn': (str, True), 'Priority': (integer, True) } @@ -297,21 +297,21 @@ class TargetGroup(AWSObject): props = { 'HealthCheckEnabled': (boolean, False), 'HealthCheckIntervalSeconds': (integer, False), - 'HealthCheckPath': (basestring, False), + 'HealthCheckPath': (str, False), 'HealthCheckPort': (tg_healthcheck_port, False), - 'HealthCheckProtocol': (basestring, False), + 'HealthCheckProtocol': (str, False), 'HealthCheckTimeoutSeconds': (integer, False), 'HealthyThresholdCount': (integer, False), 'Matcher': (Matcher, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Port': (network_port, False), - 'Protocol': (basestring, False), + 'Protocol': (str, False), 'Tags': ((Tags, list), False), 'TargetGroupAttributes': ([TargetGroupAttribute], False), 'Targets': ([TargetDescription], False), 'TargetType': (validate_target_type, False), 'UnhealthyThresholdCount': (integer, False), - 'VpcId': (basestring, False), + 'VpcId': (str, False), } def validate(self): @@ -370,15 +370,15 @@ class LoadBalancer(AWSObject): resource_type = "AWS::ElasticLoadBalancingV2::LoadBalancer" props = { - 'IpAddressType': (basestring, False), + 'IpAddressType': (str, False), 'LoadBalancerAttributes': ([LoadBalancerAttributes], False), 'Name': (elb_name, False), - 'Scheme': (basestring, False), - 'SecurityGroups': ([basestring], False), + 'Scheme': (str, False), + 'SecurityGroups': ([str], False), 'SubnetMappings': ([SubnetMapping], False), - 'Subnets': ([basestring], False), + 'Subnets': ([str], False), 'Tags': ((Tags, list), False), - 'Type': (basestring, False), + 'Type': (str, False), } def validate(self): diff --git a/troposphere/elasticsearch.py b/troposphere/elasticsearch.py index d68ed85f0..2fcb5c530 100644 --- a/troposphere/elasticsearch.py +++ b/troposphere/elasticsearch.py @@ -33,16 +33,16 @@ def validate_tls_security_policy(tls_security_policy): class CognitoOptions(AWSProperty): props = { 'Enabled': (boolean, False), - 'IdentityPoolId': (basestring, False), - 'RoleArn': (basestring, False), - 'UserPoolId': (basestring, False), + 'IdentityPoolId': (str, False), + 'RoleArn': (str, False), + 'UserPoolId': (str, False), } class DomainEndpointOptions(AWSProperty): props = { - 'CustomEndpoint': (basestring, False), - 'CustomEndpointCertificateArn': (basestring, False), + 'CustomEndpoint': (str, False), + 'CustomEndpointCertificateArn': (str, False), 'CustomEndpointEnabled': (boolean, False), # Conditional 'EnforceHTTPS': (boolean, False), 'TLSSecurityPolicy': (validate_tls_security_policy, False), @@ -74,12 +74,12 @@ class ElasticsearchClusterConfig(AWSProperty): props = { 'DedicatedMasterCount': (integer, False), 'DedicatedMasterEnabled': (boolean, False), - 'DedicatedMasterType': (basestring, False), + 'DedicatedMasterType': (str, False), 'InstanceCount': (integer, False), - 'InstanceType': (basestring, False), + 'InstanceType': (str, False), 'WarmCount': (integer, False), 'WarmEnabled': (boolean, False), - 'WarmType': (basestring, False), + 'WarmType': (str, False), 'ZoneAwarenessConfig': (ZoneAwarenessConfig, False), 'ZoneAwarenessEnabled': (boolean, False) } @@ -88,7 +88,7 @@ class ElasticsearchClusterConfig(AWSProperty): class EncryptionAtRestOptions(AWSProperty): props = { 'Enabled': (boolean, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), } @@ -106,16 +106,16 @@ class SnapshotOptions(AWSProperty): class VPCOptions(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], False) + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], False) } class MasterUserOptions(AWSProperty): props = { - 'MasterUserARN': (basestring, False), - 'MasterUserName': (basestring, False), - 'MasterUserPassword': (basestring, False), + 'MasterUserARN': (str, False), + 'MasterUserName': (str, False), + 'MasterUserPassword': (str, False), } @@ -135,11 +135,11 @@ class Domain(AWSObject): 'AdvancedOptions': (dict, False), 'AdvancedSecurityOptions': (AdvancedSecurityOptionsInput, False), 'CognitoOptions': (CognitoOptions, False), - 'DomainName': (basestring, False), + 'DomainName': (str, False), 'DomainEndpointOptions': (DomainEndpointOptions, False), 'EBSOptions': (EBSOptions, False), 'ElasticsearchClusterConfig': (ElasticsearchClusterConfig, False), - 'ElasticsearchVersion': (basestring, False), + 'ElasticsearchVersion': (str, False), 'EncryptionAtRestOptions': (EncryptionAtRestOptions, False), 'LogPublishingOptions': (dict, False), 'NodeToNodeEncryptionOptions': (NodeToNodeEncryptionOptions, False), diff --git a/troposphere/emr.py b/troposphere/emr.py index 4b7aa0202..d319e6746 100644 --- a/troposphere/emr.py +++ b/troposphere/emr.py @@ -27,8 +27,8 @@ def validate_action_on_failure(action_on_failure): class KeyValue(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True) + 'Key': (str, True), + 'Value': (str, True) } def __init__(self, key=None, value=None, **kwargs): @@ -47,10 +47,10 @@ def additional_info_validator(xs): if not isinstance(xs, dict): raise ValueError("AdditionalInfo must be a dict of " "string to string pairs") - for k, v in xs.iteritems(): - if not isinstance(k, basestring): + for k, v in xs.items(): + if not isinstance(k, str): raise ValueError('AdditionalInfo keys must be strings') - if not isinstance(v, basestring): + if not isinstance(v, str): raise ValueError('AdditionalInfo values must be strings') return xs @@ -60,7 +60,7 @@ class SecurityConfiguration(AWSObject): resource_type = "AWS::EMR::SecurityConfiguration" props = { - 'Name': (basestring, False), + 'Name': (str, False), 'SecurityConfiguration': (dict, True) } @@ -68,22 +68,22 @@ class SecurityConfiguration(AWSObject): class Application(AWSProperty): props = { 'AdditionalInfo': (additional_info_validator, False), - 'Args': ([basestring], False), - 'Name': (basestring, False), - 'Version': (basestring, False) + 'Args': ([str], False), + 'Name': (str, False), + 'Version': (str, False) } class ScriptBootstrapActionConfig(AWSProperty): props = { - 'Args': ([basestring], False), - 'Path': (basestring, True) + 'Args': ([str], False), + 'Path': (str, True) } class BootstrapActionConfig(AWSProperty): props = { - 'Name': (basestring, True), + 'Name': (str, True), 'ScriptBootstrapAction': (ScriptBootstrapActionConfig, True) } @@ -92,10 +92,10 @@ def properties_validator(xs): if not isinstance(xs, dict): raise ValueError("ConfigurationProperties must be a dict of " "string to string pairs") - for k, v in xs.iteritems(): - if not isinstance(k, basestring): + for k, v in xs.items(): + if not isinstance(k, str): raise ValueError('ConfigurationProperties keys must be strings') - if not isinstance(v, basestring) and not isinstance(v, AWSHelperFn): + if not isinstance(v, str) and not isinstance(v, AWSHelperFn): raise ValueError('ConfigurationProperties values must be strings' ' or helper functions') @@ -104,7 +104,7 @@ def properties_validator(xs): class Configuration(AWSProperty): props = { - 'Classification': (basestring, False), + 'Classification': (str, False), 'ConfigurationProperties': (properties_validator, False) } @@ -161,15 +161,15 @@ class ScalingConstraints(AWSProperty): class CloudWatchAlarmDefinition(AWSProperty): props = { - 'ComparisonOperator': (basestring, True), + 'ComparisonOperator': (str, True), 'Dimensions': ([MetricDimension], False), 'EvaluationPeriods': (positive_integer, False), - 'MetricName': (basestring, True), - 'Namespace': (basestring, False), + 'MetricName': (str, True), + 'Namespace': (str, False), 'Period': (positive_integer, True), - 'Statistic': (basestring, False), + 'Statistic': (str, False), 'Threshold': (positive_integer, True), - 'Unit': (basestring, False), + 'Unit': (str, False), } @@ -181,7 +181,7 @@ class ScalingTrigger(AWSProperty): class SimpleScalingPolicyConfiguration(AWSProperty): props = { - 'AdjustmentType': (basestring, False), + 'AdjustmentType': (str, False), 'CoolDown': (positive_integer, False), 'ScalingAdjustment': (defer, True), } @@ -234,8 +234,8 @@ class ScalingAction(AWSProperty): class ScalingRule(AWSProperty): props = { 'Action': (ScalingAction, True), - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Trigger': (ScalingTrigger, True), } @@ -250,19 +250,19 @@ class AutoScalingPolicy(AWSProperty): class InstanceGroupConfigProperty(AWSProperty): props = { 'AutoScalingPolicy': (AutoScalingPolicy, False), - 'BidPrice': (basestring, False), + 'BidPrice': (str, False), 'Configurations': ([Configuration], False), 'EbsConfiguration': (EbsConfiguration, False), 'InstanceCount': (positive_integer, True), - 'InstanceType': (basestring, True), + 'InstanceType': (str, True), 'Market': (market_validator, False), - 'Name': (basestring, False), + 'Name': (str, False), } class OnDemandProvisioningSpecification(AWSProperty): props = { - 'AllocationStrategy': (basestring, True), + 'AllocationStrategy': (str, True), } def validate(self): @@ -278,9 +278,9 @@ def validate(self): class SpotProvisioningSpecification(AWSProperty): props = { - 'AllocationStrategy': (basestring, False), + 'AllocationStrategy': (str, False), 'BlockDurationMinutes': (positive_integer, False), - 'TimeoutAction': (basestring, True), + 'TimeoutAction': (str, True), 'TimeoutDurationMinutes': (positive_integer, True), } @@ -306,11 +306,11 @@ class InstanceFleetProvisioningSpecifications(AWSProperty): class InstanceTypeConfig(AWSProperty): props = { - 'BidPrice': (basestring, False), - 'BidPriceAsPercentageOfOnDemandPrice': (basestring, False), + 'BidPrice': (str, False), + 'BidPriceAsPercentageOfOnDemandPrice': (str, False), 'Configurations': ([Configuration], False), 'EbsConfiguration': (EbsConfiguration, False), - 'InstanceType': (basestring, True), + 'InstanceType': (str, True), 'WeightedCapacity': (positive_integer, False), } @@ -320,7 +320,7 @@ class InstanceFleetConfigProperty(AWSProperty): 'InstanceTypeConfigs': ([InstanceTypeConfig], False), 'LaunchSpecifications': (InstanceFleetProvisioningSpecifications, False), - 'Name': (basestring, False), + 'Name': (str, False), 'TargetOnDemandCapacity': (positive_integer, False), 'TargetSpotCapacity': (positive_integer, False), } @@ -328,38 +328,38 @@ class InstanceFleetConfigProperty(AWSProperty): class PlacementType(AWSProperty): props = { - 'AvailabilityZone': (basestring, True) + 'AvailabilityZone': (str, True) } class JobFlowInstancesConfig(AWSProperty): props = { - 'AdditionalMasterSecurityGroups': ([basestring], False), - 'AdditionalSlaveSecurityGroups': ([basestring], False), + 'AdditionalMasterSecurityGroups': ([str], False), + 'AdditionalSlaveSecurityGroups': ([str], False), 'CoreInstanceFleet': (InstanceFleetConfigProperty, False), 'CoreInstanceGroup': (InstanceGroupConfigProperty, False), - 'Ec2KeyName': (basestring, False), - 'Ec2SubnetId': (basestring, False), - 'Ec2SubnetIds': ([basestring], False), - 'EmrManagedMasterSecurityGroup': (basestring, False), - 'EmrManagedSlaveSecurityGroup': (basestring, False), - 'HadoopVersion': (basestring, False), + 'Ec2KeyName': (str, False), + 'Ec2SubnetId': (str, False), + 'Ec2SubnetIds': ([str], False), + 'EmrManagedMasterSecurityGroup': (str, False), + 'EmrManagedSlaveSecurityGroup': (str, False), + 'HadoopVersion': (str, False), 'KeepJobFlowAliveWhenNoSteps': (boolean, False), 'MasterInstanceFleet': (InstanceFleetConfigProperty, False), 'MasterInstanceGroup': (InstanceGroupConfigProperty, False), 'Placement': (PlacementType, False), - 'ServiceAccessSecurityGroup': (basestring, False), + 'ServiceAccessSecurityGroup': (str, False), 'TerminationProtected': (boolean, False) } class KerberosAttributes(AWSProperty): props = { - 'ADDomainJoinPassword': (basestring, False), - 'ADDomainJoinUser': (basestring, False), - 'CrossRealmTrustPrincipalPassword': (basestring, False), - 'KdcAdminPassword': (basestring, True), - 'Realm': (basestring, True), + 'ADDomainJoinPassword': (str, False), + 'ADDomainJoinUser': (str, False), + 'CrossRealmTrustPrincipalPassword': (str, False), + 'KdcAdminPassword': (str, True), + 'Realm': (str, True), } @@ -369,7 +369,7 @@ class ComputeLimits(AWSProperty): 'MaximumCoreCapacityUnits': (integer, False), 'MaximumOnDemandCapacityUnits': (integer, False), 'MinimumCapacityUnits': (integer, True), - 'UnitType': (basestring, True), + 'UnitType': (str, True), } @@ -381,9 +381,9 @@ class ManagedScalingPolicy(AWSProperty): class HadoopJarStepConfig(AWSProperty): props = { - 'Args': ([basestring], False), - 'Jar': (basestring, True), - 'MainClass': (basestring, False), + 'Args': ([str], False), + 'Jar': (str, True), + 'MainClass': (str, False), 'StepProperties': ([KeyValue], False) } @@ -392,7 +392,7 @@ class StepConfig(AWSProperty): props = { 'ActionOnFailure': (validate_action_on_failure, False), 'HadoopJarStep': (HadoopJarStepConfig, True), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -402,22 +402,22 @@ class Cluster(AWSObject): props = { 'AdditionalInfo': (dict, False), 'Applications': ([Application], False), - 'AutoScalingRole': (basestring, False), + 'AutoScalingRole': (str, False), 'BootstrapActions': ([BootstrapActionConfig], False), 'Configurations': ([Configuration], False), - 'CustomAmiId': (basestring, False), + 'CustomAmiId': (str, False), 'EbsRootVolumeSize': (positive_integer, False), 'Instances': (JobFlowInstancesConfig, True), - 'JobFlowRole': (basestring, True), + 'JobFlowRole': (str, True), 'KerberosAttributes': (KerberosAttributes, False), - 'LogEncryptionKmsKeyId': (basestring, False), - 'LogUri': (basestring, False), + 'LogEncryptionKmsKeyId': (str, False), + 'LogUri': (str, False), 'ManagedScalingPolicy': (ManagedScalingPolicy, False), - 'Name': (basestring, True), - 'ReleaseLabel': (basestring, False), - 'ScaleDownBehavior': (basestring, False), - 'SecurityConfiguration': (basestring, False), - 'ServiceRole': (basestring, True), + 'Name': (str, True), + 'ReleaseLabel': (str, False), + 'ScaleDownBehavior': (str, False), + 'SecurityConfiguration': (str, False), + 'ServiceRole': (str, True), 'StepConcurrencyLevel': (integer, False), 'Steps': ([StepConfig], False), 'Tags': ((Tags, list), False), @@ -429,12 +429,12 @@ class InstanceFleetConfig(AWSObject): resource_type = "AWS::EMR::InstanceFleetConfig" props = { - 'ClusterId': (basestring, True), - 'InstanceFleetType': (basestring, True), + 'ClusterId': (str, True), + 'InstanceFleetType': (str, True), 'InstanceTypeConfigs': ([InstanceTypeConfig], False), 'LaunchSpecifications': (InstanceFleetProvisioningSpecifications, False), - 'Name': (basestring, False), + 'Name': (str, False), 'TargetOnDemandCapacity': (positive_integer, False), 'TargetSpotCapacity': (positive_integer, False), } @@ -445,15 +445,15 @@ class InstanceGroupConfig(AWSObject): props = { 'AutoScalingPolicy': (AutoScalingPolicy, False), - 'BidPrice': (basestring, False), + 'BidPrice': (str, False), 'Configurations': ([Configuration], False), 'EbsConfiguration': (EbsConfiguration, False), 'InstanceCount': (integer, True), - 'InstanceRole': (basestring, True), - 'InstanceType': (basestring, True), - 'JobFlowId': (basestring, True), + 'InstanceRole': (str, True), + 'InstanceType': (str, True), + 'JobFlowId': (str, True), 'Market': (market_validator, False), - 'Name': (basestring, False) + 'Name': (str, False) } @@ -471,8 +471,8 @@ class Step(AWSObject): props = { 'ActionOnFailure': (action_on_failure_validator, True), 'HadoopJarStep': (HadoopJarStepConfig, True), - 'JobFlowId': (basestring, True), - 'Name': (basestring, True) + 'JobFlowId': (str, True), + 'Name': (str, True) } @@ -480,17 +480,17 @@ class Studio(AWSObject): resource_type = "AWS::EMR::Studio" props = { - 'AuthMode': (basestring, True), - 'DefaultS3Location': (basestring, True), - 'Description': (basestring, False), - 'EngineSecurityGroupId': (basestring, True), - 'Name': (basestring, True), - 'ServiceRole': (basestring, True), - 'SubnetIds': ([basestring], True), + 'AuthMode': (str, True), + 'DefaultS3Location': (str, True), + 'Description': (str, False), + 'EngineSecurityGroupId': (str, True), + 'Name': (str, True), + 'ServiceRole': (str, True), + 'SubnetIds': ([str], True), 'Tags': (Tags, False), - 'UserRole': (basestring, True), - 'VpcId': (basestring, True), - 'WorkspaceSecurityGroupId': (basestring, True), + 'UserRole': (str, True), + 'VpcId': (str, True), + 'WorkspaceSecurityGroupId': (str, True), } @@ -498,8 +498,8 @@ class StudioSessionMapping(AWSObject): resource_type = "AWS::EMR::StudioSessionMapping" props = { - 'IdentityName': (basestring, True), - 'IdentityType': (basestring, True), - 'SessionPolicyArn': (basestring, True), - 'StudioId': (basestring, True), + 'IdentityName': (str, True), + 'IdentityType': (str, True), + 'SessionPolicyArn': (str, True), + 'StudioId': (str, True), } diff --git a/troposphere/emrcontainers.py b/troposphere/emrcontainers.py index bc6d6ec3a..cf7b6c769 100644 --- a/troposphere/emrcontainers.py +++ b/troposphere/emrcontainers.py @@ -14,7 +14,7 @@ class EksInfo(AWSProperty): props = { - 'Namespace': (basestring, True), + 'Namespace': (str, True), } @@ -26,9 +26,9 @@ class ContainerInfo(AWSProperty): class ContainerProvider(AWSProperty): props = { - 'Id': (basestring, True), + 'Id': (str, True), 'Info': (ContainerInfo, True), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -37,6 +37,6 @@ class VirtualCluster(AWSObject): props = { 'ContainerProvider': (ContainerProvider, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/events.py b/troposphere/events.py index b92e9feb0..92913fc4a 100644 --- a/troposphere/events.py +++ b/troposphere/events.py @@ -17,12 +17,12 @@ class ApiDestination(AWSObject): resource_type = "AWS::Events::ApiDestination" props = { - 'ConnectionArn': (basestring, True), - 'Description': (basestring, False), - 'HttpMethod': (basestring, True), - 'InvocationEndpoint': (basestring, True), + 'ConnectionArn': (str, True), + 'Description': (str, False), + 'HttpMethod': (str, True), + 'InvocationEndpoint': (str, True), 'InvocationRateLimitPerSecond': (integer, False), - 'Name': (basestring, False), + 'Name': (str, False), } @@ -30,11 +30,11 @@ class Archive(AWSObject): resource_type = "AWS::Events::Archive" props = { - 'ArchiveName': (basestring, False), - 'Description': (basestring, False), + 'ArchiveName': (str, False), + 'Description': (str, False), 'EventPattern': (dict, False), 'RetentionDays': (integer, False), - 'SourceArn': (basestring, True), + 'SourceArn': (str, True), } @@ -43,9 +43,9 @@ class Connection(AWSObject): props = { 'AuthParameters': (dict, True), - 'AuthorizationType': (basestring, True), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'AuthorizationType': (str, True), + 'Description': (str, False), + 'Name': (str, False), } @@ -53,16 +53,16 @@ class EventBus(AWSObject): resource_type = "AWS::Events::EventBus" props = { - 'EventSourceName': (basestring, False), - 'Name': (basestring, True), + 'EventSourceName': (str, False), + 'Name': (str, True), } class Condition(AWSProperty): props = { - 'Key': (basestring, False), - 'Type': (basestring, False), - 'Value': (basestring, False), + 'Key': (str, False), + 'Type': (str, False), + 'Value': (str, False), } @@ -70,12 +70,12 @@ class EventBusPolicy(AWSObject): resource_type = "AWS::Events::EventBusPolicy" props = { - 'Action': (basestring, False), + 'Action': (str, False), 'Condition': (Condition, False), - 'EventBusName': (basestring, False), - 'Principal': (basestring, False), + 'EventBusName': (str, False), + 'Principal': (str, False), 'Statement': (dict, False), - 'StatementId': (basestring, True), + 'StatementId': (str, True), } @@ -94,23 +94,23 @@ class BatchRetryStrategy(AWSProperty): class BatchParameters(AWSProperty): props = { 'ArrayProperties': (BatchArrayProperties, False), - 'JobDefinition': (basestring, True), - 'JobName': (basestring, True), + 'JobDefinition': (str, True), + 'JobName': (str, True), 'RetryStrategy': (BatchRetryStrategy, False), } class DeadLetterConfig(AWSProperty): props = { - 'Arn': (basestring, False), + 'Arn': (str, False), } class AwsVpcConfiguration(AWSProperty): props = { - 'AssignPublicIp': (basestring, False), - 'SecurityGroups': ([basestring], False), - 'Subnets': ([basestring], True), + 'AssignPublicIp': (str, False), + 'SecurityGroups': ([str], False), + 'Subnets': ([str], True), } @@ -122,19 +122,19 @@ class NetworkConfiguration(AWSProperty): class EcsParameters(AWSProperty): props = { - 'Group': (basestring, False), - 'LaunchType': (basestring, False), + 'Group': (str, False), + 'LaunchType': (str, False), 'NetworkConfiguration': (NetworkConfiguration, False), - 'PlatformVersion': (basestring, False), + 'PlatformVersion': (str, False), 'TaskCount': (integer, False), - 'TaskDefinitionArn': (basestring, True), + 'TaskDefinitionArn': (str, True), } class HttpParameters(AWSProperty): props = { 'HeaderParameters': (dict, False), - 'PathParameterValues': ([basestring], False), + 'PathParameterValues': ([str], False), 'QueryStringParameters': (dict, False), } @@ -142,23 +142,23 @@ class HttpParameters(AWSProperty): class InputTransformer(AWSProperty): props = { 'InputPathsMap': (dict, False), - 'InputTemplate': (basestring, True), + 'InputTemplate': (str, True), } class KinesisParameters(AWSProperty): props = { - 'PartitionKeyPath': (basestring, True), + 'PartitionKeyPath': (str, True), } class RedshiftDataParameters(AWSProperty): props = { - 'Database': (basestring, True), - 'DbUser': (basestring, False), - 'SecretManagerArn': (basestring, False), - 'Sql': (basestring, True), - 'StatementName': (basestring, False), + 'Database': (str, True), + 'DbUser': (str, False), + 'SecretManagerArn': (str, False), + 'Sql': (str, True), + 'StatementName': (str, False), 'WithEvent': (boolean, False), } @@ -172,8 +172,8 @@ class RetryPolicy(AWSProperty): class RunCommandTarget(AWSProperty): props = { - 'Key': (basestring, True), - 'Values': ([basestring], True), + 'Key': (str, True), + 'Values': ([str], True), } @@ -185,25 +185,25 @@ class RunCommandParameters(AWSProperty): class SqsParameters(AWSProperty): props = { - 'MessageGroupId': (basestring, True), + 'MessageGroupId': (str, True), } class Target(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'BatchParameters': (BatchParameters, False), 'DeadLetterConfig': (DeadLetterConfig, False), 'EcsParameters': (EcsParameters, False), 'HttpParameters': (HttpParameters, False), - 'Id': (basestring, True), - 'Input': (basestring, False), - 'InputPath': (basestring, False), + 'Id': (str, True), + 'Input': (str, False), + 'InputPath': (str, False), 'InputTransformer': (InputTransformer, False), 'KinesisParameters': (KinesisParameters, False), 'RedshiftDataParameters': (RedshiftDataParameters, False), 'RetryPolicy': (RetryPolicy, False), - 'RoleArn': (basestring, False), + 'RoleArn': (str, False), 'RunCommandParameters': (RunCommandParameters, False), 'SqsParameters': (SqsParameters, False), } @@ -213,12 +213,12 @@ class Rule(AWSObject): resource_type = "AWS::Events::Rule" props = { - 'Description': (basestring, False), - 'EventBusName': (basestring, False), + 'Description': (str, False), + 'EventBusName': (str, False), 'EventPattern': (dict, False), - 'Name': (basestring, False), - 'RoleArn': (basestring, False), - 'ScheduleExpression': (basestring, False), - 'State': (basestring, False), + 'Name': (str, False), + 'RoleArn': (str, False), + 'ScheduleExpression': (str, False), + 'State': (str, False), 'Targets': ([Target], False), } diff --git a/troposphere/eventschemas.py b/troposphere/eventschemas.py index 43f7f1190..97f15cf94 100644 --- a/troposphere/eventschemas.py +++ b/troposphere/eventschemas.py @@ -15,8 +15,8 @@ class Discoverer(AWSObject): resource_type = "AWS::EventSchemas::Discoverer" props = { - 'Description': (basestring, False), - 'SourceArn': (basestring, True), + 'Description': (str, False), + 'SourceArn': (str, True), 'Tags': (Tags, False), } @@ -25,8 +25,8 @@ class Registry(AWSObject): resource_type = "AWS::EventSchemas::Registry" props = { - 'Description': (basestring, False), - 'RegistryName': (basestring, False), + 'Description': (str, False), + 'RegistryName': (str, False), 'Tags': (Tags, False), } @@ -36,8 +36,8 @@ class RegistryPolicy(AWSObject): props = { 'Policy': (dict, True), - 'RegistryName': (basestring, True), - 'RevisionId': (basestring, False), + 'RegistryName': (str, True), + 'RevisionId': (str, False), } @@ -45,10 +45,10 @@ class Schema(AWSObject): resource_type = "AWS::EventSchemas::Schema" props = { - 'Content': (basestring, True), - 'Description': (basestring, False), - 'RegistryName': (basestring, True), - 'SchemaName': (basestring, False), + 'Content': (str, True), + 'Description': (str, False), + 'RegistryName': (str, True), + 'SchemaName': (str, False), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } diff --git a/troposphere/firehose.py b/troposphere/firehose.py index 46a4efb72..4065940d4 100644 --- a/troposphere/firehose.py +++ b/troposphere/firehose.py @@ -56,16 +56,16 @@ class BufferingHints(AWSProperty): class DeliveryStreamEncryptionConfigurationInput(AWSProperty): props = { - 'KeyARN': (basestring, False), - 'KeyType': (basestring, True), + 'KeyARN': (str, False), + 'KeyType': (str, True), } class CloudWatchLoggingOptions(AWSProperty): props = { 'Enabled': (boolean, False), - 'LogGroupName': (basestring, False), # Conditional - 'LogStreamName': (basestring, False), # Conditional + 'LogGroupName': (str, False), # Conditional + 'LogStreamName': (str, False), # Conditional } @@ -77,41 +77,41 @@ class RetryOptions(AWSProperty): class KMSEncryptionConfig(AWSProperty): props = { - 'AWSKMSKeyARN': (basestring, True), + 'AWSKMSKeyARN': (str, True), } class EncryptionConfiguration(AWSProperty): props = { 'KMSEncryptionConfig': (KMSEncryptionConfig, False), - 'NoEncryptionConfig': (basestring, False), + 'NoEncryptionConfig': (str, False), } class S3Configuration(AWSProperty): props = { - 'BucketARN': (basestring, True), + 'BucketARN': (str, True), 'BufferingHints': (BufferingHints, True), 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), - 'CompressionFormat': (basestring, True), + 'CompressionFormat': (str, True), 'EncryptionConfiguration': (EncryptionConfiguration, False), - 'Prefix': (basestring, False), - 'RoleARN': (basestring, True) + 'Prefix': (str, False), + 'RoleARN': (str, True) } class CopyCommand(AWSProperty): props = { - 'CopyOptions': (basestring, False), - 'DataTableColumns': (basestring, False), - 'DataTableName': (basestring, True), + 'CopyOptions': (str, False), + 'DataTableColumns': (str, False), + 'DataTableName': (str, True), } class ProcessorParameter(AWSProperty): props = { - 'ParameterName': (basestring, True), - 'ParameterValue': (basestring, True), + 'ParameterName': (str, True), + 'ParameterValue': (str, True), } @@ -131,9 +131,9 @@ class ProcessingConfiguration(AWSProperty): class VpcConfiguration(AWSProperty): props = { - 'RoleARN': (basestring, True), - 'SecurityGroupIds': ([basestring], True), - 'SubnetIds': ([basestring], True), + 'RoleARN': (str, True), + 'SecurityGroupIds': ([str], True), + 'SubnetIds': ([str], True), } @@ -141,16 +141,16 @@ class ElasticsearchDestinationConfiguration(AWSProperty): props = { 'BufferingHints': (BufferingHints, True), 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), - 'ClusterEndpoint': (basestring, False), - 'DomainARN': (basestring, True), - 'IndexName': (basestring, True), + 'ClusterEndpoint': (str, False), + 'DomainARN': (str, True), + 'IndexName': (str, True), 'IndexRotationPeriod': (index_rotation_period_validator, True), 'ProcessingConfiguration': (ProcessingConfiguration, False), 'RetryOptions': (RetryOptions, False), - 'RoleARN': (basestring, True), + 'RoleARN': (str, True), 'S3BackupMode': (s3_backup_mode_elastic_search_validator, True), 'S3Configuration': (S3Configuration, False), - 'TypeName': (basestring, False), + 'TypeName': (str, False), 'VpcConfiguration': (VpcConfiguration, False), } @@ -158,32 +158,32 @@ class ElasticsearchDestinationConfiguration(AWSProperty): class RedshiftDestinationConfiguration(AWSProperty): props = { 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), - 'ClusterJDBCURL': (basestring, True), + 'ClusterJDBCURL': (str, True), 'CopyCommand': (CopyCommand, True), - 'Password': (basestring, True), + 'Password': (str, True), 'ProcessingConfiguration': (ProcessingConfiguration, False), - 'RoleARN': (basestring, True), + 'RoleARN': (str, True), 'S3Configuration': (S3Configuration, True), - 'Username': (basestring, True), + 'Username': (str, True), } class S3DestinationConfiguration(AWSProperty): props = { - 'BucketARN': (basestring, True), + 'BucketARN': (str, True), 'BufferingHints': (BufferingHints, False), 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), - 'CompressionFormat': (basestring, False), + 'CompressionFormat': (str, False), 'EncryptionConfiguration': (EncryptionConfiguration, False), - 'ErrorOutputPrefix': (basestring, False), - 'Prefix': (basestring, False), - 'RoleARN': (basestring, True), + 'ErrorOutputPrefix': (str, False), + 'Prefix': (str, False), + 'RoleARN': (str, True), } class HiveJsonSerDe(AWSProperty): props = { - 'TimestampFormats': ([basestring], False), + 'TimestampFormats': ([str], False), } @@ -211,12 +211,12 @@ class InputFormatConfiguration(AWSProperty): class OrcSerDe(AWSProperty): props = { 'BlockSizeBytes': (integer, False), - 'BloomFilterColumns': ([basestring], False), + 'BloomFilterColumns': ([str], False), 'BloomFilterFalsePositiveProbability': (float, False), - 'Compression': (basestring, False), + 'Compression': (str, False), 'DictionaryKeyThreshold': (float, False), 'EnablePadding': (boolean, False), - 'FormatVersion': (basestring, False), + 'FormatVersion': (str, False), 'PaddingTolerance': (float, False), 'RowIndexStride': (integer, False), 'StripeSizeBytes': (integer, False), @@ -226,11 +226,11 @@ class OrcSerDe(AWSProperty): class ParquetSerDe(AWSProperty): props = { 'BlockSizeBytes': (integer, False), - 'Compression': (basestring, False), + 'Compression': (str, False), 'EnableDictionaryCompression': (boolean, False), 'MaxPaddingBytes': (integer, False), 'PageSizeBytes': (integer, False), - 'WriterVersion': (basestring, False), + 'WriterVersion': (str, False), } @@ -249,12 +249,12 @@ class OutputFormatConfiguration(AWSProperty): class SchemaConfiguration(AWSProperty): props = { - 'CatalogId': (basestring, True), - 'DatabaseName': (basestring, True), - 'Region': (basestring, True), - 'RoleARN': (basestring, True), - 'TableName': (basestring, True), - 'VersionId': (basestring, True), + 'CatalogId': (str, True), + 'DatabaseName': (str, True), + 'Region': (str, True), + 'RoleARN': (str, True), + 'TableName': (str, True), + 'VersionId': (str, True), } @@ -269,17 +269,17 @@ class DataFormatConversionConfiguration(AWSProperty): class ExtendedS3DestinationConfiguration(AWSProperty): props = { - 'BucketARN': (basestring, True), + 'BucketARN': (str, True), 'BufferingHints': (BufferingHints, False), 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), - 'CompressionFormat': (basestring, False), + 'CompressionFormat': (str, False), 'DataFormatConversionConfiguration': (DataFormatConversionConfiguration, False), 'EncryptionConfiguration': (EncryptionConfiguration, False), - 'ErrorOutputPrefix': (basestring, False), - 'Prefix': (basestring, False), + 'ErrorOutputPrefix': (str, False), + 'Prefix': (str, False), 'ProcessingConfiguration': (ProcessingConfiguration, False), - 'RoleARN': (basestring, True), + 'RoleARN': (str, True), 'S3BackupConfiguration': (S3DestinationConfiguration, False), 'S3BackupMode': (s3_backup_mode_extended_s3_validator, False), } @@ -287,8 +287,8 @@ class ExtendedS3DestinationConfiguration(AWSProperty): class KinesisStreamSourceConfiguration(AWSProperty): props = { - 'KinesisStreamARN': (basestring, True), - 'RoleARN': (basestring, True) + 'KinesisStreamARN': (str, True), + 'RoleARN': (str, True) } @@ -302,12 +302,12 @@ class SplunkDestinationConfiguration(AWSProperty): props = { 'CloudWatchLoggingOptions': (CloudWatchLoggingOptions, False), 'HECAcknowledgmentTimeoutInSeconds': (positive_integer, False), - 'HECEndpoint': (basestring, True), - 'HECEndpointType': (basestring, True), - 'HECToken': (basestring, True), + 'HECEndpoint': (str, True), + 'HECEndpointType': (str, True), + 'HECToken': (str, True), 'ProcessingConfiguration': (ProcessingConfiguration, False), 'RetryOptions': (SplunkRetryOptions, False), - 'S3BackupMode': (basestring, False), + 'S3BackupMode': (str, False), 'S3Configuration': (S3DestinationConfiguration, True), } @@ -318,7 +318,7 @@ class DeliveryStream(AWSObject): props = { 'DeliveryStreamEncryptionConfigurationInput': (DeliveryStreamEncryptionConfigurationInput, False), - 'DeliveryStreamName': (basestring, False), + 'DeliveryStreamName': (str, False), 'DeliveryStreamType': (delivery_stream_type_validator, False), 'ElasticsearchDestinationConfiguration': (ElasticsearchDestinationConfiguration, False), # noqa 'ExtendedS3DestinationConfiguration': (ExtendedS3DestinationConfiguration, False), # noqa diff --git a/troposphere/fis.py b/troposphere/fis.py index 61ca88207..3cb9c380f 100644 --- a/troposphere/fis.py +++ b/troposphere/fis.py @@ -13,8 +13,8 @@ class ExperimentTemplateStopCondition(AWSProperty): props = { - 'source': (basestring, True), - 'value': (basestring, False), + 'source': (str, True), + 'value': (str, False), } @@ -23,8 +23,8 @@ class ExperimentTemplate(AWSObject): props = { 'actions': (dict, False), - 'description': (basestring, True), - 'roleArn': (basestring, True), + 'description': (str, True), + 'roleArn': (str, True), 'stopConditions': ([ExperimentTemplateStopCondition], True), 'tags': (dict, True), 'targets': (dict, True), diff --git a/troposphere/fms.py b/troposphere/fms.py index 858683608..dd50fe806 100644 --- a/troposphere/fms.py +++ b/troposphere/fms.py @@ -10,8 +10,8 @@ class IEMap(AWSProperty): props = { - 'ACCOUNT': ([basestring], False), - 'ORGUNIT': ([basestring], False), + 'ACCOUNT': ([str], False), + 'ORGUNIT': ([str], False), } @@ -23,11 +23,11 @@ class Policy(AWSObject): 'ExcludeMap': (IEMap, False), 'ExcludeResourceTags': (boolean, True), 'IncludeMap': (IEMap, False), - 'PolicyName': (basestring, True), + 'PolicyName': (str, True), 'RemediationEnabled': (boolean, True), 'ResourceTags': (Tags, False), - 'ResourceType': (basestring, True), - 'ResourceTypeList': ([basestring], True), + 'ResourceType': (str, True), + 'ResourceTypeList': ([str], True), 'SecurityServicePolicyData': (json_checker, True), 'Tags': (Tags, False), } @@ -37,6 +37,6 @@ class NotificationChannel(AWSObject): resource_type = "AWS::FMS::NotificationChannel" props = { - 'SnsRoleName': (basestring, True), - 'SnsTopicArn': (basestring, True), + 'SnsRoleName': (str, True), + 'SnsTopicArn': (str, True), } diff --git a/troposphere/fsx.py b/troposphere/fsx.py index 221e4259e..bce1e3cbb 100644 --- a/troposphere/fsx.py +++ b/troposphere/fsx.py @@ -33,44 +33,44 @@ def validate_lustreconfiguration_perunitstoragethroughput(lustreconfiguration_pe class LustreConfiguration(AWSProperty): props = { - 'AutoImportPolicy': (basestring, False), + 'AutoImportPolicy': (str, False), 'AutomaticBackupRetentionDays': (integer, False), 'CopyTagsToBackups': (boolean, False), - 'DailyAutomaticBackupStartTime': (basestring, False), + 'DailyAutomaticBackupStartTime': (str, False), 'DeploymentType': (validate_lustreconfiguration_deploymenttype, False), - 'DriveCacheType': (basestring, False), - 'ExportPath': (basestring, False), + 'DriveCacheType': (str, False), + 'ExportPath': (str, False), 'ImportedFileChunkSize': (integer, False), - 'ImportPath': (basestring, False), + 'ImportPath': (str, False), 'PerUnitStorageThroughput': (validate_lustreconfiguration_perunitstoragethroughput, False), # NOQA - 'WeeklyMaintenanceStartTime': (basestring, False), + 'WeeklyMaintenanceStartTime': (str, False), } class SelfManagedActiveDirectoryConfiguration(AWSProperty): props = { - 'DnsIps': ([basestring], False), - 'DomainName': (basestring, False), - 'FileSystemAdministratorsGroup': (basestring, False), - 'OrganizationalUnitDistinguishedName': (basestring, False), - 'Password': (basestring, False), - 'UserName': (basestring, False), + 'DnsIps': ([str], False), + 'DomainName': (str, False), + 'FileSystemAdministratorsGroup': (str, False), + 'OrganizationalUnitDistinguishedName': (str, False), + 'Password': (str, False), + 'UserName': (str, False), } class WindowsConfiguration(AWSProperty): props = { - 'ActiveDirectoryId': (basestring, False), - 'Aliases': ([basestring], False), + 'ActiveDirectoryId': (str, False), + 'Aliases': ([str], False), 'AutomaticBackupRetentionDays': (integer, False), 'CopyTagsToBackups': (boolean, False), - 'DailyAutomaticBackupStartTime': (basestring, False), - 'DeploymentType': (basestring, False), - 'PreferredSubnetId': (basestring, False), + 'DailyAutomaticBackupStartTime': (str, False), + 'DeploymentType': (str, False), + 'PreferredSubnetId': (str, False), 'SelfManagedActiveDirectoryConfiguration': (SelfManagedActiveDirectoryConfiguration, False), 'ThroughputCapacity': (integer, True), - 'WeeklyMaintenanceStartTime': (basestring, False), + 'WeeklyMaintenanceStartTime': (str, False), } @@ -78,14 +78,14 @@ class FileSystem(AWSObject): resource_type = 'AWS::FSx::FileSystem' props = { - 'BackupId': (basestring, False), - 'FileSystemType': (basestring, False), - 'KmsKeyId': (basestring, False), + 'BackupId': (str, False), + 'FileSystemType': (str, False), + 'KmsKeyId': (str, False), 'LustreConfiguration': (LustreConfiguration, False), - 'SecurityGroupIds': ([basestring], False), + 'SecurityGroupIds': ([str], False), 'StorageCapacity': (integer, False), 'StorageType': (storage_type, False), - 'SubnetIds': ([basestring], False), + 'SubnetIds': ([str], False), 'Tags': (Tags, False), 'WindowsConfiguration': (WindowsConfiguration, False), } diff --git a/troposphere/gamelift.py b/troposphere/gamelift.py index f01a04f0c..400a9980c 100644 --- a/troposphere/gamelift.py +++ b/troposphere/gamelift.py @@ -17,9 +17,9 @@ class RoutingStrategy(AWSProperty): props = { - 'FleetId': (basestring, False), - 'Message': (basestring, False), - 'Type': (basestring, False), + 'FleetId': (str, False), + 'Message': (str, False), + 'Type': (str, False), } @@ -27,18 +27,18 @@ class Alias(AWSObject): resource_type = "AWS::GameLift::Alias" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'RoutingStrategy': (RoutingStrategy, True), } class S3Location(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, True), - 'ObjectVersion': (basestring, False), - 'RoleArn': (basestring, True), + 'Bucket': (str, True), + 'Key': (str, True), + 'ObjectVersion': (str, False), + 'RoleArn': (str, True), } @@ -46,24 +46,24 @@ class Build(AWSObject): resource_type = "AWS::GameLift::Build" props = { - 'Name': (basestring, False), - 'OperatingSystem': (basestring, False), + 'Name': (str, False), + 'OperatingSystem': (str, False), 'StorageLocation': (S3Location, False), - 'Version': (basestring, False), + 'Version': (str, False), } class CertificateConfiguration(AWSProperty): props = { - 'CertificateType': (basestring, True), + 'CertificateType': (str, True), } class IpPermission(AWSProperty): props = { 'FromPort': (integer, True), - 'IpRange': (basestring, True), - 'Protocol': (basestring, True), + 'IpRange': (str, True), + 'Protocol': (str, True), 'ToPort': (integer, True), } @@ -78,8 +78,8 @@ class ResourceCreationLimitPolicy(AWSProperty): class ServerProcess(AWSProperty): props = { 'ConcurrentExecutions': (integer, True), - 'LaunchPath': (basestring, True), - 'Parameters': (basestring, False), + 'LaunchPath': (str, True), + 'Parameters': (str, False), } @@ -95,27 +95,27 @@ class Fleet(AWSObject): resource_type = "AWS::GameLift::Fleet" props = { - 'BuildId': (basestring, False), + 'BuildId': (str, False), 'CertificateConfiguration': (CertificateConfiguration, False), - 'Description': (basestring, False), + 'Description': (str, False), 'DesiredEC2Instances': (integer, False), 'EC2InboundPermissions': ([IpPermission], False), - 'EC2InstanceType': (basestring, True), - 'FleetType': (basestring, False), - 'InstanceRoleARN': (basestring, False), - 'LogPaths': ([basestring], False), + 'EC2InstanceType': (str, True), + 'FleetType': (str, False), + 'InstanceRoleARN': (str, False), + 'LogPaths': ([str], False), 'MaxSize': (integer, False), - 'MetricGroups': ([basestring], False), + 'MetricGroups': ([str], False), 'MinSize': (integer, False), - 'Name': (basestring, True), - 'NewGameSessionProtectionPolicy': (basestring, False), - 'PeerVpcAwsAccountId': (basestring, False), - 'PeerVpcId': (basestring, False), + 'Name': (str, True), + 'NewGameSessionProtectionPolicy': (str, False), + 'PeerVpcAwsAccountId': (str, False), + 'PeerVpcId': (str, False), 'ResourceCreationLimitPolicy': (ResourceCreationLimitPolicy, False), 'RuntimeConfiguration': (RuntimeConfiguration, False), - 'ScriptId': (basestring, False), - 'ServerLaunchParameters': (basestring, False), - 'ServerLaunchPath': (basestring, False), + 'ScriptId': (str, False), + 'ServerLaunchParameters': (str, False), + 'ServerLaunchPath': (str, False), } @@ -134,16 +134,16 @@ class AutoScalingPolicy(AWSProperty): class InstanceDefinition(AWSProperty): props = { - 'InstanceType': (basestring, True), - 'WeightedCapacity': (basestring, False), + 'InstanceType': (str, True), + 'WeightedCapacity': (str, False), } class LaunchTemplate(AWSProperty): props = { - 'LaunchTemplateId': (basestring, False), - 'LaunchTemplateName': (basestring, False), - 'Version': (basestring, False), + 'LaunchTemplateId': (str, False), + 'LaunchTemplateName': (str, False), + 'Version': (str, False), } @@ -152,23 +152,23 @@ class GameServerGroup(AWSObject): props = { 'AutoScalingPolicy': (AutoScalingPolicy, False), - 'BalancingStrategy': (basestring, False), - 'DeleteOption': (basestring, False), - 'GameServerGroupName': (basestring, True), - 'GameServerProtectionPolicy': (basestring, False), + 'BalancingStrategy': (str, False), + 'DeleteOption': (str, False), + 'GameServerGroupName': (str, True), + 'GameServerProtectionPolicy': (str, False), 'InstanceDefinitions': ([InstanceDefinition], True), 'LaunchTemplate': (LaunchTemplate, True), 'MaxSize': (double, False), 'MinSize': (double, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), - 'VpcSubnets': ([basestring], False), + 'VpcSubnets': ([str], False), } class Destination(AWSProperty): props = { - 'DestinationArn': (basestring, False), + 'DestinationArn': (str, False), } @@ -184,7 +184,7 @@ class GameSessionQueue(AWSObject): props = { 'Destinations': ([Destination], False), - 'Name': (basestring, True), + 'Name': (str, True), 'PlayerLatencyPolicies': ([PlayerLatencyPolicy], False), 'TimeoutInSeconds': (integer, False), } @@ -192,8 +192,8 @@ class GameSessionQueue(AWSObject): class GameProperty(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -204,17 +204,17 @@ class MatchmakingConfiguration(AWSObject): 'AcceptanceRequired': (boolean, True), 'AcceptanceTimeoutSeconds': (integer, False), 'AdditionalPlayerCount': (integer, False), - 'BackfillMode': (basestring, False), - 'CustomEventData': (basestring, False), - 'Description': (basestring, False), - 'FlexMatchMode': (basestring, False), + 'BackfillMode': (str, False), + 'CustomEventData': (str, False), + 'Description': (str, False), + 'FlexMatchMode': (str, False), 'GameProperties': ([GameProperty], False), - 'GameSessionData': (basestring, False), - 'GameSessionQueueArns': ([basestring], False), - 'Name': (basestring, True), - 'NotificationTarget': (basestring, False), + 'GameSessionData': (str, False), + 'GameSessionQueueArns': ([str], False), + 'Name': (str, True), + 'NotificationTarget': (str, False), 'RequestTimeoutSeconds': (integer, True), - 'RuleSetName': (basestring, True), + 'RuleSetName': (str, True), } @@ -222,8 +222,8 @@ class MatchmakingRuleSet(AWSObject): resource_type = "AWS::GameLift::MatchmakingRuleSet" props = { - 'Name': (basestring, True), - 'RuleSetBody': (basestring, True), + 'Name': (str, True), + 'RuleSetBody': (str, True), } @@ -231,7 +231,7 @@ class Script(AWSObject): resource_type = "AWS::GameLift::Script" props = { - 'Name': (basestring, False), + 'Name': (str, False), 'StorageLocation': (S3Location, True), - 'Version': (basestring, False), + 'Version': (str, False), } diff --git a/troposphere/globalaccelerator.py b/troposphere/globalaccelerator.py index 4b75f2297..32869cdd1 100644 --- a/troposphere/globalaccelerator.py +++ b/troposphere/globalaccelerator.py @@ -16,9 +16,9 @@ class Accelerator(AWSObject): props = { 'Enabled': (boolean, False), - 'IpAddresses': ([basestring], False), + 'IpAddresses': ([str], False), 'IpAddressType': (accelerator_ipaddresstype, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -34,7 +34,7 @@ class Listener(AWSObject): resource_type = "AWS::GlobalAccelerator::Listener" props = { - 'AcceleratorArn': (basestring, True), + 'AcceleratorArn': (str, True), 'ClientAffinity': (listener_clientaffinity, False), 'PortRanges': ([PortRange], True), 'Protocol': (listener_protocol, False), @@ -44,7 +44,7 @@ class Listener(AWSObject): class EndpointConfiguration(AWSProperty): props = { 'ClientIPPreservationEnabled': (boolean, False), - 'EndpointId': (basestring, True), + 'EndpointId': (str, True), 'Weight': (integer, False), } @@ -54,12 +54,12 @@ class EndpointGroup(AWSObject): props = { 'EndpointConfigurations': ([EndpointConfiguration], False), - 'EndpointGroupRegion': (basestring, True), + 'EndpointGroupRegion': (str, True), 'HealthCheckIntervalSeconds': (integer, False), - 'HealthCheckPath': (basestring, False), + 'HealthCheckPath': (str, False), 'HealthCheckPort': (integer, False), 'HealthCheckProtocol': (endpointgroup_healthcheckprotocol, False), - 'ListenerArn': (basestring, True), + 'ListenerArn': (str, True), 'ThresholdCount': (integer, False), 'TrafficDialPercentage': (double, False), } diff --git a/troposphere/glue.py b/troposphere/glue.py index 85bb573c3..d0bc189d7 100644 --- a/troposphere/glue.py +++ b/troposphere/glue.py @@ -11,36 +11,36 @@ class CsvClassifier(AWSProperty): props = { 'AllowSingleColumn': (boolean, False), - 'ContainsHeader': (basestring, False), - 'Delimiter': (basestring, False), + 'ContainsHeader': (str, False), + 'Delimiter': (str, False), 'DisableValueTrimming': (boolean, False), - 'Header': ([basestring], False), - 'Name': (basestring, False), - 'QuoteSymbol': (basestring, False), + 'Header': ([str], False), + 'Name': (str, False), + 'QuoteSymbol': (str, False), } class GrokClassifier(AWSProperty): props = { - 'Classification': (basestring, True), - 'CustomPatterns': (basestring, False), - 'GrokPattern': (basestring, True), - 'Name': (basestring, False), + 'Classification': (str, True), + 'CustomPatterns': (str, False), + 'GrokPattern': (str, True), + 'Name': (str, False), } class JsonClassifier(AWSProperty): props = { - 'JsonPath': (basestring, True), - 'Name': (basestring, False), + 'JsonPath': (str, True), + 'Name': (str, False), } class XMLClassifier(AWSProperty): props = { - 'Classification': (basestring, True), - 'Name': (basestring, False), - 'RowTag': (basestring, True), + 'Classification': (str, True), + 'Name': (str, False), + 'RowTag': (str, True), } @@ -57,9 +57,9 @@ class Classifier(AWSObject): class PhysicalConnectionRequirements(AWSProperty): props = { - 'AvailabilityZone': (basestring, False), - 'SecurityGroupIdList': ([basestring], False), - 'SubnetId': (basestring, False), + 'AvailabilityZone': (str, False), + 'SecurityGroupIdList': ([str], False), + 'SubnetId': (str, False), } @@ -82,9 +82,9 @@ class ConnectionInput(AWSProperty): props = { 'ConnectionProperties': (dict, True), 'ConnectionType': (connection_type_validator, True), - 'Description': (basestring, False), - 'MatchCriteria': ([basestring], False), - 'Name': (basestring, False), + 'Description': (str, False), + 'MatchCriteria': ([str], False), + 'Name': (str, False), 'PhysicalConnectionRequirements': (PhysicalConnectionRequirements, False), } @@ -94,14 +94,14 @@ class Connection(AWSObject): resource_type = "AWS::Glue::Connection" props = { - 'CatalogId': (basestring, True), + 'CatalogId': (str, True), 'ConnectionInput': (ConnectionInput, True), } class Schedule(AWSProperty): props = { - 'ScheduleExpression': (basestring, False), + 'ScheduleExpression': (str, False), } @@ -135,29 +135,29 @@ class SchemaChangePolicy(AWSProperty): class CatalogTarget(AWSProperty): props = { - 'DatabaseName': (basestring, False), - 'Tables': ([basestring], False), + 'DatabaseName': (str, False), + 'Tables': ([str], False), } class DynamoDBTarget(AWSProperty): props = { - 'Path': (basestring, False), + 'Path': (str, False), } class JdbcTarget(AWSProperty): props = { - 'ConnectionName': (basestring, False), - 'Exclusions': ([basestring], False), - 'Path': (basestring, False), + 'ConnectionName': (str, False), + 'Exclusions': ([str], False), + 'Path': (str, False), } class S3Target(AWSProperty): props = { - 'Exclusions': ([basestring], False), - 'Path': (basestring, False), + 'Exclusions': ([str], False), + 'Path': (str, False), } @@ -174,16 +174,16 @@ class Crawler(AWSObject): resource_type = "AWS::Glue::Crawler" props = { - 'Classifiers': ([basestring], False), - 'Configuration': (basestring, False), - 'CrawlerSecurityConfiguration': (basestring, False), - 'DatabaseName': (basestring, True), - 'Description': (basestring, False), - 'Name': (basestring, False), - 'Role': (basestring, True), + 'Classifiers': ([str], False), + 'Configuration': (str, False), + 'CrawlerSecurityConfiguration': (str, False), + 'DatabaseName': (str, True), + 'Description': (str, False), + 'Name': (str, False), + 'Role': (str, True), 'Schedule': (Schedule, False), 'SchemaChangePolicy': (SchemaChangePolicy, False), - 'TablePrefix': (basestring, False), + 'TablePrefix': (str, False), 'Tags': (dict, False), 'Targets': (Targets, True), } @@ -191,15 +191,15 @@ class Crawler(AWSObject): class ConnectionPasswordEncryption(AWSProperty): props = { - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'ReturnConnectionPasswordEncrypted': (boolean, False), } class EncryptionAtRest(AWSProperty): props = { - 'CatalogEncryptionMode': (basestring, False), - 'SseAwsKmsKeyId': (basestring, False), + 'CatalogEncryptionMode': (str, False), + 'SseAwsKmsKeyId': (str, False), } @@ -215,7 +215,7 @@ class DataCatalogEncryptionSettings(AWSObject): resource_type = "AWS::Glue::DataCatalogEncryptionSettings" props = { - 'CatalogId': (basestring, True), + 'CatalogId': (str, True), 'DataCatalogEncryptionSettings': (DataCatalogEncryptionSettingsProperty, True), } @@ -223,9 +223,9 @@ class DataCatalogEncryptionSettings(AWSObject): class DatabaseInput(AWSProperty): props = { - 'Description': (basestring, False), - 'LocationUri': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'LocationUri': (str, False), + 'Name': (str, False), 'Parameters': (dict, False), } @@ -234,7 +234,7 @@ class Database(AWSObject): resource_type = "AWS::Glue::Database" props = { - 'CatalogId': (basestring, True), + 'CatalogId': (str, True), 'DatabaseInput': (DatabaseInput, True), } @@ -244,26 +244,26 @@ class DevEndpoint(AWSObject): props = { 'Arguments': (dict, False), - 'EndpointName': (basestring, False), - 'ExtraJarsS3Path': (basestring, False), - 'ExtraPythonLibsS3Path': (basestring, False), - 'GlueVersion': (basestring, False), + 'EndpointName': (str, False), + 'ExtraJarsS3Path': (str, False), + 'ExtraPythonLibsS3Path': (str, False), + 'GlueVersion': (str, False), 'NumberOfNodes': (integer, False), 'NumberOfWorkers': (integer, False), - 'PublicKey': (basestring, False), - 'PublicKeys': ([basestring], False), - 'RoleArn': (basestring, True), - 'SecurityConfiguration': (basestring, False), - 'SecurityGroupIds': ([basestring], False), - 'SubnetId': (basestring, False), + 'PublicKey': (str, False), + 'PublicKeys': ([str], False), + 'RoleArn': (str, True), + 'SecurityConfiguration': (str, False), + 'SecurityGroupIds': ([str], False), + 'SubnetId': (str, False), 'Tags': (dict, False), - 'WorkerType': (basestring, False), + 'WorkerType': (str, False), } class ConnectionsList(AWSProperty): props = { - 'Connections': ([basestring], False), + 'Connections': ([str], False), } @@ -275,9 +275,9 @@ class ExecutionProperty(AWSProperty): class JobCommand(AWSProperty): props = { - 'Name': (basestring, False), - 'PythonVersion': (basestring, False), - 'ScriptLocation': (basestring, False), + 'Name': (str, False), + 'PythonVersion': (str, False), + 'ScriptLocation': (str, False), } @@ -295,29 +295,29 @@ class Job(AWSObject): 'Command': (JobCommand, True), 'Connections': (ConnectionsList, False), 'DefaultArguments': (dict, False), - 'Description': (basestring, False), + 'Description': (str, False), 'ExecutionProperty': (ExecutionProperty, False), - 'GlueVersion': (basestring, False), - 'LogUri': (basestring, False), + 'GlueVersion': (str, False), + 'LogUri': (str, False), 'MaxCapacity': (double, False), 'MaxRetries': (double, False), - 'Name': (basestring, False), + 'Name': (str, False), 'NotificationProperty': (NotificationProperty, False), 'NumberOfWorkers': (integer, False), - 'Role': (basestring, True), - 'SecurityConfiguration': (basestring, False), + 'Role': (str, True), + 'SecurityConfiguration': (str, False), 'Tags': (dict, False), 'Timeout': (integer, False), - 'WorkerType': (basestring, False), + 'WorkerType': (str, False), } class GlueTables(AWSProperty): props = { - 'CatalogId': (basestring, False), - 'ConnectionName': (basestring, False), - 'DatabaseName': (basestring, True), - 'TableName': (basestring, True), + 'CatalogId': (str, False), + 'ConnectionName': (str, False), + 'DatabaseName': (str, True), + 'TableName': (str, True), } @@ -332,14 +332,14 @@ class FindMatchesParameters(AWSProperty): 'AccuracyCostTradeoff': (float, False), 'EnforceProvidedLabels': (boolean, False), 'PrecisionRecallTradeoff': (float, False), - 'PrimaryKeyColumnName': (basestring, True), + 'PrimaryKeyColumnName': (str, True), } class TransformParameters(AWSProperty): props = { 'FindMatchesParameters': (FindMatchesParameters, False), - 'TransformType': (basestring, True), + 'TransformType': (str, True), } @@ -347,61 +347,61 @@ class MLTransform(AWSObject): resource_type = "AWS::Glue::MLTransform" props = { - 'Description': (basestring, False), - 'GlueVersion': (basestring, False), + 'Description': (str, False), + 'GlueVersion': (str, False), 'InputRecordTables': (InputRecordTables, True), 'MaxCapacity': (double, False), 'MaxRetries': (integer, False), - 'Name': (basestring, False), + 'Name': (str, False), 'NumberOfWorkers': (integer, False), - 'Role': (basestring, True), + 'Role': (str, True), 'Tags': (dict, False), 'Timeout': (integer, False), 'TransformParameters': (TransformParameters, True), - 'WorkerType': (basestring, False), + 'WorkerType': (str, False), } class Column(AWSProperty): props = { - 'Comment': (basestring, False), - 'Name': (basestring, True), - 'Type': (basestring, False), + 'Comment': (str, False), + 'Name': (str, True), + 'Type': (str, False), } class Order(AWSProperty): props = { - 'Column': (basestring, True), + 'Column': (str, True), 'SortOrder': (integer_range(0, 1), False), } class SerdeInfo(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), 'Parameters': (dict, False), - 'SerializationLibrary': (basestring, False), + 'SerializationLibrary': (str, False), } class SkewedInfo(AWSProperty): props = { - 'SkewedColumnNames': ([basestring], False), - 'SkewedColumnValues': ([basestring], False), + 'SkewedColumnNames': ([str], False), + 'SkewedColumnValues': ([str], False), 'SkewedColumnValueLocationMaps': (dict, False), } class StorageDescriptor(AWSProperty): props = { - 'BucketColumns': ([basestring], False), + 'BucketColumns': ([str], False), 'Columns': ([Column], False), 'Compressed': (boolean, False), - 'InputFormat': (basestring, False), - 'Location': (basestring, False), + 'InputFormat': (str, False), + 'Location': (str, False), 'NumberOfBuckets': (positive_integer, False), - 'OutputFormat': (basestring, False), + 'OutputFormat': (str, False), 'Parameters': (dict, False), 'SerdeInfo': (SerdeInfo, False), 'SkewedInfo': (SkewedInfo, False), @@ -414,7 +414,7 @@ class PartitionInput(AWSProperty): props = { 'Parameters': (dict, False), 'StorageDescriptor': (StorageDescriptor, False), - 'Values': ([basestring], True), + 'Values': ([str], True), } @@ -422,10 +422,10 @@ class Partition(AWSObject): resource_type = "AWS::Glue::Partition" props = { - 'CatalogId': (basestring, True), - 'DatabaseName': (basestring, True), + 'CatalogId': (str, True), + 'DatabaseName': (str, True), 'PartitionInput': (PartitionInput, True), - 'TableName': (basestring, True), + 'TableName': (str, True), } @@ -433,8 +433,8 @@ class Registry(AWSObject): resource_type = "AWS::Glue::Registry" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -451,12 +451,12 @@ class Schema(AWSObject): props = { 'CheckpointVersion': (SchemaVersion, False), - 'Compatibility': (basestring, True), - 'DataFormat': (basestring, True), - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Compatibility': (str, True), + 'DataFormat': (str, True), + 'Description': (str, False), + 'Name': (str, True), 'Registry': (Registry, False), - 'SchemaDefinition': (basestring, True), + 'SchemaDefinition': (str, True), 'Tags': (Tags, False), } @@ -465,30 +465,30 @@ class SchemaVersionMetadata(AWSObject): resource_type = "AWS::Glue::SchemaVersionMetadata" props = { - 'Key': (basestring, True), - 'SchemaVersionId': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'SchemaVersionId': (str, True), + 'Value': (str, True), } class CloudWatchEncryption(AWSProperty): props = { - 'CloudWatchEncryptionMode': (basestring, False), - 'KmsKeyArn': (basestring, False), + 'CloudWatchEncryptionMode': (str, False), + 'KmsKeyArn': (str, False), } class JobBookmarksEncryption(AWSProperty): props = { - 'JobBookmarksEncryptionMode': (basestring, False), - 'KmsKeyArn': (basestring, False), + 'JobBookmarksEncryptionMode': (str, False), + 'KmsKeyArn': (str, False), } class S3Encryption(AWSProperty): props = { - 'KmsKeyArn': (basestring, False), - 'S3EncryptionMode': (basestring, False), + 'KmsKeyArn': (str, False), + 'S3EncryptionMode': (str, False), } @@ -505,7 +505,7 @@ class SecurityConfiguration(AWSObject): props = { 'EncryptionConfiguration': (EncryptionConfiguration, True), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -521,16 +521,16 @@ def table_type_validator(type): class TableInput(AWSProperty): props = { - 'Description': (basestring, False), - 'Name': (basestring, False), - 'Owner': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), + 'Owner': (str, False), 'Parameters': (dict, False), 'PartitionKeys': ([Column], False), 'Retention': (positive_integer, False), 'StorageDescriptor': (StorageDescriptor, False), 'TableType': (table_type_validator, False), - 'ViewExpandedText': (basestring, False), - 'ViewOriginalText': (basestring, False), + 'ViewExpandedText': (str, False), + 'ViewOriginalText': (str, False), } @@ -538,8 +538,8 @@ class Table(AWSObject): resource_type = "AWS::Glue::Table" props = { - 'CatalogId': (basestring, True), - 'DatabaseName': (basestring, True), + 'CatalogId': (str, True), + 'DatabaseName': (str, True), 'TableInput': (TableInput, True), } @@ -547,26 +547,26 @@ class Table(AWSObject): class Action(AWSProperty): props = { 'Arguments': (dict, False), - 'CrawlerName': (basestring, False), - 'JobName': (basestring, False), - 'SecurityConfiguration': (basestring, False), + 'CrawlerName': (str, False), + 'JobName': (str, False), + 'SecurityConfiguration': (str, False), } class Condition(AWSProperty): props = { - 'CrawlerName': (basestring, False), - 'CrawlState': (basestring, False), - 'JobName': (basestring, False), - 'LogicalOperator': (basestring, False), - 'State': (basestring, False), + 'CrawlerName': (str, False), + 'CrawlState': (str, False), + 'JobName': (str, False), + 'LogicalOperator': (str, False), + 'State': (str, False), } class Predicate(AWSProperty): props = { 'Conditions': ([Condition], False), - 'Logical': (basestring, False), + 'Logical': (str, False), } @@ -586,14 +586,14 @@ class Trigger(AWSObject): props = { 'Actions': ([Action], True), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), 'Predicate': (Predicate, False), - 'Schedule': (basestring, False), + 'Schedule': (str, False), 'StartOnCreation': (boolean, False), 'Tags': (dict, False), - 'Type': (basestring, True), - 'WorkflowName': (basestring, False), + 'Type': (str, True), + 'WorkflowName': (str, False), } @@ -602,7 +602,7 @@ class Workflow(AWSObject): props = { 'DefaultRunProperties': (dict, False), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), 'Tags': (dict, False), } diff --git a/troposphere/greengrass.py b/troposphere/greengrass.py index 7a7f63bab..24826499a 100644 --- a/troposphere/greengrass.py +++ b/troposphere/greengrass.py @@ -11,8 +11,8 @@ class Connector(AWSProperty): props = { - 'ConnectorArn': (basestring, True), - 'Id': (basestring, True), + 'ConnectorArn': (str, True), + 'Id': (str, True), 'Parameters': (dict, False), } @@ -28,7 +28,7 @@ class ConnectorDefinition(AWSObject): props = { 'InitialVersion': (ConnectorDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -37,17 +37,17 @@ class ConnectorDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::ConnectorDefinitionVersion" props = { - 'ConnectorDefinitionId': (basestring, True), + 'ConnectorDefinitionId': (str, True), 'Connectors': ([Connector], True), } class Core(AWSProperty): props = { - 'CertificateArn': (basestring, True), - 'Id': (basestring, True), + 'CertificateArn': (str, True), + 'Id': (str, True), 'SyncShadow': (boolean, False), - 'ThingArn': (basestring, True), + 'ThingArn': (str, True), } @@ -62,7 +62,7 @@ class CoreDefinition(AWSObject): props = { 'InitialVersion': (CoreDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -71,17 +71,17 @@ class CoreDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::CoreDefinitionVersion" props = { - 'CoreDefinitionId': (basestring, True), + 'CoreDefinitionId': (str, True), 'Cores': ([Core], True), } class Device(AWSProperty): props = { - 'CertificateArn': (basestring, True), - 'Id': (basestring, True), + 'CertificateArn': (str, True), + 'Id': (str, True), 'SyncShadow': (boolean, False), - 'ThingArn': (basestring, True), + 'ThingArn': (str, True), } @@ -96,7 +96,7 @@ class DeviceDefinition(AWSObject): props = { 'InitialVersion': (DeviceDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -105,7 +105,7 @@ class DeviceDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::DeviceDefinitionVersion" props = { - 'DeviceDefinitionId': (basestring, True), + 'DeviceDefinitionId': (str, True), 'Devices': ([Device], True), } @@ -119,7 +119,7 @@ class RunAs(AWSProperty): class Execution(AWSProperty): props = { - 'IsolationMode': (basestring, False), + 'IsolationMode': (str, False), 'RunAs': (RunAs, False), } @@ -132,8 +132,8 @@ class DefaultConfig(AWSProperty): class ResourceAccessPolicy(AWSProperty): props = { - 'Permission': (basestring, False), - 'ResourceId': (basestring, True), + 'Permission': (str, False), + 'ResourceId': (str, True), } @@ -148,10 +148,10 @@ class Environment(AWSProperty): class FunctionConfiguration(AWSProperty): props = { - 'EncodingType': (basestring, False), + 'EncodingType': (str, False), 'Environment': (Environment, False), - 'ExecArgs': (basestring, False), - 'Executable': (basestring, False), + 'ExecArgs': (str, False), + 'Executable': (str, False), 'MemorySize': (integer, False), 'Pinned': (boolean, False), 'Timeout': (integer, False), @@ -160,9 +160,9 @@ class FunctionConfiguration(AWSProperty): class Function(AWSProperty): props = { - 'FunctionArn': (basestring, True), + 'FunctionArn': (str, True), 'FunctionConfiguration': (FunctionConfiguration, True), - 'Id': (basestring, True), + 'Id': (str, True), } @@ -178,7 +178,7 @@ class FunctionDefinition(AWSObject): props = { 'InitialVersion': (FunctionDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -188,20 +188,20 @@ class FunctionDefinitionVersion(AWSObject): props = { 'DefaultConfig': (DefaultConfig, False), - 'FunctionDefinitionId': (basestring, True), + 'FunctionDefinitionId': (str, True), 'Functions': ([Function], True), } class GroupVersion(AWSProperty): props = { - 'ConnectorDefinitionVersionArn': (basestring, False), - 'CoreDefinitionVersionArn': (basestring, False), - 'DeviceDefinitionVersionArn': (basestring, False), - 'FunctionDefinitionVersionArn': (basestring, False), - 'LoggerDefinitionVersionArn': (basestring, False), - 'ResourceDefinitionVersionArn': (basestring, False), - 'SubscriptionDefinitionVersionArn': (basestring, False), + 'ConnectorDefinitionVersionArn': (str, False), + 'CoreDefinitionVersionArn': (str, False), + 'DeviceDefinitionVersionArn': (str, False), + 'FunctionDefinitionVersionArn': (str, False), + 'LoggerDefinitionVersionArn': (str, False), + 'ResourceDefinitionVersionArn': (str, False), + 'SubscriptionDefinitionVersionArn': (str, False), } @@ -210,8 +210,8 @@ class Group(AWSObject): props = { 'InitialVersion': (GroupVersion, False), - 'Name': (basestring, True), - 'RoleArn': (basestring, False), + 'Name': (str, True), + 'RoleArn': (str, False), 'Tags': (dict, False), } @@ -220,24 +220,24 @@ class GroupVersion(AWSObject): resource_type = "AWS::Greengrass::GroupVersion" props = { - 'ConnectorDefinitionVersionArn': (basestring, False), - 'CoreDefinitionVersionArn': (basestring, False), - 'DeviceDefinitionVersionArn': (basestring, False), - 'FunctionDefinitionVersionArn': (basestring, False), - 'GroupId': (basestring, True), - 'LoggerDefinitionVersionArn': (basestring, False), - 'ResourceDefinitionVersionArn': (basestring, False), - 'SubscriptionDefinitionVersionArn': (basestring, False), + 'ConnectorDefinitionVersionArn': (str, False), + 'CoreDefinitionVersionArn': (str, False), + 'DeviceDefinitionVersionArn': (str, False), + 'FunctionDefinitionVersionArn': (str, False), + 'GroupId': (str, True), + 'LoggerDefinitionVersionArn': (str, False), + 'ResourceDefinitionVersionArn': (str, False), + 'SubscriptionDefinitionVersionArn': (str, False), } class Logger(AWSProperty): props = { - 'Component': (basestring, True), - 'Id': (basestring, True), - 'Level': (basestring, True), + 'Component': (str, True), + 'Id': (str, True), + 'Level': (str, True), 'Space': (integer, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -252,7 +252,7 @@ class LoggerDefinition(AWSObject): props = { 'InitialVersion': (LoggerDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -261,7 +261,7 @@ class LoggerDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::LoggerDefinitionVersion" props = { - 'LoggerDefinitionId': (basestring, True), + 'LoggerDefinitionId': (str, True), 'Loggers': ([Logger], True), } @@ -269,52 +269,52 @@ class LoggerDefinitionVersion(AWSObject): class GroupOwnerSetting(AWSProperty): props = { 'AutoAddGroupOwner': (boolean, True), - 'GroupOwner': (basestring, False), + 'GroupOwner': (str, False), } class LocalDeviceResourceData(AWSProperty): props = { 'GroupOwnerSetting': (GroupOwnerSetting, False), - 'SourcePath': (basestring, True), + 'SourcePath': (str, True), } class LocalVolumeResourceData(AWSProperty): props = { - 'DestinationPath': (basestring, True), + 'DestinationPath': (str, True), 'GroupOwnerSetting': (GroupOwnerSetting, False), - 'SourcePath': (basestring, True), + 'SourcePath': (str, True), } class ResourceDownloadOwnerSetting(AWSProperty): props = { - 'GroupOwner': (basestring, True), - 'GroupPermission': (basestring, True), + 'GroupOwner': (str, True), + 'GroupPermission': (str, True), } class S3MachineLearningModelResourceData(AWSProperty): props = { - 'DestinationPath': (basestring, True), + 'DestinationPath': (str, True), 'OwnerSetting': (ResourceDownloadOwnerSetting, False), - 'S3Uri': (basestring, True), + 'S3Uri': (str, True), } class SageMakerMachineLearningModelResourceData(AWSProperty): props = { - 'DestinationPath': (basestring, True), + 'DestinationPath': (str, True), 'OwnerSetting': (ResourceDownloadOwnerSetting, False), - 'SageMakerJobArn': (basestring, True), + 'SageMakerJobArn': (str, True), } class SecretsManagerSecretResourceData(AWSProperty): props = { - 'ARN': (basestring, True), - 'AdditionalStagingLabelsToDownload': ([basestring], False), + 'ARN': (str, True), + 'AdditionalStagingLabelsToDownload': ([str], False), } @@ -333,8 +333,8 @@ class ResourceDataContainer(AWSProperty): class ResourceInstance(AWSProperty): props = { - 'Id': (basestring, True), - 'Name': (basestring, True), + 'Id': (str, True), + 'Name': (str, True), 'ResourceDataContainer': (ResourceDataContainer, True), } @@ -350,7 +350,7 @@ class ResourceDefinition(AWSObject): props = { 'InitialVersion': (ResourceDefinitionVersion, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -359,17 +359,17 @@ class ResourceDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::ResourceDefinitionVersion" props = { - 'ResourceDefinitionId': (basestring, True), + 'ResourceDefinitionId': (str, True), 'Resources': ([ResourceInstance], True), } class Subscription(AWSProperty): props = { - 'Id': (basestring, True), - 'Source': (basestring, True), - 'Subject': (basestring, True), - 'Target': (basestring, True), + 'Id': (str, True), + 'Source': (str, True), + 'Subject': (str, True), + 'Target': (str, True), } @@ -384,7 +384,7 @@ class SubscriptionDefinition(AWSObject): props = { 'InitialVersion': (SubscriptionDefinitionVersionProperty, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -393,6 +393,6 @@ class SubscriptionDefinitionVersion(AWSObject): resource_type = "AWS::Greengrass::SubscriptionDefinitionVersion" props = { - 'SubscriptionDefinitionId': (basestring, True), + 'SubscriptionDefinitionId': (str, True), 'Subscriptions': ([Subscription], True), } diff --git a/troposphere/greengrassv2.py b/troposphere/greengrassv2.py index a15a5f9bf..89b57d1b2 100644 --- a/troposphere/greengrassv2.py +++ b/troposphere/greengrassv2.py @@ -17,31 +17,31 @@ class ComponentPlatform(AWSProperty): props = { 'Attributes': (dict, False), - 'Name': (basestring, False), + 'Name': (str, False), } class LambdaEventSource(AWSProperty): props = { - 'Topic': (basestring, False), - 'Type': (basestring, False), + 'Topic': (str, False), + 'Type': (str, False), } class LambdaDeviceMount(AWSProperty): props = { 'AddGroupOwner': (boolean, False), - 'Path': (basestring, False), - 'Permission': (basestring, False), + 'Path': (str, False), + 'Permission': (str, False), } class LambdaVolumeMount(AWSProperty): props = { 'AddGroupOwner': (boolean, False), - 'DestinationPath': (basestring, False), - 'Permission': (basestring, False), - 'SourcePath': (basestring, False), + 'DestinationPath': (str, False), + 'Permission': (str, False), + 'SourcePath': (str, False), } @@ -57,7 +57,7 @@ class LambdaContainerParams(AWSProperty): class LambdaLinuxProcessParams(AWSProperty): props = { 'ContainerParams': (LambdaContainerParams, False), - 'IsolationMode': (basestring, False), + 'IsolationMode': (str, False), } @@ -65,8 +65,8 @@ class LambdaExecutionParameters(AWSProperty): props = { 'EnvironmentVariables': (dict, False), 'EventSources': ([LambdaEventSource], False), - 'ExecArgs': ([basestring], False), - 'InputPayloadEncodingType': (basestring, False), + 'ExecArgs': ([str], False), + 'InputPayloadEncodingType': (str, False), 'LinuxProcessParams': (LambdaLinuxProcessParams, False), 'MaxIdleTimeInSeconds': (integer, False), 'MaxInstancesCount': (integer, False), @@ -81,10 +81,10 @@ class LambdaFunctionRecipeSource(AWSProperty): props = { 'ComponentDependencies': (dict, False), 'ComponentLambdaParameters': (LambdaExecutionParameters, False), - 'ComponentName': (basestring, False), + 'ComponentName': (str, False), 'ComponentPlatforms': ([ComponentPlatform], False), - 'ComponentVersion': (basestring, False), - 'LambdaArn': (basestring, False), + 'ComponentVersion': (str, False), + 'LambdaArn': (str, False), } @@ -92,7 +92,7 @@ class ComponentVersion(AWSObject): resource_type = "AWS::GreengrassV2::ComponentVersion" props = { - 'InlineRecipe': (basestring, False), + 'InlineRecipe': (str, False), 'LambdaFunction': (LambdaFunctionRecipeSource, False), 'Tags': (Tags, False), } diff --git a/troposphere/groundstation.py b/troposphere/groundstation.py index e16068d8d..0fc52a476 100644 --- a/troposphere/groundstation.py +++ b/troposphere/groundstation.py @@ -8,8 +8,8 @@ class DataflowEdge(AWSProperty): props = { - 'Destination': (basestring, True), - 'Source': (basestring, True), + 'Destination': (str, True), + 'Source': (str, True), } @@ -21,15 +21,15 @@ class MissionProfile(AWSObject): 'ContactPrePassDurationSeconds': (integer, False), 'DataflowEdges': ([DataflowEdge], True), 'MinimumViableContactDurationSeconds': (integer, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), - 'TrackingConfigArn': (basestring, True), + 'TrackingConfigArn': (str, True), } class SocketAddress(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), 'Port': (integer, False), } @@ -38,15 +38,15 @@ class DataflowEndpoint(AWSProperty): props = { 'Address': (SocketAddress, False), 'Mtu': (integer, False), - 'Name': (basestring, False), + 'Name': (str, False), } class SecurityDetails(AWSProperty): props = { - 'RoleArn': (basestring, False), - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], False), + 'RoleArn': (str, False), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], False), } @@ -71,14 +71,14 @@ class DemodulationConfig(AWSProperty): class Bandwidth(AWSProperty): props = { - 'Units': (basestring, True), + 'Units': (str, True), 'Value': (double, True), } class Frequency(AWSProperty): props = { - 'Units': (basestring, True), + 'Units': (str, True), 'Value': (double, True), } @@ -87,7 +87,7 @@ class SpectrumConfig(AWSProperty): props = { 'Bandwidth': (Bandwidth, True), 'CenterFrequency': (Frequency, True), - 'Polarization': (basestring, False), + 'Polarization': (str, False), } @@ -109,7 +109,7 @@ class SpectrumConfig(AWSProperty): props = { 'Bandwidth': (Bandwidth, True), 'CenterFrequency': (Frequency, True), - 'Polarization': (basestring, False), + 'Polarization': (str, False), } @@ -124,7 +124,7 @@ class DataflowEndpointGroup(AWSObject): class Eirp(AWSObject): props = { - 'Units': (basestring, True), + 'Units': (str, True), 'Value': (double, True), } @@ -138,20 +138,20 @@ class AntennaUplinkConfig(AWSObject): class DataflowEndpointConfig(AWSProperty): props = { - 'DataflowEndpointName': (basestring, True), - 'DataflowEndpointRegion': (basestring, False), + 'DataflowEndpointName': (str, True), + 'DataflowEndpointRegion': (str, False), } class TrackingConfig(AWSProperty): props = { - 'AutoTrack': (basestring, True), + 'AutoTrack': (str, True), } class UplinkEchoConfig(AWSProperty): props = { - 'AntennaUplinkConfigArn': (basestring, True), + 'AntennaUplinkConfigArn': (str, True), 'Enabled': (boolean, True), } @@ -172,6 +172,6 @@ class Config(AWSObject): props = { 'ConfigData': (ConfigData, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/guardduty.py b/troposphere/guardduty.py index b04f3afac..c91439cec 100644 --- a/troposphere/guardduty.py +++ b/troposphere/guardduty.py @@ -12,17 +12,17 @@ class Detector(AWSObject): props = { 'Enable': (boolean, True), - 'FindingPublishingFrequency': (basestring, False), + 'FindingPublishingFrequency': (str, False), } class Condition(AWSProperty): props = { - 'Eq': ([basestring], False), + 'Eq': ([str], False), 'Gte': (integer, False), 'Lt': (integer, False), 'Lte': (integer, False), - 'Neq': ([basestring], False), + 'Neq': ([str], False), } @@ -37,11 +37,11 @@ class Filter(AWSObject): resource_type = "AWS::GuardDuty::Filter" props = { - 'Action': (basestring, True), - 'Description': (basestring, True), - 'DetectorId': (basestring, True), + 'Action': (str, True), + 'Description': (str, True), + 'DetectorId': (str, True), 'FindingCriteria': (FindingCriteria, True), - 'Name': (basestring, False), + 'Name': (str, False), 'Rank': (integer, True), } @@ -51,10 +51,10 @@ class IPSet(AWSObject): props = { 'Activate': (boolean, True), - 'DetectorId': (basestring, True), - 'Format': (basestring, True), - 'Location': (basestring, True), - 'Name': (basestring, False), + 'DetectorId': (str, True), + 'Format': (str, True), + 'Location': (str, True), + 'Name': (str, False), } @@ -62,9 +62,9 @@ class Master(AWSObject): resource_type = "AWS::GuardDuty::Master" props = { - 'DetectorId': (basestring, True), - 'InvitationId': (basestring, False), - 'MasterId': (basestring, True), + 'DetectorId': (str, True), + 'InvitationId': (str, False), + 'MasterId': (str, True), } @@ -72,11 +72,11 @@ class Member(AWSObject): resource_type = "AWS::GuardDuty::Member" props = { - 'DetectorId': (basestring, True), - 'Email': (basestring, True), - 'MemberId': (basestring, True), - 'Message': (basestring, False), - 'Status': (basestring, False), + 'DetectorId': (str, True), + 'Email': (str, True), + 'MemberId': (str, True), + 'Message': (str, False), + 'Status': (str, False), 'DisableEmailNotification': (bool, False), } @@ -86,8 +86,8 @@ class ThreatIntelSet(AWSObject): props = { 'Activate': (boolean, True), - 'DetectorId': (basestring, True), - 'Format': (basestring, True), - 'Location': (basestring, True), - 'Name': (basestring, False), + 'DetectorId': (str, True), + 'Format': (str, True), + 'Location': (str, True), + 'Name': (str, False), } diff --git a/troposphere/iam.py b/troposphere/iam.py index 50653ad4b..bc5ee835d 100644 --- a/troposphere/iam.py +++ b/troposphere/iam.py @@ -18,7 +18,7 @@ class AccessKey(AWSObject): props = { 'Serial': (integer, False), 'Status': (status, False), - 'UserName': (basestring, True), + 'UserName': (str, True), } @@ -26,18 +26,18 @@ class PolicyType(AWSObject): resource_type = "AWS::IAM::Policy" props = { - 'Groups': ([basestring], False), + 'Groups': ([str], False), 'PolicyDocument': (policytypes, True), - 'PolicyName': (basestring, True), - 'Roles': ([basestring], False), - 'Users': ([basestring], False), + 'PolicyName': (str, True), + 'Roles': ([str], False), + 'Users': ([str], False), } class Policy(AWSProperty): props = { 'PolicyDocument': (policytypes, True), - 'PolicyName': (basestring, True), + 'PolicyName': (str, True), } @@ -49,7 +49,7 @@ class Group(AWSObject): props = { 'GroupName': (iam_group_name, False), - 'ManagedPolicyArns': ([basestring], False), + 'ManagedPolicyArns': ([str], False), 'Path': (iam_path, False), 'Policies': ([Policy], False), } @@ -59,7 +59,7 @@ class InstanceProfile(AWSObject): resource_type = "AWS::IAM::InstanceProfile" props = { - 'InstanceProfileName': (basestring, False), + 'InstanceProfileName': (str, False), 'Path': (iam_path, False), 'Roles': (list, True), } @@ -69,13 +69,13 @@ class ManagedPolicy(AWSObject): resource_type = "AWS::IAM::ManagedPolicy" props = { - 'Description': (basestring, False), - 'Groups': ([basestring], False), - 'ManagedPolicyName': (basestring, False), + 'Description': (str, False), + 'Groups': ([str], False), + 'ManagedPolicyName': (str, False), 'Path': (iam_path, False), 'PolicyDocument': (policytypes, True), - 'Roles': ([basestring], False), - 'Users': ([basestring], False), + 'Roles': ([str], False), + 'Users': ([str], False), } @@ -83,10 +83,10 @@ class OIDCProvider(AWSObject): resource_type = "AWS::IAM::OIDCProvider" props = { - 'ClientIdList': ([basestring], False), + 'ClientIdList': ([str], False), 'Tags': (Tags, False), - 'ThumbprintList': ([basestring], True), - 'Url': (basestring, False), + 'ThumbprintList': ([str], True), + 'Url': (str, False), } @@ -95,11 +95,11 @@ class Role(AWSObject): props = { 'AssumeRolePolicyDocument': (policytypes, True), - 'Description': (basestring, False), - 'ManagedPolicyArns': ([basestring], False), + 'Description': (str, False), + 'ManagedPolicyArns': ([str], False), 'MaxSessionDuration': (integer, False), 'Path': (iam_path, False), - 'PermissionsBoundary': (basestring, False), + 'PermissionsBoundary': (str, False), 'Policies': ([Policy], False), 'RoleName': (iam_role_name, False), 'Tags': ((Tags, list), False), @@ -110,8 +110,8 @@ class SAMLProvider(AWSObject): resource_type = "AWS::IAM::SAMLProvider" props = { - 'Name': (basestring, False), - 'SamlMetadataDocument': (basestring, True), + 'Name': (str, False), + 'SamlMetadataDocument': (str, True), 'Tags': (Tags, False), } @@ -120,11 +120,11 @@ class ServerCertificate(AWSObject): resource_type = "AWS::IAM::ServerCertificate" props = { - 'CertificateBody': (basestring, False), - 'CertificateChain': (basestring, False), - 'Path': (basestring, False), - 'PrivateKey': (basestring, False), - 'ServerCertificateName': (basestring, False), + 'CertificateBody': (str, False), + 'CertificateChain': (str, False), + 'Path': (str, False), + 'PrivateKey': (str, False), + 'ServerCertificateName': (str, False), 'Tags': (Tags, False), } @@ -133,15 +133,15 @@ class ServiceLinkedRole(AWSObject): resource_type = "AWS::IAM::ServiceLinkedRole" props = { - 'AWSServiceName': (basestring, True), - 'CustomSuffix': (basestring, False), - 'Description': (basestring, False), + 'AWSServiceName': (str, True), + 'CustomSuffix': (str, False), + 'Description': (str, False), } class LoginProfile(AWSProperty): props = { - 'Password': (basestring, True), + 'Password': (str, True), 'PasswordResetRequired': (boolean, False), } @@ -150,11 +150,11 @@ class User(AWSObject): resource_type = "AWS::IAM::User" props = { - 'Groups': ([basestring], False), + 'Groups': ([str], False), 'LoginProfile': (LoginProfile, False), - 'ManagedPolicyArns': ([basestring], False), + 'ManagedPolicyArns': ([str], False), 'Path': (iam_path, False), - 'PermissionsBoundary': (basestring, False), + 'PermissionsBoundary': (str, False), 'Policies': ([Policy], False), 'Tags': (Tags, False), 'UserName': (iam_user_name, False), @@ -165,7 +165,7 @@ class UserToGroupAddition(AWSObject): resource_type = "AWS::IAM::UserToGroupAddition" props = { - 'GroupName': (basestring, True), + 'GroupName': (str, True), 'Users': (list, True), } @@ -174,8 +174,8 @@ class VirtualMFADevice(AWSObject): resource_type = "AWS::IAM::VirtualMFADevice" props = { - 'Path': (basestring, False), + 'Path': (str, False), 'Tags': (Tags, False), - 'Users': ([basestring], True), - 'VirtualMfaDeviceName': (basestring, False), + 'Users': ([str], True), + 'VirtualMfaDeviceName': (str, False), } diff --git a/troposphere/imagebuilder.py b/troposphere/imagebuilder.py index df37d3405..2f9ac3faf 100644 --- a/troposphere/imagebuilder.py +++ b/troposphere/imagebuilder.py @@ -14,28 +14,28 @@ class Component(AWSObject): resource_type = "AWS::ImageBuilder::Component" props = { - 'ChangeDescription': (basestring, False), - 'Data': (basestring, False), - 'Description': (basestring, False), - 'KmsKeyId': (basestring, False), - 'Name': (basestring, True), + 'ChangeDescription': (str, False), + 'Data': (str, False), + 'Description': (str, False), + 'KmsKeyId': (str, False), + 'Name': (str, True), 'Platform': (component_platforms, True), 'Tags': (dict, False), - 'Uri': (basestring, False), - 'Version': (basestring, True), + 'Uri': (str, False), + 'Version': (str, True), } class ComponentConfiguration(AWSProperty): props = { - 'ComponentArn': (basestring, False), + 'ComponentArn': (str, False), } class TargetContainerRepository(AWSProperty): props = { - 'RepositoryName': (basestring, False), - 'Service': (basestring, False), + 'RepositoryName': (str, False), + 'Service': (str, False), } @@ -44,27 +44,27 @@ class ContainerRecipe(AWSObject): props = { 'Components': ([ComponentConfiguration], True), - 'ContainerType': (basestring, True), - 'Description': (basestring, False), - 'DockerfileTemplateData': (basestring, False), - 'DockerfileTemplateUri': (basestring, False), - 'ImageOsVersionOverride': (basestring, False), - 'KmsKeyId': (basestring, False), - 'Name': (basestring, True), - 'ParentImage': (basestring, True), - 'PlatformOverride': (basestring, False), + 'ContainerType': (str, True), + 'Description': (str, False), + 'DockerfileTemplateData': (str, False), + 'DockerfileTemplateUri': (str, False), + 'ImageOsVersionOverride': (str, False), + 'KmsKeyId': (str, False), + 'Name': (str, True), + 'ParentImage': (str, True), + 'PlatformOverride': (str, False), 'Tags': (Tags, False), 'TargetRepository': (TargetContainerRepository, True), - 'Version': (basestring, True), - 'WorkingDirectory': (basestring, False), + 'Version': (str, True), + 'WorkingDirectory': (str, False), } class Distribution(AWSProperty): props = { 'AmiDistributionConfiguration': (dict, False), - 'LicenseConfigurationArns': ([basestring], False), - 'Region': (basestring, False), + 'LicenseConfigurationArns': ([str], False), + 'Region': (str, False), } @@ -72,9 +72,9 @@ class DistributionConfiguration(AWSObject): resource_type = "AWS::ImageBuilder::DistributionConfiguration" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'Distributions': ([Distribution], True), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } @@ -90,18 +90,18 @@ class Image(AWSObject): resource_type = "AWS::ImageBuilder::Image" props = { - 'DistributionConfigurationArn': (basestring, False), - 'ImageRecipeArn': (basestring, True), + 'DistributionConfigurationArn': (str, False), + 'ImageRecipeArn': (str, True), 'ImageTestsConfiguration': (ImageTestsConfiguration, True), - 'InfrastructureConfigurationArn': (basestring, True), + 'InfrastructureConfigurationArn': (str, True), 'Tags': (dict, False), } class S3Logs(AWSProperty): props = { - "S3BucketName": (basestring, False), - "S3KeyPrefix": (basestring, False), + "S3BucketName": (str, False), + "S3KeyPrefix": (str, False), } @@ -115,15 +115,15 @@ class InfrastructureConfiguration(AWSObject): resource_type = "AWS::ImageBuilder::InfrastructureConfiguration" props = { - 'Description': (basestring, False), - 'InstanceProfileName': (basestring, True), - 'InstanceTypes': ([basestring], False), - 'KeyPair': (basestring, False), + 'Description': (str, False), + 'InstanceProfileName': (str, True), + 'InstanceTypes': ([str], False), + 'KeyPair': (str, False), 'Logging': (Logging, False), - 'Name': (basestring, True), - 'SecurityGroupIds': ([basestring], False), - 'SnsTopicArn': (basestring, False), - 'SubnetId': (basestring, False), + 'Name': (str, True), + 'SecurityGroupIds': ([str], False), + 'SnsTopicArn': (str, False), + 'SubnetId': (str, False), 'Tags': (dict, False), 'TerminateInstanceOnFailure': (boolean, False) } @@ -134,8 +134,8 @@ class EbsInstanceBlockDeviceSpecification(AWSProperty): 'DeleteOnTermination': (boolean, False), 'Encrypted': (boolean, False), 'Iops': (integer, False), - 'KmsKeyId': (basestring, False), - 'SnapshotId': (basestring, False), + 'KmsKeyId': (str, False), + 'SnapshotId': (str, False), 'VolumeSize': (integer, False), 'VolumeType': (ebsinstanceblockdevicespecification_volume_type, False), } @@ -143,16 +143,16 @@ class EbsInstanceBlockDeviceSpecification(AWSProperty): class InstanceBlockDeviceMapping(AWSProperty): props = { - 'DeviceName': (basestring, False), + 'DeviceName': (str, False), 'Ebs': (EbsInstanceBlockDeviceSpecification, False), - 'NoDevice': (basestring, False), - 'VirtualName': (basestring, False), + 'NoDevice': (str, False), + 'VirtualName': (str, False), } class ComponentConfiguration(AWSProperty): props = { - 'ComponentArn': (basestring, False), + 'ComponentArn': (str, False), } @@ -162,18 +162,18 @@ class ImageRecipe(AWSObject): props = { 'BlockDeviceMappings': ([InstanceBlockDeviceMapping], False), 'Components': ([ComponentConfiguration], True), - 'Description': (basestring, False), - 'Name': (basestring, True), - 'ParentImage': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), + 'ParentImage': (str, True), 'Tags': (dict, False), - 'Version': (basestring, True) + 'Version': (str, True) } class Schedule(AWSProperty): props = { 'PipelineExecutionStartCondition': (schedule_pipelineexecutionstartcondition, False), # NOQA - 'ScheduleExpression': (basestring, False), + 'ScheduleExpression': (str, False), } @@ -181,12 +181,12 @@ class ImagePipeline(AWSObject): resource_type = "AWS::ImageBuilder::ImagePipeline" props = { - 'Description': (basestring, False), - 'DistributionConfigurationArn': (basestring, False), - 'ImageRecipeArn': (basestring, True), + 'Description': (str, False), + 'DistributionConfigurationArn': (str, False), + 'ImageRecipeArn': (str, True), 'ImageTestsConfiguration': (ImageTestsConfiguration, False), - 'InfrastructureConfigurationArn': (basestring, True), - 'Name': (basestring, True), + 'InfrastructureConfigurationArn': (str, True), + 'Name': (str, True), 'Schedule': (Schedule, False), 'Status': (imagepipeline_status, False), 'Tags': (dict, False), diff --git a/troposphere/inspector.py b/troposphere/inspector.py index 42c32ea0b..498f63453 100644 --- a/troposphere/inspector.py +++ b/troposphere/inspector.py @@ -11,8 +11,8 @@ class AssessmentTarget(AWSObject): resource_type = "AWS::Inspector::AssessmentTarget" props = { - 'AssessmentTargetName': (basestring, False), - 'ResourceGroupArn': (basestring, False), + 'AssessmentTargetName': (str, False), + 'ResourceGroupArn': (str, False), } @@ -20,10 +20,10 @@ class AssessmentTemplate(AWSObject): resource_type = "AWS::Inspector::AssessmentTemplate" props = { - 'AssessmentTargetArn': (basestring, True), - 'AssessmentTemplateName': (basestring, False), + 'AssessmentTargetArn': (str, True), + 'AssessmentTemplateName': (str, False), 'DurationInSeconds': (integer, True), - 'RulesPackageArns': ([basestring], True), + 'RulesPackageArns': ([str], True), 'UserAttributesForFindings': (Tags, False), } diff --git a/troposphere/iot.py b/troposphere/iot.py index e6fe568ba..128ca2b26 100644 --- a/troposphere/iot.py +++ b/troposphere/iot.py @@ -38,8 +38,8 @@ class AuditCheckConfigurations(AWSProperty): class AuditNotificationTarget(AWSProperty): props = { 'Enabled': (boolean, False), - 'RoleArn': (basestring, False), - 'TargetArn': (basestring, False), + 'RoleArn': (str, False), + 'TargetArn': (str, False), } @@ -53,11 +53,11 @@ class AccountAuditConfiguration(AWSObject): resource_type = "AWS::IoT::AccountAuditConfiguration" props = { - 'AccountId': (basestring, True), + 'AccountId': (str, True), 'AuditCheckConfigurations': (AuditCheckConfigurations, True), 'AuditNotificationTargetConfigurations': (AuditNotificationTargetConfigurations, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), } @@ -65,12 +65,12 @@ class Authorizer(AWSObject): resource_type = "AWS::IoT::Authorizer" props = { - 'AuthorizerFunctionArn': (basestring, True), - 'AuthorizerName': (basestring, False), + 'AuthorizerFunctionArn': (str, True), + 'AuthorizerName': (str, False), 'SigningDisabled': (boolean, False), - 'Status': (basestring, False), + 'Status': (str, False), 'Tags': (dict, False), - 'TokenKeyName': (basestring, False), + 'TokenKeyName': (str, False), # 'TokenSigningPublicKeys': (TokenSigningPublicKeys, False), } @@ -79,11 +79,11 @@ class Certificate(AWSObject): resource_type = "AWS::IoT::Certificate" props = { - 'CACertificatePem': (basestring, False), - 'CertificateMode': (basestring, False), - 'CertificatePem': (basestring, False), - 'CertificateSigningRequest': (basestring, False), - 'Status': (basestring, True), + 'CACertificatePem': (str, False), + 'CertificateMode': (str, False), + 'CertificatePem': (str, False), + 'CertificateSigningRequest': (str, False), + 'Status': (str, True), } @@ -91,9 +91,9 @@ class CustomMetric(AWSObject): resource_type = "AWS::IoT::CustomMetric" props = { - 'DisplayName': (basestring, False), - 'MetricName': (basestring, False), - 'MetricType': (basestring, True), + 'DisplayName': (str, False), + 'MetricName': (str, False), + 'MetricType': (str, True), 'Tags': (Tags, False), } @@ -102,17 +102,17 @@ class Dimension(AWSObject): resource_type = "AWS::IoT::Dimension" props = { - 'Name': (basestring, False), - 'StringValues': ([basestring], True), + 'Name': (str, False), + 'StringValues': ([str], True), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } class AuthorizerConfig(AWSProperty): props = { 'AllowAuthorizerOverride': (boolean, False), - 'DefaultAuthorizerName': (basestring, False), + 'DefaultAuthorizerName': (str, False), } @@ -121,51 +121,51 @@ class DomainConfiguration(AWSObject): props = { 'AuthorizerConfig': (AuthorizerConfig, False), - 'DomainConfigurationName': (basestring, False), - 'DomainConfigurationStatus': (basestring, False), - 'DomainName': (basestring, False), - 'ServerCertificateArns': ([basestring], False), - 'ServiceType': (basestring, False), + 'DomainConfigurationName': (str, False), + 'DomainConfigurationStatus': (str, False), + 'DomainName': (str, False), + 'ServerCertificateArns': ([str], False), + 'ServiceType': (str, False), 'Tags': (Tags, False), - 'ValidationCertificateArn': (basestring, False), + 'ValidationCertificateArn': (str, False), } class AddThingsToThingGroupParams(AWSProperty): props = { 'OverrideDynamicGroups': (boolean, False), - 'ThingGroupNames': ([basestring], True), + 'ThingGroupNames': ([str], True), } class EnableIoTLoggingParams(AWSProperty): props = { - 'LogLevel': (basestring, True), - 'RoleArnForLogging': (basestring, True), + 'LogLevel': (str, True), + 'RoleArnForLogging': (str, True), } class PublishFindingToSnsParams(AWSProperty): props = { - 'TopicArn': (basestring, True), + 'TopicArn': (str, True), } class ReplaceDefaultPolicyVersionParams(AWSProperty): props = { - 'TemplateName': (basestring, True), + 'TemplateName': (str, True), } class UpdateCACertificateParams(AWSProperty): props = { - 'Action': (basestring, True), + 'Action': (str, True), } class UpdateDeviceCertificateParams(AWSProperty): props = { - 'Action': (basestring, True), + 'Action': (str, True), } @@ -186,143 +186,143 @@ class MitigationAction(AWSObject): resource_type = "AWS::IoT::MitigationAction" props = { - 'ActionName': (basestring, False), + 'ActionName': (str, False), 'ActionParams': (ActionParams, True), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), } class CloudwatchAlarmAction(AWSProperty): props = { - 'AlarmName': (basestring, True), - 'RoleArn': (basestring, True), - 'StateReason': (basestring, True), - 'StateValue': (basestring, True), + 'AlarmName': (str, True), + 'RoleArn': (str, True), + 'StateReason': (str, True), + 'StateValue': (str, True), } class CloudwatchMetricAction(AWSProperty): props = { - 'MetricName': (basestring, True), - 'MetricNamespace': (basestring, True), - 'MetricTimestamp': (basestring, False), - 'MetricUnit': (basestring, True), - 'MetricValue': (basestring, True), - 'RoleArn': (basestring, True), + 'MetricName': (str, True), + 'MetricNamespace': (str, True), + 'MetricTimestamp': (str, False), + 'MetricUnit': (str, True), + 'MetricValue': (str, True), + 'RoleArn': (str, True), } class DynamoDBAction(AWSProperty): props = { - 'HashKeyField': (basestring, True), - 'HashKeyType': (basestring, False), - 'HashKeyValue': (basestring, True), - 'PayloadField': (basestring, False), - 'RangeKeyField': (basestring, False), - 'RangeKeyType': (basestring, False), - 'RangeKeyValue': (basestring, False), - 'RoleArn': (basestring, True), - 'TableName': (basestring, True), + 'HashKeyField': (str, True), + 'HashKeyType': (str, False), + 'HashKeyValue': (str, True), + 'PayloadField': (str, False), + 'RangeKeyField': (str, False), + 'RangeKeyType': (str, False), + 'RangeKeyValue': (str, False), + 'RoleArn': (str, True), + 'TableName': (str, True), } class PutItemInput(AWSProperty): props = { - 'TableName': (basestring, True), + 'TableName': (str, True), } class DynamoDBv2Action(AWSProperty): props = { 'PutItem': (PutItemInput, False), - 'RoleArn': (basestring, False), + 'RoleArn': (str, False), } class ElasticsearchAction(AWSProperty): props = { - 'Endpoint': (basestring, True), - 'Id': (basestring, True), - 'Index': (basestring, True), - 'RoleArn': (basestring, True), - 'Type': (basestring, True), + 'Endpoint': (str, True), + 'Id': (str, True), + 'Index': (str, True), + 'RoleArn': (str, True), + 'Type': (str, True), } class FirehoseAction(AWSProperty): props = { - 'DeliveryStreamName': (basestring, True), - 'RoleArn': (basestring, True), - 'Separator': (basestring, False), + 'DeliveryStreamName': (str, True), + 'RoleArn': (str, True), + 'Separator': (str, False), } class IotAnalyticsAction(AWSProperty): props = { - 'ChannelName': (basestring, True), - 'RoleArn': (basestring, True), + 'ChannelName': (str, True), + 'RoleArn': (str, True), } class KinesisAction(AWSProperty): props = { - 'PartitionKey': (basestring, False), - 'RoleArn': (basestring, True), - 'StreamName': (basestring, True), + 'PartitionKey': (str, False), + 'RoleArn': (str, True), + 'StreamName': (str, True), } class LambdaAction(AWSProperty): props = { - 'FunctionArn': (basestring, True), + 'FunctionArn': (str, True), } class RepublishAction(AWSProperty): props = { 'Qos': (integer, False), - 'RoleArn': (basestring, True), - 'Topic': (basestring, True), + 'RoleArn': (str, True), + 'Topic': (str, True), } class S3Action(AWSProperty): props = { - 'BucketName': (basestring, True), - 'Key': (basestring, True), - 'RoleArn': (basestring, True), + 'BucketName': (str, True), + 'Key': (str, True), + 'RoleArn': (str, True), } class SnsAction(AWSProperty): props = { - 'MessageFormat': (basestring, False), - 'RoleArn': (basestring, True), - 'TargetArn': (basestring, True), + 'MessageFormat': (str, False), + 'RoleArn': (str, True), + 'TargetArn': (str, True), } class SqsAction(AWSProperty): props = { - 'QueueUrl': (basestring, True), - 'RoleArn': (basestring, True), - 'UseBase64': (basestring, False), + 'QueueUrl': (str, True), + 'RoleArn': (str, True), + 'UseBase64': (str, False), } class SigV4Authorization(AWSProperty): props = { - 'RoleArn': (basestring, True), - 'ServiceName': (basestring, True), - 'SigningRegion': (basestring, True), + 'RoleArn': (str, True), + 'ServiceName': (str, True), + 'SigningRegion': (str, True), } class HttpActionHeader(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -335,39 +335,39 @@ class HttpAuthorization(AWSProperty): class HttpAction(AWSProperty): props = { 'Auth': (HttpAuthorization, False), - 'ConfirmationUrl': (basestring, False), + 'ConfirmationUrl': (str, False), 'Headers': ([HttpActionHeader], False), - 'Url': (basestring, True), + 'Url': (str, True), } class IotEventsAction(AWSProperty): props = { - 'InputName': (basestring, True), - 'MessageId': (basestring, False), - 'RoleArn': (basestring, True), + 'InputName': (str, True), + 'MessageId': (str, False), + 'RoleArn': (str, True), } class AssetPropertyVariant(AWSProperty): props = { - 'BooleanValue': (basestring, False), - 'DoubleValue': (basestring, False), - 'IntegerValue': (basestring, False), - 'StringValue': (basestring, False), + 'BooleanValue': (str, False), + 'DoubleValue': (str, False), + 'IntegerValue': (str, False), + 'StringValue': (str, False), } class AssetPropertyTimestamp(AWSProperty): props = { - 'OffsetInNanos': (basestring, False), - 'TimeInSeconds': (basestring, True), + 'OffsetInNanos': (str, False), + 'TimeInSeconds': (str, True), } class AssetPropertyValue(AWSProperty): props = { - 'Quality': (basestring, False), + 'Quality': (str, False), 'Timestamp': (AssetPropertyTimestamp, True), 'Value': (AssetPropertyVariant, True), } @@ -375,10 +375,10 @@ class AssetPropertyValue(AWSProperty): class PutAssetPropertyValueEntry(AWSProperty): props = { - 'AssetId': (basestring, False), - 'EntryId': (basestring, False), - 'PropertyAlias': (basestring, False), - 'PropertyId': (basestring, False), + 'AssetId': (str, False), + 'EntryId': (str, False), + 'PropertyAlias': (str, False), + 'PropertyId': (str, False), 'PropertyValues': ([AssetPropertyValue], True), } @@ -386,15 +386,15 @@ class PutAssetPropertyValueEntry(AWSProperty): class IotSiteWiseAction(AWSProperty): props = { 'PutAssetPropertyValueEntries': ([PutAssetPropertyValueEntry], True), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), } class StepFunctionsAction(AWSProperty): props = { - 'ExecutionNamePrefix': (basestring, False), - 'RoleArn': (basestring, True), - 'StateMachineName': (basestring, True), + 'ExecutionNamePrefix': (str, False), + 'RoleArn': (str, True), + 'StateMachineName': (str, True), } @@ -423,10 +423,10 @@ class Action(AWSProperty): class TopicRulePayload(AWSProperty): props = { 'Actions': ([Action], True), - 'AwsIotSqlVersion': (basestring, False), - 'Description': (basestring, False), + 'AwsIotSqlVersion': (str, False), + 'Description': (str, False), 'RuleDisabled': (boolean, True), - 'Sql': (basestring, True), + 'Sql': (str, True), } @@ -434,7 +434,7 @@ class TopicRule(AWSObject): resource_type = "AWS::IoT::TopicRule" props = { - 'RuleName': (basestring, False), + 'RuleName': (str, False), 'TopicRulePayload': (TopicRulePayload, True), } @@ -443,8 +443,8 @@ class ThingPrincipalAttachment(AWSObject): resource_type = "AWS::IoT::ThingPrincipalAttachment" props = { - 'Principal': (basestring, True), - 'ThingName': (basestring, True), + 'Principal': (str, True), + 'ThingName': (str, True), } @@ -453,7 +453,7 @@ class Thing(AWSObject): props = { 'AttributePayload': (dict, False), - 'ThingName': (basestring, False), + 'ThingName': (str, False), } @@ -461,8 +461,8 @@ class PolicyPrincipalAttachment(AWSObject): resource_type = "AWS::IoT::PolicyPrincipalAttachment" props = { - 'PolicyName': (basestring, True), - 'Principal': (basestring, True), + 'PolicyName': (str, True), + 'Principal': (str, True), } @@ -471,14 +471,14 @@ class Policy(AWSObject): props = { 'PolicyDocument': (policytypes, True), - 'PolicyName': (basestring, False), + 'PolicyName': (str, False), } class ProvisioningHook(AWSProperty): props = { - 'PayloadVersion': (basestring, False), - 'TargetArn': (basestring, False), + 'PayloadVersion': (str, False), + 'TargetArn': (str, False), } @@ -486,13 +486,13 @@ class ProvisioningTemplate(AWSObject): resource_type = "AWS::IoT::ProvisioningTemplate" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'Enabled': (boolean, False), 'PreProvisioningHook': (ProvisioningHook, False), - 'ProvisioningRoleArn': (basestring, True), + 'ProvisioningRoleArn': (str, True), 'Tags': (dict, False), - 'TemplateBody': (basestring, True), - 'TemplateName': (basestring, False), + 'TemplateBody': (str, True), + 'TemplateName': (str, False), } @@ -500,41 +500,41 @@ class ScheduledAudit(AWSObject): resource_type = "AWS::IoT::ScheduledAudit" props = { - 'DayOfMonth': (basestring, False), - 'DayOfWeek': (basestring, False), - 'Frequency': (basestring, True), - 'ScheduledAuditName': (basestring, False), + 'DayOfMonth': (str, False), + 'DayOfWeek': (str, False), + 'Frequency': (str, True), + 'ScheduledAuditName': (str, False), 'Tags': (Tags, False), - 'TargetCheckNames': ([basestring], True), + 'TargetCheckNames': ([str], True), } class MachineLearningDetectionConfig(AWSProperty): props = { - 'ConfidenceLevel': (basestring, False), + 'ConfidenceLevel': (str, False), } class MetricValue(AWSProperty): props = { - 'Cidrs': ([basestring], False), - 'Count': (basestring, False), + 'Cidrs': ([str], False), + 'Count': (str, False), 'Number': (double, False), 'Numbers': ([double], False), 'Ports': ([integer], False), - 'Strings': ([basestring], False), + 'Strings': ([str], False), } class StatisticalThreshold(AWSProperty): props = { - 'Statistic': (basestring, False), + 'Statistic': (str, False), } class BehaviorCriteria(AWSProperty): props = { - 'ComparisonOperator': (basestring, False), + 'ComparisonOperator': (str, False), 'ConsecutiveDatapointsToAlarm': (integer, False), 'ConsecutiveDatapointsToClear': (integer, False), 'DurationSeconds': (integer, False), @@ -546,24 +546,24 @@ class BehaviorCriteria(AWSProperty): class MetricDimension(AWSProperty): props = { - 'DimensionName': (basestring, True), - 'Operator': (basestring, False), + 'DimensionName': (str, True), + 'Operator': (str, False), } class Behavior(AWSProperty): props = { 'Criteria': (BehaviorCriteria, False), - 'Metric': (basestring, False), + 'Metric': (str, False), 'MetricDimension': (MetricDimension, False), - 'Name': (basestring, True), + 'Name': (str, True), 'SuppressAlerts': (boolean, False), } class MetricToRetain(AWSProperty): props = { - 'Metric': (basestring, True), + 'Metric': (str, True), 'MetricDimension': (MetricDimension, False), } @@ -575,25 +575,25 @@ class SecurityProfile(AWSObject): 'AdditionalMetricsToRetainV2': ([MetricToRetain], False), 'AlertTargets': (dict, False), 'Behaviors': ([Behavior], False), - 'SecurityProfileDescription': (basestring, False), - 'SecurityProfileName': (basestring, False), + 'SecurityProfileDescription': (str, False), + 'SecurityProfileName': (str, False), 'Tags': (Tags, False), - 'TargetArns': ([basestring], False), + 'TargetArns': ([str], False), } class HttpUrlDestinationSummary(AWSProperty): props = { - 'ConfirmationUrl': (basestring, False), + 'ConfirmationUrl': (str, False), } class VpcDestinationProperties(AWSProperty): props = { - 'RoleArn': (basestring, False), - 'SecurityGroups': ([basestring], False), - 'SubnetIds': ([basestring], False), - 'VpcId': (basestring, False), + 'RoleArn': (str, False), + 'SecurityGroups': ([str], False), + 'SubnetIds': ([str], False), + 'VpcId': (str, False), } @@ -602,6 +602,6 @@ class TopicRuleDestination(AWSObject): props = { 'HttpUrlProperties': (HttpUrlDestinationSummary, False), - 'Status': (basestring, False), + 'Status': (str, False), 'VpcProperties': (VpcDestinationProperties, False), } diff --git a/troposphere/iot1click.py b/troposphere/iot1click.py index 0a722dd1e..ddf56dc47 100644 --- a/troposphere/iot1click.py +++ b/troposphere/iot1click.py @@ -6,7 +6,7 @@ class Device(AWSObject): resource_type = "AWS::IoT1Click::Device" props = { - 'DeviceId': (basestring, True), + 'DeviceId': (str, True), 'Enabled': (boolean, True), } @@ -17,8 +17,8 @@ class Placement(AWSObject): props = { 'AssociatedDevices': (json_checker, False), 'Attributes': (json_checker, False), - 'PlacementName': (basestring, False), - 'ProjectName': (basestring, True), + 'PlacementName': (str, False), + 'ProjectName': (str, True), } @@ -33,7 +33,7 @@ class Project(AWSObject): resource_type = "AWS::IoT1Click::Project" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'PlacementTemplate': (PlacementTemplate, True), - 'ProjectName': (basestring, False), + 'ProjectName': (str, False), } diff --git a/troposphere/iotanalytics.py b/troposphere/iotanalytics.py index 8a94a7420..bdbb1b9c1 100644 --- a/troposphere/iotanalytics.py +++ b/troposphere/iotanalytics.py @@ -16,9 +16,9 @@ class RetentionPeriod(AWSProperty): class CustomerManagedS3(AWSProperty): props = { - 'Bucket': (basestring, True), - 'KeyPrefix': (basestring, False), - 'RoleArn': (basestring, True), + 'Bucket': (str, True), + 'KeyPrefix': (str, False), + 'RoleArn': (str, True), } @@ -38,7 +38,7 @@ class Channel(AWSObject): resource_type = "AWS::IoTAnalytics::Channel" props = { - 'ChannelName': (basestring, False), + 'ChannelName': (str, False), 'ChannelStorage': (ChannelStorage, False), 'RetentionPeriod': (RetentionPeriod, False), 'Tags': ((Tags, list), False), @@ -48,85 +48,85 @@ class Channel(AWSObject): class AddAttributes(AWSProperty): props = { 'Attributes': (dict, False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'Name': (str, False), + 'Next': (str, False), } class ActivityChannel(AWSProperty): props = { - 'ChannelName': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'ChannelName': (str, False), + 'Name': (str, False), + 'Next': (str, False), } class ActivityDatastore(AWSProperty): props = { - 'DatastoreName': (basestring, False), - 'Name': (basestring, False), + 'DatastoreName': (str, False), + 'Name': (str, False), } class DeviceRegistryEnrich(AWSProperty): props = { - 'Attribute': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), - 'RoleArn': (basestring, False), - 'ThingName': (basestring, False), + 'Attribute': (str, False), + 'Name': (str, False), + 'Next': (str, False), + 'RoleArn': (str, False), + 'ThingName': (str, False), } class DeviceShadowEnrich(AWSProperty): props = { - 'Attribute': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), - 'RoleArn': (basestring, False), - 'ThingName': (basestring, False), + 'Attribute': (str, False), + 'Name': (str, False), + 'Next': (str, False), + 'RoleArn': (str, False), + 'ThingName': (str, False), } class Filter(AWSProperty): props = { - 'Filter': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'Filter': (str, False), + 'Name': (str, False), + 'Next': (str, False), } class Lambda(AWSProperty): props = { 'BatchSize': (integer, False), - 'LambdaName': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'LambdaName': (str, False), + 'Name': (str, False), + 'Next': (str, False), } class Math(AWSProperty): props = { - 'Attribute': (basestring, False), - 'Math': (basestring, False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'Attribute': (str, False), + 'Math': (str, False), + 'Name': (str, False), + 'Next': (str, False), } class RemoveAttributes(AWSProperty): props = { - 'Attributes': ([basestring], False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'Attributes': ([str], False), + 'Name': (str, False), + 'Next': (str, False), } class SelectAttributes(AWSProperty): props = { - 'Attributes': ([basestring], False), - 'Name': (basestring, False), - 'Next': (basestring, False), + 'Attributes': ([str], False), + 'Name': (str, False), + 'Next': (str, False), } @@ -150,27 +150,27 @@ class Pipeline(AWSObject): props = { 'PipelineActivities': ([Activity], True), - 'PipelineName': (basestring, False), + 'PipelineName': (str, False), 'Tags': ((Tags, list), False), } class ResourceConfiguration(AWSProperty): props = { - 'ComputeType': (basestring, True), + 'ComputeType': (str, True), 'VolumeSizeInGB': (integer, True), } class DatasetContentVersionValue(AWSProperty): props = { - 'DatasetName': (basestring, False), + 'DatasetName': (str, False), } class OutputFileUriValue(AWSProperty): props = { - 'FileName': (basestring, False), + 'FileName': (str, False), } @@ -179,15 +179,15 @@ class Variable(AWSProperty): 'DatasetContentVersionValue': (DatasetContentVersionValue, False), 'DoubleValue': (double, False), 'OutputFileUriValue': (OutputFileUriValue, False), - 'StringValue': (basestring, False), - 'VariableName': (basestring, False) + 'StringValue': (str, False), + 'VariableName': (str, False) } class ContainerAction(AWSProperty): props = { - 'ExecutionRoleArn': (basestring, True), - 'Image': (basestring, True), + 'ExecutionRoleArn': (str, True), + 'Image': (str, True), 'ResourceConfiguration': (ResourceConfiguration, False), 'Variables': ([Variable], False), } @@ -195,7 +195,7 @@ class ContainerAction(AWSProperty): class DeltaTime(AWSProperty): props = { - 'TimeExpression': (basestring, True), + 'TimeExpression': (str, True), 'OffsetSeconds': (integer, True), } @@ -209,13 +209,13 @@ class QueryActionFilter(AWSProperty): class QueryAction(AWSProperty): props = { 'Filters': ([QueryActionFilter], False), - 'SqlQuery': (basestring, False), + 'SqlQuery': (str, False), } class Action(AWSProperty): props = { - 'ActionName': (basestring, True), + 'ActionName': (str, True), 'ContainerAction': (ContainerAction, False), 'QueryAction': (QueryAction, False) } @@ -223,24 +223,24 @@ class Action(AWSProperty): class IotEventsDestinationConfiguration(AWSProperty): props = { - 'InputName': (basestring, True), - 'RoleArn': (basestring, True), + 'InputName': (str, True), + 'RoleArn': (str, True), } class GlueConfiguration(AWSProperty): props = { - 'DatabaseName': (basestring, True), - 'TableName': (basestring, True), + 'DatabaseName': (str, True), + 'TableName': (str, True), } class S3DestinationConfiguration(AWSProperty): props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'GlueConfiguration': (GlueConfiguration, False), - 'Key': (basestring, True), - 'RoleArn': (basestring, True), + 'Key': (str, True), + 'RoleArn': (str, True), } @@ -255,7 +255,7 @@ class DatasetContentDeliveryRuleDestination(AWSProperty): class DatasetContentDeliveryRule(AWSProperty): props = { 'Destination': (DatasetContentDeliveryRuleDestination, True), - 'EntryName': (basestring, False), + 'EntryName': (str, False), } @@ -275,19 +275,19 @@ class LateDataRuleConfiguration(AWSProperty): class LateDataRule(AWSProperty): props = { 'RuleConfiguration': (LateDataRuleConfiguration, True), - 'RuleName': (basestring, False), + 'RuleName': (str, False), } class Schedule(AWSProperty): props = { - 'ScheduleExpression': (basestring, True), + 'ScheduleExpression': (str, True), } class TriggeringDataset(AWSProperty): props = { - 'DatasetName': (basestring, True), + 'DatasetName': (str, True), } @@ -311,7 +311,7 @@ class Dataset(AWSObject): props = { 'Actions': ([Action], True), 'ContentDeliveryRules': ([DatasetContentDeliveryRule], False), - 'DatasetName': (basestring, False), + 'DatasetName': (str, False), 'LateDataRules': ([LateDataRule], False), 'RetentionPeriod': (RetentionPeriod, False), 'Tags': (Tags, False), @@ -329,8 +329,8 @@ class DatastoreStorage(AWSProperty): class Column(AWSProperty): props = { - 'Name': (basestring, True), - 'Type': (basestring, True), + 'Name': (str, True), + 'Type': (str, True), } @@ -357,7 +357,7 @@ class Datastore(AWSObject): resource_type = "AWS::IoTAnalytics::Datastore" props = { - 'DatastoreName': (basestring, False), + 'DatastoreName': (str, False), 'DatastoreStorage': (DatastoreStorage, False), 'FileFormatConfiguration': (FileFormatConfiguration, False), 'RetentionPeriod': (RetentionPeriod, False), diff --git a/troposphere/iotevents.py b/troposphere/iotevents.py index 9192e97ac..650b6b2cc 100644 --- a/troposphere/iotevents.py +++ b/troposphere/iotevents.py @@ -16,64 +16,64 @@ class ClearTimer(AWSProperty): props = { - 'TimerName': (basestring, False), + 'TimerName': (str, False), } class Firehose(AWSProperty): props = { - 'DeliveryStreamName': (basestring, False), - 'Separator': (basestring, False), + 'DeliveryStreamName': (str, False), + 'Separator': (str, False), } class IotEvents(AWSProperty): props = { - 'InputName': (basestring, False), + 'InputName': (str, False), } class IotTopicPublish(AWSProperty): props = { - 'MqttTopic': (basestring, False), + 'MqttTopic': (str, False), } class Lambda(AWSProperty): props = { - 'FunctionArn': (basestring, False), + 'FunctionArn': (str, False), } class ResetTimer(AWSProperty): props = { - 'TimerName': (basestring, False), + 'TimerName': (str, False), } class SetTimer(AWSProperty): props = { 'Seconds': (integer, False), - 'TimerName': (basestring, False), + 'TimerName': (str, False), } class SetVariable(AWSProperty): props = { - 'Value': (basestring, False), - 'VariableName': (basestring, False), + 'Value': (str, False), + 'VariableName': (str, False), } class Sns(AWSProperty): props = { - 'TargetArn': (basestring, False), + 'TargetArn': (str, False), } class Sqs(AWSProperty): props = { - 'QueueUrl': (basestring, False), + 'QueueUrl': (str, False), 'UseBase64': (boolean, False), } @@ -96,8 +96,8 @@ class Action(AWSProperty): class Event(AWSProperty): props = { 'Actions': ([Action], False), - 'Condition': (basestring, False), - 'EventName': (basestring, False), + 'Condition': (str, False), + 'EventName': (str, False), } @@ -116,9 +116,9 @@ class OnExit(AWSProperty): class TransitionEvent(AWSProperty): props = { 'Actions': ([Action], False), - 'Condition': (basestring, False), - 'EventName': (basestring, False), - 'NextState': (basestring, False), + 'Condition': (str, False), + 'EventName': (str, False), + 'NextState': (str, False), } @@ -134,13 +134,13 @@ class State(AWSProperty): 'OnEnter': (OnEnter, False), 'OnExit': (OnExit, False), 'OnInput': (OnInput, False), - 'StateName': (basestring, False), + 'StateName': (str, False), } class DetectorModelDefinition(AWSProperty): props = { - 'InitialStateName': (basestring, False), + 'InitialStateName': (str, False), 'States': ([State], False), } @@ -150,17 +150,17 @@ class DetectorModel(AWSObject): props = { 'DetectorModelDefinition': (DetectorModelDefinition, False), - 'DetectorModelDescription': (basestring, False), - 'DetectorModelName': (basestring, False), - 'Key': (basestring, False), - 'RoleArn': (basestring, False), + 'DetectorModelDescription': (str, False), + 'DetectorModelName': (str, False), + 'Key': (str, False), + 'RoleArn': (str, False), 'Tags': (Tags, False), } class Attribute(AWSProperty): props = { - 'JsonPath': (basestring, False), + 'JsonPath': (str, False), } @@ -175,7 +175,7 @@ class Input(AWSObject): props = { 'InputDefinition': (InputDefinition, False), - 'InputDescription': (basestring, False), - 'InputName': (basestring, False), + 'InputDescription': (str, False), + 'InputName': (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/iotsitewise.py b/troposphere/iotsitewise.py index ca7b3ab55..61f574208 100644 --- a/troposphere/iotsitewise.py +++ b/troposphere/iotsitewise.py @@ -14,19 +14,19 @@ class IamRole(AWSProperty): props = { - 'arn': (basestring, False), + 'arn': (str, False), } class IamUser(AWSProperty): props = { - 'arn': (basestring, False), + 'arn': (str, False), } class User(AWSProperty): props = { - 'id': (basestring, False), + 'id': (str, False), } @@ -40,13 +40,13 @@ class AccessPolicyIdentity(AWSProperty): class PortalProperty(AWSProperty): props = { - 'id': (basestring, False), + 'id': (str, False), } class Project(AWSProperty): props = { - 'id': (basestring, False), + 'id': (str, False), } @@ -62,23 +62,23 @@ class AccessPolicy(AWSObject): props = { 'AccessPolicyIdentity': (AccessPolicyIdentity, True), - 'AccessPolicyPermission': (basestring, True), + 'AccessPolicyPermission': (str, True), 'AccessPolicyResource': (AccessPolicyResource, True), } class AssetHierarchy(AWSProperty): props = { - 'ChildAssetId': (basestring, True), - 'LogicalId': (basestring, True), + 'ChildAssetId': (str, True), + 'LogicalId': (str, True), } class AssetProperty(AWSProperty): props = { - 'Alias': (basestring, False), - 'LogicalId': (basestring, True), - 'NotificationState': (basestring, False), + 'Alias': (str, False), + 'LogicalId': (str, True), + 'NotificationState': (str, False), } @@ -87,8 +87,8 @@ class Asset(AWSObject): props = { 'AssetHierarchies': ([AssetHierarchy], False), - 'AssetModelId': (basestring, True), - 'AssetName': (basestring, True), + 'AssetModelId': (str, True), + 'AssetName': (str, True), 'AssetProperties': ([AssetProperty], False), 'Tags': (Tags, False), } @@ -96,27 +96,27 @@ class Asset(AWSObject): class Attribute(AWSProperty): props = { - 'DefaultValue': (basestring, False), + 'DefaultValue': (str, False), } class VariableValue(AWSProperty): props = { - 'HierarchyLogicalId': (basestring, False), - 'PropertyLogicalId': (basestring, True), + 'HierarchyLogicalId': (str, False), + 'PropertyLogicalId': (str, True), } class ExpressionVariable(AWSProperty): props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Value': (VariableValue, True), } class TumblingWindow(AWSProperty): props = { - 'Interval': (basestring, True), + 'Interval': (str, True), } @@ -128,7 +128,7 @@ class MetricWindow(AWSProperty): class Metric(AWSProperty): props = { - 'Expression': (basestring, True), + 'Expression': (str, True), 'Variables': ([ExpressionVariable], True), 'Window': (MetricWindow, True), } @@ -136,7 +136,7 @@ class Metric(AWSProperty): class Transform(AWSProperty): props = { - 'Expression': (basestring, True), + 'Expression': (str, True), 'Variables': ([ExpressionVariable], True), } @@ -146,35 +146,35 @@ class PropertyType(AWSProperty): 'Attribute': (Attribute, False), 'Metric': (Metric, False), 'Transform': (Transform, False), - 'TypeName': (basestring, True), + 'TypeName': (str, True), } class AssetModelProperty(AWSProperty): props = { - 'DataType': (basestring, True), - 'DataTypeSpec': (basestring, False), - 'LogicalId': (basestring, True), - 'Name': (basestring, True), + 'DataType': (str, True), + 'DataTypeSpec': (str, False), + 'LogicalId': (str, True), + 'Name': (str, True), 'Type': (PropertyType, True), - 'Unit': (basestring, False), + 'Unit': (str, False), } class AssetModelCompositeModel(AWSProperty): props = { 'CompositeModelProperties': ([AssetModelProperty], False), - 'Description': (basestring, False), - 'Name': (basestring, True), - 'Type': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), + 'Type': (str, True), } class AssetModelHierarchy(AWSProperty): props = { - 'ChildAssetModelId': (basestring, True), - 'LogicalId': (basestring, True), - 'Name': (basestring, True), + 'ChildAssetModelId': (str, True), + 'LogicalId': (str, True), + 'Name': (str, True), } @@ -183,9 +183,9 @@ class AssetModel(AWSObject): props = { 'AssetModelCompositeModels': ([AssetModelCompositeModel], False), - 'AssetModelDescription': (basestring, False), + 'AssetModelDescription': (str, False), 'AssetModelHierarchies': ([AssetModelHierarchy], False), - 'AssetModelName': (basestring, True), + 'AssetModelName': (str, True), 'AssetModelProperties': ([AssetModelProperty], False), 'Tags': (Tags, False), } @@ -195,24 +195,24 @@ class Dashboard(AWSObject): resource_type = "AWS::IoTSiteWise::Dashboard" props = { - 'DashboardDefinition': (basestring, True), - 'DashboardDescription': (basestring, True), - 'DashboardName': (basestring, True), - 'ProjectId': (basestring, False), + 'DashboardDefinition': (str, True), + 'DashboardDescription': (str, True), + 'DashboardName': (str, True), + 'ProjectId': (str, False), 'Tags': (Tags, False), } class GatewayCapabilitySummary(AWSProperty): props = { - 'CapabilityConfiguration': (basestring, False), - 'CapabilityNamespace': (basestring, True), + 'CapabilityConfiguration': (str, False), + 'CapabilityNamespace': (str, True), } class Greengrass(AWSProperty): props = { - 'GroupArn': (basestring, True), + 'GroupArn': (str, True), } @@ -227,7 +227,7 @@ class Gateway(AWSObject): props = { 'GatewayCapabilitySummaries': ([GatewayCapabilitySummary], False), - 'GatewayName': (basestring, True), + 'GatewayName': (str, True), 'GatewayPlatform': (GatewayPlatform, True), 'Tags': (Tags, False), } @@ -237,10 +237,10 @@ class Portal(AWSObject): resource_type = "AWS::IoTSiteWise::Portal" props = { - 'PortalAuthMode': (basestring, False), - 'PortalContactEmail': (basestring, True), - 'PortalDescription': (basestring, False), - 'PortalName': (basestring, True), - 'RoleArn': (basestring, True), + 'PortalAuthMode': (str, False), + 'PortalContactEmail': (str, True), + 'PortalDescription': (str, False), + 'PortalName': (str, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/iotwireless.py b/troposphere/iotwireless.py index b3d28eebd..5b0c38b25 100644 --- a/troposphere/iotwireless.py +++ b/troposphere/iotwireless.py @@ -18,11 +18,11 @@ class Destination(AWSObject): resource_type = "AWS::IoTWireless::Destination" props = { - 'Description': (basestring, False), - 'Expression': (basestring, True), - 'ExpressionType': (basestring, True), - 'Name': (basestring, True), - 'RoleArn': (basestring, True), + 'Description': (str, False), + 'Expression': (str, True), + 'ExpressionType': (str, True), + 'Name': (str, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), } @@ -31,14 +31,14 @@ class LoRaWANDeviceProfile(AWSProperty): props = { 'ClassBTimeout': (integer, False), 'ClassCTimeout': (integer, False), - 'MacVersion': (basestring, False), + 'MacVersion': (str, False), 'MaxDutyCycle': (integer, False), 'MaxEirp': (integer, False), 'PingSlotDr': (integer, False), 'PingSlotFreq': (integer, False), 'PingSlotPeriod': (integer, False), - 'RegParamsRevision': (basestring, False), - 'RfRegion': (basestring, False), + 'RegParamsRevision': (str, False), + 'RfRegion': (str, False), 'Supports32BitFCnt': (boolean, False), 'SupportsClassB': (boolean, False), 'SupportsClassC': (boolean, False), @@ -51,7 +51,7 @@ class DeviceProfile(AWSObject): props = { 'LoRaWAN': (LoRaWANDeviceProfile, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), } @@ -59,11 +59,11 @@ class DeviceProfile(AWSObject): class LoRaWANServiceProfile(AWSProperty): props = { 'AddGwMetadata': (boolean, False), - 'ChannelMask': (basestring, False), + 'ChannelMask': (str, False), 'DevStatusReqFreq': (integer, False), 'DlBucketSize': (integer, False), 'DlRate': (integer, False), - 'DlRatePolicy': (basestring, False), + 'DlRatePolicy': (str, False), 'DrMax': (integer, False), 'DrMin': (integer, False), 'HrAllowed': (boolean, False), @@ -76,7 +76,7 @@ class LoRaWANServiceProfile(AWSProperty): 'TargetPer': (integer, False), 'UlBucketSize': (integer, False), 'UlRate': (integer, False), - 'UlRatePolicy': (basestring, False), + 'UlRatePolicy': (str, False), } @@ -85,53 +85,53 @@ class ServiceProfile(AWSObject): props = { 'LoRaWAN': (LoRaWANServiceProfile, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), } class SessionKeysAbpV10x(AWSProperty): props = { - 'AppSKey': (basestring, True), - 'NwkSKey': (basestring, True), + 'AppSKey': (str, True), + 'NwkSKey': (str, True), } class AbpV10x(AWSProperty): props = { - 'DevAddr': (basestring, True), + 'DevAddr': (str, True), 'SessionKeys': (SessionKeysAbpV10x, True), } class SessionKeysAbpV11(AWSProperty): props = { - 'AppSKey': (basestring, True), - 'FNwkSIntKey': (basestring, True), - 'NwkSEncKey': (basestring, True), - 'SNwkSIntKey': (basestring, True), + 'AppSKey': (str, True), + 'FNwkSIntKey': (str, True), + 'NwkSEncKey': (str, True), + 'SNwkSIntKey': (str, True), } class AbpV11(AWSProperty): props = { - 'DevAddr': (basestring, True), + 'DevAddr': (str, True), 'SessionKeys': (SessionKeysAbpV11, True), } class OtaaV10x(AWSProperty): props = { - 'AppEui': (basestring, True), - 'AppKey': (basestring, True), + 'AppEui': (str, True), + 'AppKey': (str, True), } class OtaaV11(AWSProperty): props = { - 'AppKey': (basestring, True), - 'JoinEui': (basestring, True), - 'NwkKey': (basestring, True), + 'AppKey': (str, True), + 'JoinEui': (str, True), + 'NwkKey': (str, True), } @@ -139,11 +139,11 @@ class LoRaWANDevice(AWSProperty): props = { 'AbpV10x': (AbpV10x, False), 'AbpV11': (AbpV11, False), - 'DevEui': (basestring, False), - 'DeviceProfileId': (basestring, False), + 'DevEui': (str, False), + 'DeviceProfileId': (str, False), 'OtaaV10x': (OtaaV10x, False), 'OtaaV11': (OtaaV11, False), - 'ServiceProfileId': (basestring, False), + 'ServiceProfileId': (str, False), } @@ -151,21 +151,21 @@ class WirelessDevice(AWSObject): resource_type = "AWS::IoTWireless::WirelessDevice" props = { - 'Description': (basestring, False), - 'DestinationName': (basestring, True), - 'LastUplinkReceivedAt': (basestring, False), + 'Description': (str, False), + 'DestinationName': (str, True), + 'LastUplinkReceivedAt': (str, False), 'LoRaWAN': (LoRaWANDevice, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), - 'ThingArn': (basestring, False), - 'Type': (basestring, True), + 'ThingArn': (str, False), + 'Type': (str, True), } class LoRaWANGateway(AWSProperty): props = { - 'GatewayEui': (basestring, True), - 'RfRegion': (basestring, True), + 'GatewayEui': (str, True), + 'RfRegion': (str, True), } @@ -173,10 +173,10 @@ class WirelessGateway(AWSObject): resource_type = "AWS::IoTWireless::WirelessGateway" props = { - 'Description': (basestring, False), - 'LastUplinkReceivedAt': (basestring, False), + 'Description': (str, False), + 'LastUplinkReceivedAt': (str, False), 'LoRaWAN': (LoRaWANGateway, True), - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), - 'ThingArn': (basestring, False), + 'ThingArn': (str, False), } diff --git a/troposphere/ivs.py b/troposphere/ivs.py index f3770145d..305e235b4 100644 --- a/troposphere/ivs.py +++ b/troposphere/ivs.py @@ -17,10 +17,10 @@ class Channel(AWSObject): props = { 'Authorized': (boolean, False), - 'LatencyMode': (basestring, False), - 'Name': (basestring, False), + 'LatencyMode': (str, False), + 'Name': (str, False), 'Tags': (Tags, False), - 'Type': (basestring, False), + 'Type': (str, False), } @@ -28,8 +28,8 @@ class PlaybackKeyPair(AWSObject): resource_type = "AWS::IVS::PlaybackKeyPair" props = { - 'Name': (basestring, False), - 'PublicKeyMaterial': (basestring, True), + 'Name': (str, False), + 'PublicKeyMaterial': (str, True), 'Tags': (Tags, False), } @@ -38,6 +38,6 @@ class StreamKey(AWSObject): resource_type = "AWS::IVS::StreamKey" props = { - 'ChannelArn': (basestring, True), + 'ChannelArn': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/kendra.py b/troposphere/kendra.py index 994ae134f..1f51a6475 100644 --- a/troposphere/kendra.py +++ b/troposphere/kendra.py @@ -16,9 +16,9 @@ class ConfluenceAttachmentToIndexFieldMapping(AWSProperty): props = { - 'DataSourceFieldName': (basestring, True), - 'DateFieldFormat': (basestring, False), - 'IndexFieldName': (basestring, True), + 'DataSourceFieldName': (str, True), + 'DateFieldFormat': (str, False), + 'IndexFieldName': (str, True), } @@ -39,9 +39,9 @@ class ConfluenceAttachmentConfiguration(AWSProperty): class ConfluenceBlogToIndexFieldMapping(AWSProperty): props = { - 'DataSourceFieldName': (basestring, True), - 'DateFieldFormat': (basestring, False), - 'IndexFieldName': (basestring, True), + 'DataSourceFieldName': (str, True), + 'DateFieldFormat': (str, False), + 'IndexFieldName': (str, True), } @@ -60,9 +60,9 @@ class ConfluenceBlogConfiguration(AWSProperty): class ConfluencePageToIndexFieldMapping(AWSProperty): props = { - 'DataSourceFieldName': (basestring, True), - 'DateFieldFormat': (basestring, False), - 'IndexFieldName': (basestring, True), + 'DataSourceFieldName': (str, True), + 'DateFieldFormat': (str, False), + 'IndexFieldName': (str, True), } @@ -81,9 +81,9 @@ class ConfluencePageConfiguration(AWSProperty): class ConfluenceSpaceToIndexFieldMapping(AWSProperty): props = { - 'DataSourceFieldName': (basestring, True), - 'DateFieldFormat': (basestring, False), - 'IndexFieldName': (basestring, True), + 'DataSourceFieldName': (str, True), + 'DateFieldFormat': (str, False), + 'IndexFieldName': (str, True), } @@ -96,7 +96,7 @@ class ConfluenceSpaceFieldMappingsList(AWSProperty): class ConfluenceSpaceList(AWSProperty): props = { - 'ConfluenceSpaceList': ([basestring], False), + 'ConfluenceSpaceList': ([str], False), } @@ -112,14 +112,14 @@ class ConfluenceSpaceConfiguration(AWSProperty): class DataSourceInclusionsExclusionsStrings(AWSProperty): props = { - 'DataSourceInclusionsExclusionsStrings': ([basestring], False), + 'DataSourceInclusionsExclusionsStrings': ([str], False), } class DataSourceVpcConfiguration(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], True), - 'SubnetIds': ([basestring], True), + 'SecurityGroupIds': ([str], True), + 'SubnetIds': ([str], True), } @@ -131,31 +131,31 @@ class ConfluenceConfiguration(AWSProperty): 'ExclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), 'InclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), 'PageConfiguration': (ConfluencePageConfiguration, False), - 'SecretArn': (basestring, True), - 'ServerUrl': (basestring, True), + 'SecretArn': (str, True), + 'ServerUrl': (str, True), 'SpaceConfiguration': (ConfluenceSpaceConfiguration, False), - 'Version': (basestring, True), + 'Version': (str, True), 'VpcConfiguration': (DataSourceVpcConfiguration, False), } class AclConfiguration(AWSProperty): props = { - 'AllowedGroupsColumnName': (basestring, True), + 'AllowedGroupsColumnName': (str, True), } class ChangeDetectingColumns(AWSProperty): props = { - 'ChangeDetectingColumns': ([basestring], False), + 'ChangeDetectingColumns': ([str], False), } class DataSourceToIndexFieldMapping(AWSProperty): props = { - 'DataSourceFieldName': (basestring, True), - 'DateFieldFormat': (basestring, False), - 'IndexFieldName': (basestring, True), + 'DataSourceFieldName': (str, True), + 'DateFieldFormat': (str, False), + 'IndexFieldName': (str, True), } @@ -169,26 +169,26 @@ class DataSourceToIndexFieldMappingList(AWSProperty): class ColumnConfiguration(AWSProperty): props = { 'ChangeDetectingColumns': (ChangeDetectingColumns, True), - 'DocumentDataColumnName': (basestring, True), - 'DocumentIdColumnName': (basestring, True), - 'DocumentTitleColumnName': (basestring, False), + 'DocumentDataColumnName': (str, True), + 'DocumentIdColumnName': (str, True), + 'DocumentTitleColumnName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), } class ConnectionConfiguration(AWSProperty): props = { - 'DatabaseHost': (basestring, True), - 'DatabaseName': (basestring, True), + 'DatabaseHost': (str, True), + 'DatabaseName': (str, True), 'DatabasePort': (integer, True), - 'SecretArn': (basestring, True), - 'TableName': (basestring, True), + 'SecretArn': (str, True), + 'TableName': (str, True), } class SqlConfiguration(AWSProperty): props = { - 'QueryIdentifiersEnclosingOption': (basestring, False), + 'QueryIdentifiersEnclosingOption': (str, False), } @@ -197,7 +197,7 @@ class DatabaseConfiguration(AWSProperty): 'AclConfiguration': (AclConfiguration, False), 'ColumnConfiguration': (ColumnConfiguration, True), 'ConnectionConfiguration': (ConnectionConfiguration, True), - 'DatabaseEngineType': (basestring, True), + 'DatabaseEngineType': (str, True), 'SqlConfiguration': (SqlConfiguration, False), 'VpcConfiguration': (DataSourceVpcConfiguration, False), } @@ -205,19 +205,19 @@ class DatabaseConfiguration(AWSProperty): class ExcludeMimeTypesList(AWSProperty): props = { - 'ExcludeMimeTypesList': ([basestring], False), + 'ExcludeMimeTypesList': ([str], False), } class ExcludeSharedDrivesList(AWSProperty): props = { - 'ExcludeSharedDrivesList': ([basestring], False), + 'ExcludeSharedDrivesList': ([str], False), } class ExcludeUserAccountsList(AWSProperty): props = { - 'ExcludeUserAccountsList': ([basestring], False), + 'ExcludeUserAccountsList': ([str], False), } @@ -229,20 +229,20 @@ class GoogleDriveConfiguration(AWSProperty): 'ExclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), 'InclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), - 'SecretArn': (basestring, True), + 'SecretArn': (str, True), } class OneDriveUserList(AWSProperty): props = { - 'OneDriveUserList': ([basestring], False), + 'OneDriveUserList': ([str], False), } class S3Path(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, True), + 'Bucket': (str, True), + 'Key': (str, True), } @@ -260,20 +260,20 @@ class OneDriveConfiguration(AWSProperty): 'FieldMappings': (DataSourceToIndexFieldMappingList, False), 'InclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), 'OneDriveUsers': (OneDriveUsers, True), - 'SecretArn': (basestring, True), - 'TenantDomain': (basestring, True), + 'SecretArn': (str, True), + 'TenantDomain': (str, True), } class AccessControlListConfiguration(AWSProperty): props = { - 'KeyPath': (basestring, False), + 'KeyPath': (str, False), } class DocumentsMetadataConfiguration(AWSProperty): props = { - 'S3Prefix': (basestring, False), + 'S3Prefix': (str, False), } @@ -281,7 +281,7 @@ class S3DataSourceConfiguration(AWSProperty): props = { 'AccessControlListConfiguration': (AccessControlListConfiguration, False), - 'BucketName': (basestring, True), + 'BucketName': (str, True), 'DocumentsMetadataConfiguration': (DocumentsMetadataConfiguration, False), 'ExclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), @@ -292,14 +292,14 @@ class S3DataSourceConfiguration(AWSProperty): class SalesforceChatterFeedIncludeFilterTypes(AWSProperty): props = { - 'SalesforceChatterFeedIncludeFilterTypes': ([basestring], False), + 'SalesforceChatterFeedIncludeFilterTypes': ([str], False), } class SalesforceChatterFeedConfiguration(AWSProperty): props = { - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), 'IncludeFilterTypes': (SalesforceChatterFeedIncludeFilterTypes, False), @@ -308,10 +308,10 @@ class SalesforceChatterFeedConfiguration(AWSProperty): class SalesforceCustomKnowledgeArticleTypeConfiguration(AWSProperty): props = { - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -324,14 +324,14 @@ class SalesforceCustomKnowledgeArticleTypeConfigurationList(AWSProperty): class SalesforceKnowledgeArticleStateList(AWSProperty): props = { - 'SalesforceKnowledgeArticleStateList': ([basestring], False), + 'SalesforceKnowledgeArticleStateList': ([str], False), } class SalesforceStandardKnowledgeArticleTypeConfiguration(AWSProperty): props = { - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), } @@ -348,17 +348,17 @@ class SalesforceKnowledgeArticleConfiguration(AWSProperty): class SalesforceStandardObjectAttachmentConfiguration(AWSProperty): props = { - 'DocumentTitleFieldName': (basestring, False), + 'DocumentTitleFieldName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), } class SalesforceStandardObjectConfiguration(AWSProperty): props = { - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), - 'Name': (basestring, True), + 'Name': (str, True), } @@ -380,8 +380,8 @@ class SalesforceConfiguration(AWSProperty): (DataSourceInclusionsExclusionsStrings, False), 'KnowledgeArticleConfiguration': (SalesforceKnowledgeArticleConfiguration, False), - 'SecretArn': (basestring, True), - 'ServerUrl': (basestring, True), + 'SecretArn': (str, True), + 'ServerUrl': (str, True), 'StandardObjectAttachmentConfiguration': (SalesforceStandardObjectAttachmentConfiguration, False), 'StandardObjectConfigurations': @@ -392,8 +392,8 @@ class SalesforceConfiguration(AWSProperty): class ServiceNowKnowledgeArticleConfiguration(AWSProperty): props = { 'CrawlAttachments': (boolean, False), - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'ExcludeAttachmentFilePatterns': (DataSourceInclusionsExclusionsStrings, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), @@ -405,8 +405,8 @@ class ServiceNowKnowledgeArticleConfiguration(AWSProperty): class ServiceNowServiceCatalogConfiguration(AWSProperty): props = { 'CrawlAttachments': (boolean, False), - 'DocumentDataFieldName': (basestring, True), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentDataFieldName': (str, True), + 'DocumentTitleFieldName': (str, False), 'ExcludeAttachmentFilePatterns': (DataSourceInclusionsExclusionsStrings, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), @@ -417,13 +417,13 @@ class ServiceNowServiceCatalogConfiguration(AWSProperty): class ServiceNowConfiguration(AWSProperty): props = { - 'HostUrl': (basestring, True), + 'HostUrl': (str, True), 'KnowledgeArticleConfiguration': (ServiceNowKnowledgeArticleConfiguration, False), - 'SecretArn': (basestring, True), + 'SecretArn': (str, True), 'ServiceCatalogConfiguration': (ServiceNowServiceCatalogConfiguration, False), - 'ServiceNowBuildVersion': (basestring, True), + 'ServiceNowBuildVersion': (str, True), } @@ -431,13 +431,13 @@ class SharePointConfiguration(AWSProperty): props = { 'CrawlAttachments': (boolean, False), 'DisableLocalGroups': (boolean, False), - 'DocumentTitleFieldName': (basestring, False), + 'DocumentTitleFieldName': (str, False), 'ExclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), 'FieldMappings': (DataSourceToIndexFieldMappingList, False), 'InclusionPatterns': (DataSourceInclusionsExclusionsStrings, False), - 'SecretArn': (basestring, True), - 'SharePointVersion': (basestring, True), - 'Urls': ([basestring], True), + 'SecretArn': (str, True), + 'SharePointVersion': (str, True), + 'Urls': ([str], True), 'UseChangeLog': (boolean, False), 'VpcConfiguration': (DataSourceVpcConfiguration, False), } @@ -461,13 +461,13 @@ class DataSource(AWSObject): props = { 'DataSourceConfiguration': (DataSourceConfiguration, False), - 'Description': (basestring, False), - 'IndexId': (basestring, True), - 'Name': (basestring, True), - 'RoleArn': (basestring, False), - 'Schedule': (basestring, False), + 'Description': (str, False), + 'IndexId': (str, True), + 'Name': (str, True), + 'RoleArn': (str, False), + 'Schedule': (str, False), 'Tags': (Tags, False), - 'Type': (basestring, True), + 'Type': (str, True), } @@ -475,11 +475,11 @@ class Faq(AWSObject): resource_type = "AWS::Kendra::Faq" props = { - 'Description': (basestring, False), - 'FileFormat': (basestring, False), - 'IndexId': (basestring, True), - 'Name': (basestring, True), - 'RoleArn': (basestring, True), + 'Description': (str, False), + 'FileFormat': (str, False), + 'IndexId': (str, True), + 'Name': (str, True), + 'RoleArn': (str, True), 'S3Path': (S3Path, True), 'Tags': (Tags, False), } @@ -494,7 +494,7 @@ class CapacityUnitsConfiguration(AWSProperty): class ValueImportanceItem(AWSProperty): props = { - 'Key': (basestring, False), + 'Key': (str, False), 'Value': (integer, False), } @@ -507,10 +507,10 @@ class ValueImportanceItems(AWSProperty): class Relevance(AWSProperty): props = { - 'Duration': (basestring, False), + 'Duration': (str, False), 'Freshness': (boolean, False), 'Importance': (integer, False), - 'RankOrder': (basestring, False), + 'RankOrder': (str, False), 'ValueImportanceItems': (ValueImportanceItems, False), } @@ -526,35 +526,35 @@ class Search(AWSProperty): class DocumentMetadataConfiguration(AWSProperty): props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Relevance': (Relevance, False), 'Search': (Search, False), - 'Type': (basestring, True), + 'Type': (str, True), } class ServerSideEncryptionConfiguration(AWSProperty): props = { - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), } class JsonTokenTypeConfiguration(AWSProperty): props = { - 'GroupAttributeField': (basestring, True), - 'UserNameAttributeField': (basestring, True), + 'GroupAttributeField': (str, True), + 'UserNameAttributeField': (str, True), } class JwtTokenTypeConfiguration(AWSProperty): props = { - 'ClaimRegex': (basestring, False), - 'GroupAttributeField': (basestring, False), - 'Issuer': (basestring, False), - 'KeyLocation': (basestring, True), - 'SecretManagerArn': (basestring, False), - 'URL': (basestring, False), - 'UserNameAttributeField': (basestring, False), + 'ClaimRegex': (str, False), + 'GroupAttributeField': (str, False), + 'Issuer': (str, False), + 'KeyLocation': (str, True), + 'SecretManagerArn': (str, False), + 'URL': (str, False), + 'UserNameAttributeField': (str, False), } @@ -570,15 +570,15 @@ class Index(AWSObject): props = { 'CapacityUnits': (CapacityUnitsConfiguration, False), - 'Description': (basestring, False), + 'Description': (str, False), 'DocumentMetadataConfigurations': ([DocumentMetadataConfiguration], False), - 'Edition': (basestring, True), - 'Name': (basestring, True), - 'RoleArn': (basestring, True), + 'Edition': (str, True), + 'Name': (str, True), + 'RoleArn': (str, True), 'ServerSideEncryptionConfiguration': (ServerSideEncryptionConfiguration, False), 'Tags': (Tags, False), - 'UserContextPolicy': (basestring, False), + 'UserContextPolicy': (str, False), 'UserTokenConfigurations': ([UserTokenConfiguration], False), } diff --git a/troposphere/kinesis.py b/troposphere/kinesis.py index 33501e9a6..e7d762354 100644 --- a/troposphere/kinesis.py +++ b/troposphere/kinesis.py @@ -9,8 +9,8 @@ class StreamEncryption(AWSProperty): props = { - 'EncryptionType': (basestring, True), - 'KeyId': (basestring, True), + 'EncryptionType': (str, True), + 'KeyId': (str, True), } @@ -18,7 +18,7 @@ class Stream(AWSObject): resource_type = "AWS::Kinesis::Stream" props = { - 'Name': (basestring, False), + 'Name': (str, False), 'RetentionPeriodHours': (integer, False), 'ShardCount': (integer, True), 'StreamEncryption': (StreamEncryption, False), @@ -30,6 +30,6 @@ class StreamConsumer(AWSObject): resource_type = "AWS::Kinesis::StreamConsumer" props = { - 'ConsumerName': (basestring, True), - 'StreamARN': (basestring, True), + 'ConsumerName': (str, True), + 'StreamARN': (str, True), } diff --git a/troposphere/kinesisanalyticsv2.py b/troposphere/kinesisanalyticsv2.py index b117d9c45..5864b82db 100644 --- a/troposphere/kinesisanalyticsv2.py +++ b/troposphere/kinesisanalyticsv2.py @@ -22,30 +22,30 @@ def validate_runtime_environment(runtime_environment): class S3ContentLocation(AWSProperty): props = { - 'BucketARN': (basestring, False), - 'FileKey': (basestring, False), - 'ObjectVersion': (basestring, False) + 'BucketARN': (str, False), + 'FileKey': (str, False), + 'ObjectVersion': (str, False) } class CodeContent(AWSProperty): props = { 'S3ContentLocation': (S3ContentLocation, False), - 'TextContent': (basestring, False), - 'ZipFileContent': (basestring, False), + 'TextContent': (str, False), + 'ZipFileContent': (str, False), } class ApplicationCodeConfiguration(AWSProperty): props = { 'CodeContent': (CodeContent, True), - 'CodeContentType': (basestring, True), + 'CodeContentType': (str, True), } class PropertyGroup(AWSProperty): props = { - 'PropertyGroupId': (basestring, False), + 'PropertyGroupId': (str, False), 'PropertyMap': (dict, False), } @@ -58,7 +58,7 @@ class EnvironmentProperties(AWSProperty): class CheckpointConfiguration(AWSProperty): props = { - 'ConfigurationType': (basestring, True), + 'ConfigurationType': (str, True), 'CheckpointInterval': (integer, False), 'CheckpointingEnabled': (boolean, False), 'MinPauseBetweenCheckpoints': (integer, False), @@ -67,16 +67,16 @@ class CheckpointConfiguration(AWSProperty): class MonitoringConfiguration(AWSProperty): props = { - 'ConfigurationType': (basestring, True), - 'LogLevel': (basestring, False), - 'MetricsLevel': (basestring, False), + 'ConfigurationType': (str, True), + 'LogLevel': (str, False), + 'MetricsLevel': (str, False), } class ParallelismConfiguration(AWSProperty): props = { 'AutoScalingEnabled': (boolean, False), - 'ConfigurationType': (basestring, True), + 'ConfigurationType': (str, True), 'Parallelism': (integer, False), 'ParallelismPerKPU': (integer, False), } @@ -98,7 +98,7 @@ class InputParallelism(AWSProperty): class InputLambdaProcessor(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } @@ -110,22 +110,22 @@ class InputProcessingConfiguration(AWSProperty): class RecordColumn(AWSProperty): props = { - 'Mapping': (basestring, False), - 'Name': (basestring, True), - 'SqlType': (basestring, True), + 'Mapping': (str, False), + 'Name': (str, True), + 'SqlType': (str, True), } class JSONMappingParameters(AWSProperty): props = { - 'RecordRowPath': (basestring, True), + 'RecordRowPath': (str, True), } class CSVMappingParameters(AWSProperty): props = { - 'RecordColumnDelimiter': (basestring, True), - 'RecordRowDelimiter': (basestring, True), + 'RecordColumnDelimiter': (str, True), + 'RecordRowDelimiter': (str, True), } @@ -139,27 +139,27 @@ class MappingParameters(AWSProperty): class RecordFormat(AWSProperty): props = { 'MappingParameters': (MappingParameters, False), - 'RecordFormatType': (basestring, True), + 'RecordFormatType': (str, True), } class InputSchema(AWSProperty): props = { 'RecordColumns': ([RecordColumn], True), - 'RecordEncoding': (basestring, False), + 'RecordEncoding': (str, False), 'RecordFormat': (RecordFormat, True), } class KinesisStreamsInput(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } class KinesisFirehoseInput(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } @@ -170,7 +170,7 @@ class Input(AWSProperty): 'InputSchema': (InputSchema, True), 'KinesisFirehoseInput': (KinesisFirehoseInput, False), 'KinesisStreamsInput': (KinesisStreamsInput, False), - 'NamePrefix': (basestring, False), + 'NamePrefix': (str, False), } @@ -201,16 +201,16 @@ class Application(AWSObject): props = { 'ApplicationConfiguration': (ApplicationConfiguration, False), - 'ApplicationDescription': (basestring, False), - 'ApplicationName': (basestring, False), + 'ApplicationDescription': (str, False), + 'ApplicationName': (str, False), 'RuntimeEnvironment': (validate_runtime_environment, True), - 'ServiceExecutionRole': (basestring, True), + 'ServiceExecutionRole': (str, True), } class CloudWatchLoggingOption(AWSProperty): props = { - 'LogStreamARN': (basestring, True), + 'LogStreamARN': (str, True), } @@ -219,21 +219,21 @@ class ApplicationCloudWatchLoggingOption(AWSObject): "AWS::KinesisAnalyticsV2::ApplicationCloudWatchLoggingOption" props = { - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'CloudWatchLoggingOption': (CloudWatchLoggingOption, True), } class S3ReferenceDataSource(AWSProperty): props = { - 'BucketARN': (basestring, False), - 'FileKey': (basestring, False), + 'BucketARN': (str, False), + 'FileKey': (str, False), } class ReferenceSchema(AWSProperty): props = { - 'RecordEncoding': (basestring, False), + 'RecordEncoding': (str, False), 'RecordColumns': ([RecordColumn], True), 'RecordFormat': (RecordFormat, True), } @@ -242,7 +242,7 @@ class ReferenceSchema(AWSProperty): class ReferenceDataSource(AWSProperty): props = { 'ReferenceSchema': (ReferenceSchema, True), - 'TableName': (basestring, False), + 'TableName': (str, False), 'S3ReferenceDataSource': (S3ReferenceDataSource, False), } @@ -251,32 +251,32 @@ class ApplicationReferenceDataSource(AWSObject): resource_type = "AWS::KinesisAnalyticsV2::ApplicationReferenceDataSource" props = { - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'ReferenceDataSource': (ReferenceDataSource, True), } class LambdaOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } class KinesisFirehoseOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } class KinesisStreamsOutput(AWSProperty): props = { - 'ResourceARN': (basestring, True), + 'ResourceARN': (str, True), } class DestinationSchema(AWSProperty): props = { - 'RecordFormatType': (basestring, False), + 'RecordFormatType': (str, False), } @@ -286,7 +286,7 @@ class Output(AWSProperty): "LambdaOutput": (LambdaOutput, False), "KinesisFirehoseOutput": (KinesisFirehoseOutput, False), "KinesisStreamsOutput": (KinesisStreamsOutput, False), - "Name": (basestring, False), + "Name": (str, False), } @@ -294,6 +294,6 @@ class ApplicationOutput(AWSObject): resource_type = "AWS::KinesisAnalyticsV2::ApplicationOutput" props = { - 'ApplicationName': (basestring, True), + 'ApplicationName': (str, True), 'Output': (Output, True), } diff --git a/troposphere/kms.py b/troposphere/kms.py index 21dce0079..0c60b3b99 100644 --- a/troposphere/kms.py +++ b/troposphere/kms.py @@ -12,8 +12,8 @@ class Alias(AWSObject): resource_type = "AWS::KMS::Alias" props = { - 'AliasName': (basestring, True), - 'TargetKeyId': (basestring, True) + 'AliasName': (str, True), + 'TargetKeyId': (str, True) } @@ -21,11 +21,11 @@ class Key(AWSObject): resource_type = "AWS::KMS::Key" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'EnableKeyRotation': (boolean, False), 'Enabled': (boolean, False), 'KeyPolicy': (policytypes, True), - 'KeySpec': (basestring, False), + 'KeySpec': (str, False), 'KeyUsage': (key_usage_type, False), 'PendingWindowInDays': (integer_range(7, 30), False), 'Tags': ((Tags, list), False) diff --git a/troposphere/lakeformation.py b/troposphere/lakeformation.py index fb97f637b..81adedcfb 100644 --- a/troposphere/lakeformation.py +++ b/troposphere/lakeformation.py @@ -26,41 +26,41 @@ class DataLakeSettings(AWSObject): class DataLakePrincipal(AWSProperty): props = { - 'DataLakePrincipalIdentifier': (basestring, False), + 'DataLakePrincipalIdentifier': (str, False), } class DatabaseResource(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), } class TableResource(AWSProperty): props = { - 'DatabaseName': (basestring, False), - 'Name': (basestring, False), + 'DatabaseName': (str, False), + 'Name': (str, False), } class DataLocationResource(AWSProperty): props = { - 'S3Resource': (basestring, False), + 'S3Resource': (str, False), } class ColumnWildcard(AWSProperty): props = { - 'ExcludedColumnNames': ([basestring], False), + 'ExcludedColumnNames': ([str], False), } class TableWithColumnsResource(AWSProperty): props = { - 'ColumnNames': ([basestring], False), + 'ColumnNames': ([str], False), 'ColumnWildcard': (ColumnWildcard, False), - 'DatabaseName': (basestring, False), - 'Name': (basestring, False), + 'DatabaseName': (str, False), + 'Name': (str, False), } @@ -78,7 +78,7 @@ class Permissions(AWSObject): props = { 'DataLakePrincipal': (DataLakePrincipal, True), - 'Permissions': ([basestring], False), - 'PermissionsWithGrantOption': ([basestring], False), + 'Permissions': ([str], False), + 'PermissionsWithGrantOption': ([str], False), 'Resource': (Resource, True), } diff --git a/troposphere/licensemanager.py b/troposphere/licensemanager.py index 44e0d1617..8339ba725 100644 --- a/troposphere/licensemanager.py +++ b/troposphere/licensemanager.py @@ -17,12 +17,12 @@ class Grant(AWSObject): resource_type = "AWS::LicenseManager::Grant" props = { - 'AllowedOperations': ([basestring], False), - 'GrantName': (basestring, False), - 'HomeRegion': (basestring, False), - 'LicenseArn': (basestring, False), - 'Principals': ([basestring], False), - 'Status': (basestring, False), + 'AllowedOperations': ([str], False), + 'GrantName': (str, False), + 'HomeRegion': (str, False), + 'LicenseArn': (str, False), + 'Principals': ([str], False), + 'Status': (str, False), } @@ -43,7 +43,7 @@ class ConsumptionConfiguration(AWSProperty): props = { 'BorrowConfiguration': (BorrowConfiguration, False), 'ProvisionalConfiguration': (ProvisionalConfiguration, False), - 'RenewType': (basestring, False), + 'RenewType': (str, False), } @@ -51,31 +51,31 @@ class Entitlement(AWSProperty): props = { 'AllowCheckIn': (boolean, False), 'MaxCount': (integer, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Overage': (boolean, False), - 'Unit': (basestring, True), - 'Value': (basestring, False), + 'Unit': (str, True), + 'Value': (str, False), } class IssuerData(AWSProperty): props = { - 'Name': (basestring, True), - 'SignKey': (basestring, False), + 'Name': (str, True), + 'SignKey': (str, False), } class Metadata(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True), + 'Name': (str, True), + 'Value': (str, True), } class ValidityDateFormat(AWSProperty): props = { - 'Begin': (basestring, True), - 'End': (basestring, True), + 'Begin': (str, True), + 'End': (str, True), } @@ -83,15 +83,15 @@ class License(AWSObject): resource_type = "AWS::LicenseManager::License" props = { - 'Beneficiary': (basestring, False), + 'Beneficiary': (str, False), 'ConsumptionConfiguration': (ConsumptionConfiguration, True), 'Entitlements': ([Entitlement], True), - 'HomeRegion': (basestring, True), + 'HomeRegion': (str, True), 'Issuer': (IssuerData, True), 'LicenseMetadata': ([Metadata], False), - 'LicenseName': (basestring, True), - 'ProductName': (basestring, True), - 'ProductSKU': (basestring, False), - 'Status': (basestring, False), + 'LicenseName': (str, True), + 'ProductName': (str, True), + 'ProductSKU': (str, False), + 'Status': (str, False), 'Validity': (ValidityDateFormat, True), } diff --git a/troposphere/logs.py b/troposphere/logs.py index 2abd5b7b7..9becfa657 100644 --- a/troposphere/logs.py +++ b/troposphere/logs.py @@ -7,10 +7,10 @@ class Destination(AWSObject): resource_type = "AWS::Logs::Destination" props = { - 'DestinationName': (basestring, True), - 'DestinationPolicy': (basestring, True), - 'RoleArn': (basestring, True), - 'TargetArn': (basestring, True), + 'DestinationName': (str, True), + 'DestinationPolicy': (str, True), + 'RoleArn': (str, True), + 'TargetArn': (str, True), } @@ -18,7 +18,7 @@ class LogGroup(AWSObject): resource_type = "AWS::Logs::LogGroup" props = { - 'LogGroupName': (basestring, False), + 'LogGroupName': (str, False), 'RetentionInDays': (integer_list_item(RETENTION_DAYS), False), } @@ -27,17 +27,17 @@ class LogStream(AWSObject): resource_type = "AWS::Logs::LogStream" props = { - 'LogGroupName': (basestring, True), - 'LogStreamName': (basestring, False) + 'LogGroupName': (str, True), + 'LogStreamName': (str, False) } class MetricTransformation(AWSProperty): props = { 'DefaultValue': (float, False), - 'MetricName': (basestring, True), - 'MetricNamespace': (basestring, True), - 'MetricValue': (basestring, True), + 'MetricName': (str, True), + 'MetricNamespace': (str, True), + 'MetricValue': (str, True), } @@ -45,8 +45,8 @@ class MetricFilter(AWSObject): resource_type = "AWS::Logs::MetricFilter" props = { - 'FilterPattern': (basestring, True), - 'LogGroupName': (basestring, True), + 'FilterPattern': (str, True), + 'LogGroupName': (str, True), 'MetricTransformations': ([MetricTransformation], True), } @@ -55,8 +55,8 @@ class SubscriptionFilter(AWSObject): resource_type = "AWS::Logs::SubscriptionFilter" props = { - 'DestinationArn': (basestring, True), - 'FilterPattern': (basestring, True), - 'LogGroupName': (basestring, True), - 'RoleArn': (basestring, False), + 'DestinationArn': (str, True), + 'FilterPattern': (str, True), + 'LogGroupName': (str, True), + 'RoleArn': (str, False), } diff --git a/troposphere/lookoutvision.py b/troposphere/lookoutvision.py index f45c5853a..59dc68cf1 100644 --- a/troposphere/lookoutvision.py +++ b/troposphere/lookoutvision.py @@ -14,5 +14,5 @@ class Project(AWSObject): resource_type = "AWS::LookoutVision::Project" props = { - 'ProjectName': (basestring, True), + 'ProjectName': (str, True), } diff --git a/troposphere/macie.py b/troposphere/macie.py index 5f2443920..ca83d9047 100644 --- a/troposphere/macie.py +++ b/troposphere/macie.py @@ -23,12 +23,12 @@ class CustomDataIdentifier(AWSObject): resource_type = "AWS::Macie::CustomDataIdentifier" props = { - 'Description': (basestring, False), - 'IgnoreWords': ([basestring], False), - 'Keywords': ([basestring], False), + 'Description': (str, False), + 'IgnoreWords': ([str], False), + 'Keywords': ([str], False), 'MaximumMatchDistance': (integer, False), - 'Name': (basestring, True), - 'Regex': (basestring, True) + 'Name': (str, True), + 'Regex': (str, True) } @@ -43,8 +43,8 @@ class FindingsFilter(AWSObject): props = { 'Action': (findingsfilter_action, False), - 'Description': (basestring, False), + 'Description': (str, False), 'FindingCriteria': (FindingCriteria, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Position': (integer, False) } diff --git a/troposphere/managedblockchain.py b/troposphere/managedblockchain.py index 46586758a..5edee5a94 100644 --- a/troposphere/managedblockchain.py +++ b/troposphere/managedblockchain.py @@ -14,8 +14,8 @@ class MemberFabricConfiguration(AWSProperty): props = { - 'AdminPassword': (basestring, True), - 'AdminUsername': (basestring, True), + 'AdminPassword': (str, True), + 'AdminUsername': (str, True), } @@ -27,16 +27,16 @@ class MemberFrameworkConfiguration(AWSProperty): class MemberConfiguration(AWSProperty): props = { - 'Description': (basestring, False), + 'Description': (str, False), 'MemberFrameworkConfiguration': (MemberFrameworkConfiguration, False), - 'Name': (basestring, True), + 'Name': (str, True), } class NetworkFabricConfiguration(AWSProperty): props = { - 'Edition': (basestring, True), + 'Edition': (str, True), } @@ -49,7 +49,7 @@ class NetworkFrameworkConfiguration(AWSProperty): class ApprovalThresholdPolicy(AWSProperty): props = { 'ProposalDurationInHours': (integer, False), - 'ThresholdComparator': (basestring, False), + 'ThresholdComparator': (str, False), 'ThresholdPercentage': (integer, False), } @@ -62,10 +62,10 @@ class VotingPolicy(AWSProperty): class NetworkConfiguration(AWSProperty): props = { - 'Description': (basestring, False), - 'Framework': (basestring, True), - 'FrameworkVersion': (basestring, True), - 'Name': (basestring, True), + 'Description': (str, False), + 'Framework': (str, True), + 'FrameworkVersion': (str, True), + 'Name': (str, True), 'NetworkFrameworkConfiguration': (NetworkFrameworkConfiguration, False), 'VotingPolicy': (VotingPolicy, True), @@ -76,17 +76,17 @@ class Member(AWSObject): resource_type = "AWS::ManagedBlockchain::Member" props = { - 'InvitationId': (basestring, False), + 'InvitationId': (str, False), 'MemberConfiguration': (MemberConfiguration, True), 'NetworkConfiguration': (NetworkConfiguration, False), - 'NetworkId': (basestring, False), + 'NetworkId': (str, False), } class NodeConfiguration(AWSProperty): props = { - 'AvailabilityZone': (basestring, True), - 'InstanceType': (basestring, True), + 'AvailabilityZone': (str, True), + 'InstanceType': (str, True), } @@ -94,7 +94,7 @@ class Node(AWSObject): resource_type = "AWS::ManagedBlockchain::Node" props = { - 'MemberId': (basestring, True), - 'NetworkId': (basestring, True), + 'MemberId': (str, True), + 'NetworkId': (str, True), 'NodeConfiguration': (NodeConfiguration, True), } diff --git a/troposphere/mediaconnect.py b/troposphere/mediaconnect.py index 097c042cc..02efbd7b8 100644 --- a/troposphere/mediaconnect.py +++ b/troposphere/mediaconnect.py @@ -15,39 +15,39 @@ class FailoverConfig(AWSProperty): props = { 'RecoveryWindow': (integer, False), - 'State': (basestring, False), + 'State': (str, False), } class Encryption(AWSProperty): props = { - 'Algorithm': (basestring, True), - 'ConstantInitializationVector': (basestring, False), - 'DeviceId': (basestring, False), - 'KeyType': (basestring, False), - 'Region': (basestring, False), - 'ResourceId': (basestring, False), - 'RoleArn': (basestring, True), - 'SecretArn': (basestring, False), - 'Url': (basestring, False), + 'Algorithm': (str, True), + 'ConstantInitializationVector': (str, False), + 'DeviceId': (str, False), + 'KeyType': (str, False), + 'Region': (str, False), + 'ResourceId': (str, False), + 'RoleArn': (str, True), + 'SecretArn': (str, False), + 'Url': (str, False), } class Source(AWSProperty): props = { 'Decryption': (Encryption, False), - 'Description': (basestring, False), - 'EntitlementArn': (basestring, False), - 'IngestIp': (basestring, False), + 'Description': (str, False), + 'EntitlementArn': (str, False), + 'IngestIp': (str, False), 'IngestPort': (integer, False), 'MaxBitrate': (integer, False), 'MaxLatency': (integer, False), - 'Name': (basestring, False), - 'Protocol': (basestring, False), - 'SourceArn': (basestring, False), - 'StreamId': (basestring, False), - 'VpcInterfaceName': (basestring, False), - 'WhitelistCidr': (basestring, False), + 'Name': (str, False), + 'Protocol': (str, False), + 'SourceArn': (str, False), + 'StreamId': (str, False), + 'VpcInterfaceName': (str, False), + 'WhitelistCidr': (str, False), } @@ -55,8 +55,8 @@ class Flow(AWSObject): resource_type = "AWS::MediaConnect::Flow" props = { - 'AvailabilityZone': (basestring, False), - 'Name': (basestring, True), + 'AvailabilityZone': (str, False), + 'Name': (str, True), 'Source': (Source, True), 'SourceFailoverConfig': (FailoverConfig, False), } @@ -67,18 +67,18 @@ class FlowEntitlement(AWSObject): props = { 'DataTransferSubscriberFeePercent': (integer, False), - 'Description': (basestring, True), + 'Description': (str, True), 'Encryption': (Encryption, False), - 'EntitlementStatus': (basestring, False), - 'FlowArn': (basestring, True), - 'Name': (basestring, True), - 'Subscribers': ([basestring], True), + 'EntitlementStatus': (str, False), + 'FlowArn': (str, True), + 'Name': (str, True), + 'Subscribers': ([str], True), } class VpcInterfaceAttachment(AWSProperty): props = { - 'VpcInterfaceName': (basestring, False), + 'VpcInterfaceName': (str, False), } @@ -86,18 +86,18 @@ class FlowOutput(AWSObject): resource_type = "AWS::MediaConnect::FlowOutput" props = { - 'CidrAllowList': ([basestring], False), - 'Description': (basestring, False), - 'Destination': (basestring, False), + 'CidrAllowList': ([str], False), + 'Description': (str, False), + 'Destination': (str, False), 'Encryption': (Encryption, False), - 'FlowArn': (basestring, True), + 'FlowArn': (str, True), 'MaxLatency': (integer, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Port': (integer, False), - 'Protocol': (basestring, True), - 'RemoteId': (basestring, False), + 'Protocol': (str, True), + 'RemoteId': (str, False), 'SmoothingLatency': (integer, False), - 'StreamId': (basestring, False), + 'StreamId': (str, False), 'VpcInterfaceAttachment': (VpcInterfaceAttachment, False), } @@ -107,17 +107,17 @@ class FlowSource(AWSObject): props = { 'Decryption': (Encryption, False), - 'Description': (basestring, True), - 'EntitlementArn': (basestring, False), - 'FlowArn': (basestring, False), + 'Description': (str, True), + 'EntitlementArn': (str, False), + 'FlowArn': (str, False), 'IngestPort': (integer, False), 'MaxBitrate': (integer, False), 'MaxLatency': (integer, False), - 'Name': (basestring, True), - 'Protocol': (basestring, False), - 'StreamId': (basestring, False), - 'VpcInterfaceName': (basestring, False), - 'WhitelistCidr': (basestring, False), + 'Name': (str, True), + 'Protocol': (str, False), + 'StreamId': (str, False), + 'VpcInterfaceName': (str, False), + 'WhitelistCidr': (str, False), } @@ -125,9 +125,9 @@ class FlowVpcInterface(AWSObject): resource_type = "AWS::MediaConnect::FlowVpcInterface" props = { - 'FlowArn': (basestring, True), - 'Name': (basestring, True), - 'RoleArn': (basestring, True), - 'SecurityGroupIds': ([basestring], True), - 'SubnetId': (basestring, True), + 'FlowArn': (str, True), + 'Name': (str, True), + 'RoleArn': (str, True), + 'SecurityGroupIds': ([str], True), + 'SubnetId': (str, True), } diff --git a/troposphere/mediaconvert.py b/troposphere/mediaconvert.py index 466729323..d59e80c34 100644 --- a/troposphere/mediaconvert.py +++ b/troposphere/mediaconvert.py @@ -14,7 +14,7 @@ class AccelerationSettings(AWSProperty): props = { - 'Mode': (basestring, True), + 'Mode': (str, True), } @@ -23,13 +23,13 @@ class JobTemplate(AWSObject): props = { 'AccelerationSettings': (AccelerationSettings, False), - 'Category': (basestring, False), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Category': (str, False), + 'Description': (str, False), + 'Name': (str, False), 'Priority': (integer, False), - 'Queue': (basestring, False), + 'Queue': (str, False), 'SettingsJson': (dict, True), - 'StatusUpdateInterval': (basestring, False), + 'StatusUpdateInterval': (str, False), 'Tags': (dict, False), } @@ -38,9 +38,9 @@ class Preset(AWSObject): resource_type = "AWS::MediaConvert::Preset" props = { - 'Category': (basestring, False), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Category': (str, False), + 'Description': (str, False), + 'Name': (str, False), 'SettingsJson': (dict, True), 'Tags': (dict, False), } @@ -50,9 +50,9 @@ class Queue(AWSObject): resource_type = "AWS::MediaConvert::Queue" props = { - 'Description': (basestring, False), - 'Name': (basestring, False), - 'PricingPlan': (basestring, False), - 'Status': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), + 'PricingPlan': (str, False), + 'Status': (str, False), 'Tags': (dict, False), } diff --git a/troposphere/medialive.py b/troposphere/medialive.py index 1ddf09516..561c8722e 100644 --- a/troposphere/medialive.py +++ b/troposphere/medialive.py @@ -12,8 +12,8 @@ class AudioLanguageSelection(AWSProperty): props = { - 'LanguageCode': (basestring, False), - 'LanguageSelectionPolicy': (basestring, False), + 'LanguageCode': (str, False), + 'LanguageSelectionPolicy': (str, False), } @@ -32,7 +32,7 @@ class AudioSelectorSettings(AWSProperty): class AudioSelector(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), 'SelectorSettings': (AudioSelectorSettings, False), } @@ -50,8 +50,8 @@ class DvbSubSourceSettings(AWSProperty): class EmbeddedSourceSettings(AWSProperty): props = { - 'Convert608To708': (basestring, False), - 'Scte20Detection': (basestring, False), + 'Convert608To708': (str, False), + 'Scte20Detection': (str, False), 'Source608ChannelNumber': (integer, False), 'Source608TrackNumber': (integer, False), } @@ -59,7 +59,7 @@ class EmbeddedSourceSettings(AWSProperty): class Scte20SourceSettings(AWSProperty): props = { - 'Convert608To708': (basestring, False), + 'Convert608To708': (str, False), 'Source608ChannelNumber': (integer, False), } @@ -72,7 +72,7 @@ class Scte27SourceSettings(AWSProperty): class TeletextSourceSettings(AWSProperty): props = { - 'PageNumber': (basestring, False), + 'PageNumber': (str, False), } @@ -89,8 +89,8 @@ class CaptionSelectorSettings(AWSProperty): class CaptionSelector(AWSProperty): props = { - 'LanguageCode': (basestring, False), - 'Name': (basestring, False), + 'LanguageCode': (str, False), + 'Name': (str, False), 'SelectorSettings': (CaptionSelectorSettings, False), } @@ -107,7 +107,7 @@ class HlsInputSettings(AWSProperty): class NetworkInputSettings(AWSProperty): props = { 'HlsInputSettings': (HlsInputSettings, False), - 'ServerValidation': (basestring, False), + 'ServerValidation': (str, False), } @@ -132,8 +132,8 @@ class VideoSelectorSettings(AWSProperty): class VideoSelector(AWSProperty): props = { - 'ColorSpace': (basestring, False), - 'ColorSpaceUsage': (basestring, False), + 'ColorSpace': (str, False), + 'ColorSpaceUsage': (str, False), 'SelectorSettings': (VideoSelectorSettings, False), } @@ -142,50 +142,50 @@ class InputSettings(AWSProperty): props = { 'AudioSelectors': ([AudioSelector], False), 'CaptionSelectors': ([CaptionSelector], False), - 'DeblockFilter': (basestring, False), - 'DenoiseFilter': (basestring, False), + 'DeblockFilter': (str, False), + 'DenoiseFilter': (str, False), 'FilterStrength': (integer, False), - 'InputFilter': (basestring, False), + 'InputFilter': (str, False), 'NetworkInputSettings': (NetworkInputSettings, False), - 'SourceEndBehavior': (basestring, False), + 'SourceEndBehavior': (str, False), 'VideoSelector': (VideoSelector, False), } class InputAttachment(AWSProperty): props = { - 'InputAttachmentName': (basestring, False), - 'InputId': (basestring, False), + 'InputAttachmentName': (str, False), + 'InputId': (str, False), 'InputSettings': (InputSettings, False), } class InputSpecification(AWSProperty): props = { - 'Codec': (basestring, False), - 'MaximumBitrate': (basestring, False), - 'Resolution': (basestring, False), + 'Codec': (str, False), + 'MaximumBitrate': (str, False), + 'Resolution': (str, False), } class MediaPackageOutputDestinationSettings(AWSProperty): props = { - 'ChannelId': (basestring, False), + 'ChannelId': (str, False), } class OutputDestinationSettings(AWSProperty): props = { - 'PasswordParam': (basestring, False), - 'StreamName': (basestring, False), - 'Url': (basestring, False), - 'Username': (basestring, False), + 'PasswordParam': (str, False), + 'StreamName': (str, False), + 'Url': (str, False), + 'Username': (str, False), } class OutputDestination(AWSProperty): props = { - 'Id': (basestring, False), + 'Id': (str, False), 'MediaPackageSettings': ([MediaPackageOutputDestinationSettings], False), 'Settings': ([OutputDestinationSettings], False), @@ -196,42 +196,42 @@ class Channel(AWSObject): resource_type = "AWS::MediaLive::Channel" props = { - 'ChannelClass': (basestring, False), + 'ChannelClass': (str, False), 'Destinations': ([OutputDestination], False), 'EncoderSettings': (dict, False), 'InputAttachments': ([InputAttachment], False), 'InputSpecification': (InputSpecification, False), - 'LogLevel': (basestring, False), - 'Name': (basestring, False), - 'RoleArn': (basestring, False), + 'LogLevel': (str, False), + 'Name': (str, False), + 'RoleArn': (str, False), 'Tags': (Tags, False), } class InputDestinationRequest(AWSProperty): props = { - 'StreamName': (basestring, False), + 'StreamName': (str, False), } class InputSourceRequest(AWSProperty): props = { - 'PasswordParam': (basestring, False), - 'Url': (basestring, False), - 'Username': (basestring, False), + 'PasswordParam': (str, False), + 'Url': (str, False), + 'Username': (str, False), } class InputVpcRequest(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], False), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], False), } class MediaConnectFlowRequest(AWSProperty): props = { - 'FlowArn': (basestring, False), + 'FlowArn': (str, False), } @@ -240,20 +240,20 @@ class Input(AWSObject): props = { 'Destinations': ([InputDestinationRequest], False), - 'InputSecurityGroups': ([basestring], False), + 'InputSecurityGroups': ([str], False), 'MediaConnectFlows': ([MediaConnectFlowRequest], False), - 'Name': (basestring, False), - 'RoleArn': (basestring, False), + 'Name': (str, False), + 'RoleArn': (str, False), 'Sources': ([InputSourceRequest], False), 'Tags': (Tags, False), - 'Type': (basestring, False), + 'Type': (str, False), 'Vpc': (InputVpcRequest, False), } class InputWhitelistRuleCidr(AWSProperty): props = { - 'Cidr': (basestring, False), + 'Cidr': (str, False), } diff --git a/troposphere/mediapackage.py b/troposphere/mediapackage.py index 9190c17e4..9d872b4b2 100644 --- a/troposphere/mediapackage.py +++ b/troposphere/mediapackage.py @@ -16,8 +16,8 @@ class EgressEndpoint(AWSProperty): props = { - 'PackagingConfigurationId': (basestring, True), - 'Url': (basestring, True), + 'PackagingConfigurationId': (str, True), + 'Url': (str, True), } @@ -26,11 +26,11 @@ class Asset(AWSObject): props = { 'EgressEndpoints': ([EgressEndpoint], False), - 'Id': (basestring, True), - 'PackagingGroupId': (basestring, True), - 'ResourceId': (basestring, False), - 'SourceArn': (basestring, True), - 'SourceRoleArn': (basestring, True), + 'Id': (str, True), + 'PackagingGroupId': (str, True), + 'ResourceId': (str, False), + 'SourceArn': (str, True), + 'SourceRoleArn': (str, True), 'Tags': (Tags, False), } @@ -39,24 +39,24 @@ class Channel(AWSObject): resource_type = "AWS::MediaPackage::Channel" props = { - 'Description': (basestring, False), - 'Id': (basestring, True), + 'Description': (str, False), + 'Id': (str, True), 'Tags': (Tags, False), } class Authorization(AWSProperty): props = { - 'CdnIdentifierSecret': (basestring, True), - 'SecretsRoleArn': (basestring, True), + 'CdnIdentifierSecret': (str, True), + 'SecretsRoleArn': (str, True), } class SpekeKeyProvider(AWSProperty): props = { - 'RoleArn': (basestring, True), - 'SystemIds': ([basestring], True), - 'Url': (basestring, True), + 'RoleArn': (str, True), + 'SystemIds': ([str], True), + 'Url': (str, True), } @@ -70,15 +70,15 @@ class StreamSelection(AWSProperty): props = { 'MaxVideoBitsPerSecond': (integer, False), 'MinVideoBitsPerSecond': (integer, False), - 'StreamOrder': (basestring, False), + 'StreamOrder': (str, False), } class HlsManifest(AWSProperty): props = { - 'AdMarkers': (basestring, False), + 'AdMarkers': (str, False), 'IncludeIframeOnlyStream': (boolean, False), - 'ManifestName': (basestring, False), + 'ManifestName': (str, False), 'ProgramDateTimeIntervalSeconds': (integer, False), 'RepeatExtXKey': (boolean, False), 'StreamSelection': (StreamSelection, False), @@ -101,10 +101,10 @@ class DashEncryption(AWSProperty): class DashManifest(AWSProperty): props = { - 'ManifestLayout': (basestring, False), - 'ManifestName': (basestring, False), + 'ManifestLayout': (str, False), + 'ManifestName': (str, False), 'MinBufferTimeSeconds': (integer, False), - 'Profile': (basestring, False), + 'Profile': (str, False), 'StreamSelection': (StreamSelection, False), } @@ -113,16 +113,16 @@ class DashPackage(AWSProperty): props = { 'DashManifests': ([DashManifest], True), 'Encryption': (DashEncryption, False), - 'PeriodTriggers': ([basestring], False), + 'PeriodTriggers': ([str], False), 'SegmentDurationSeconds': (integer, False), - 'SegmentTemplateFormat': (basestring, False), + 'SegmentTemplateFormat': (str, False), } class HlsEncryption(AWSProperty): props = { - 'ConstantInitializationVector': (basestring, False), - 'EncryptionMethod': (basestring, False), + 'ConstantInitializationVector': (str, False), + 'EncryptionMethod': (str, False), 'SpekeKeyProvider': (SpekeKeyProvider, True), } @@ -144,7 +144,7 @@ class MssEncryption(AWSProperty): class MssManifest(AWSProperty): props = { - 'ManifestName': (basestring, False), + 'ManifestName': (str, False), 'StreamSelection': (StreamSelection, False), } @@ -162,19 +162,19 @@ class OriginEndpoint(AWSObject): props = { 'Authorization': (Authorization, False), - 'ChannelId': (basestring, True), + 'ChannelId': (str, True), 'CmafPackage': (CmafPackage, False), 'DashPackage': (DashPackage, False), - 'Description': (basestring, False), + 'Description': (str, False), 'HlsPackage': (HlsPackage, False), - 'Id': (basestring, True), - 'ManifestName': (basestring, False), + 'Id': (str, True), + 'ManifestName': (str, False), 'MssPackage': (MssPackage, False), - 'Origination': (basestring, False), + 'Origination': (str, False), 'StartoverWindowSeconds': (integer, False), 'Tags': (Tags, False), 'TimeDelaySeconds': (integer, False), - 'Whitelist': ([basestring], False), + 'Whitelist': ([str], False), } @@ -185,9 +185,9 @@ class PackagingConfiguration(AWSObject): 'CmafPackage': (CmafPackage, False), 'DashPackage': (DashPackage, False), 'HlsPackage': (HlsPackage, False), - 'Id': (basestring, True), + 'Id': (str, True), 'MssPackage': (MssPackage, False), - 'PackagingGroupId': (basestring, True), + 'PackagingGroupId': (str, True), 'Tags': (Tags, False), } @@ -197,6 +197,6 @@ class PackagingGroup(AWSObject): props = { 'Authorization': (Authorization, False), - 'Id': (basestring, True), + 'Id': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/mediastore.py b/troposphere/mediastore.py index f4090c4e7..78a507212 100644 --- a/troposphere/mediastore.py +++ b/troposphere/mediastore.py @@ -12,18 +12,18 @@ class CorsRule(AWSProperty): props = { - 'AllowedHeaders': ([basestring], False), - 'AllowedMethods': ([basestring], False), - 'AllowedOrigins': ([basestring], False), - 'ExposeHeaders': ([basestring], False), + 'AllowedHeaders': ([str], False), + 'AllowedMethods': ([str], False), + 'AllowedOrigins': ([str], False), + 'ExposeHeaders': ([str], False), 'MaxAgeSeconds': (integer, False), } class MetricPolicyRule(AWSProperty): props = { - 'ObjectGroup': (basestring, True), - 'ObjectGroupName': (basestring, True), + 'ObjectGroup': (str, True), + 'ObjectGroupName': (str, True), } @@ -39,10 +39,10 @@ class Container(AWSObject): props = { 'AccessLoggingEnabled': (boolean, False), - 'ContainerName': (basestring, True), + 'ContainerName': (str, True), 'CorsPolicy': ([CorsRule], False), - 'LifecyclePolicy': (basestring, False), + 'LifecyclePolicy': (str, False), 'MetricPolicy': (MetricPolicy, False), - 'Policy': (basestring, False), + 'Policy': (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/msk.py b/troposphere/msk.py index 2456bc709..23ca287f3 100644 --- a/troposphere/msk.py +++ b/troposphere/msk.py @@ -27,10 +27,10 @@ class StorageInfo(AWSProperty): class BrokerNodeGroupInfo(AWSProperty): props = { - 'BrokerAZDistribution': (basestring, False), - 'ClientSubnets': ([basestring], True), - 'InstanceType': (basestring, True), - 'SecurityGroups': ([basestring], False), + 'BrokerAZDistribution': (str, False), + 'ClientSubnets': ([str], True), + 'InstanceType': (str, True), + 'SecurityGroups': ([str], False), 'StorageInfo': (StorageInfo, False), } @@ -49,7 +49,7 @@ class Sasl(AWSProperty): class Tls(AWSProperty): props = { - 'CertificateAuthorityArnList': ([basestring], False), + 'CertificateAuthorityArnList': ([str], False), } @@ -62,20 +62,20 @@ class ClientAuthentication(AWSProperty): class ConfigurationInfo(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'Revision': (integer, True), } class EncryptionAtRest(AWSProperty): props = { - 'DataVolumeKMSKeyId': (basestring, True), + 'DataVolumeKMSKeyId': (str, True), } class EncryptionInTransit(AWSProperty): props = { - 'ClientBroker': (basestring, False), + 'ClientBroker': (str, False), 'InCluster': (boolean, False), } @@ -114,7 +114,7 @@ class OpenMonitoring(AWSProperty): class Firehose(AWSProperty): props = { - 'DeliveryStream': (basestring, True), + 'DeliveryStream': (str, True), 'Enabled': (boolean, True), } @@ -122,15 +122,15 @@ class Firehose(AWSProperty): class CloudWatchLogs(AWSProperty): props = { 'Enabled': (boolean, True), - 'LogGroup': (basestring, False), + 'LogGroup': (str, False), } class S3(AWSProperty): props = { - 'Bucket': (basestring, False), + 'Bucket': (str, False), 'Enabled': (boolean, True), - 'Prefix': (basestring, False), + 'Prefix': (str, False), } @@ -154,11 +154,11 @@ class Cluster(AWSObject): props = { 'BrokerNodeGroupInfo': (BrokerNodeGroupInfo, True), 'ClientAuthentication': (ClientAuthentication, False), - 'ClusterName': (basestring, True), + 'ClusterName': (str, True), 'ConfigurationInfo': (ConfigurationInfo, False), 'EncryptionInfo': (EncryptionInfo, False), - 'EnhancedMonitoring': (basestring, False), - 'KafkaVersion': (basestring, True), + 'EnhancedMonitoring': (str, False), + 'KafkaVersion': (str, True), 'LoggingInfo': (LoggingInfo, False), 'NumberOfBrokerNodes': (integer, True), 'OpenMonitoring': (OpenMonitoring, False), diff --git a/troposphere/neptune.py b/troposphere/neptune.py index b14aae90a..4917f51bd 100644 --- a/troposphere/neptune.py +++ b/troposphere/neptune.py @@ -12,9 +12,9 @@ class DBClusterParameterGroup(AWSObject): resource_type = "AWS::Neptune::DBClusterParameterGroup" props = { - 'Description': (basestring, True), - 'Family': (basestring, True), - 'Name': (basestring, False), + 'Description': (str, True), + 'Family': (str, True), + 'Name': (str, False), 'Parameters': (dict, True), 'Tags': (Tags, False), } @@ -24,23 +24,23 @@ class DBCluster(AWSObject): resource_type = "AWS::Neptune::DBCluster" props = { - 'AvailabilityZones': ([basestring], False), + 'AvailabilityZones': ([str], False), 'BackupRetentionPeriod': (integer, False), - 'DBClusterIdentifier': (basestring, False), - 'DBClusterParameterGroupName': (basestring, False), - 'DBSubnetGroupName': (basestring, False), + 'DBClusterIdentifier': (str, False), + 'DBClusterParameterGroupName': (str, False), + 'DBSubnetGroupName': (str, False), 'DeletionProtection': (boolean, False), - 'EnableCloudwatchLogsExports': ([basestring], False), - 'EngineVersion': (basestring, False), + 'EnableCloudwatchLogsExports': ([str], False), + 'EngineVersion': (str, False), 'IamAuthEnabled': (boolean, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'Port': (integer, False), - 'PreferredBackupWindow': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), - 'SnapshotIdentifier': (basestring, False), + 'PreferredBackupWindow': (str, False), + 'PreferredMaintenanceWindow': (str, False), + 'SnapshotIdentifier': (str, False), 'StorageEncrypted': (boolean, False), 'Tags': (Tags, False), - 'VpcSecurityGroupIds': ([basestring], False), + 'VpcSecurityGroupIds': ([str], False), } @@ -50,14 +50,14 @@ class DBInstance(AWSObject): props = { 'AllowMajorVersionUpgrade': (boolean, False), 'AutoMinorVersionUpgrade': (boolean, False), - 'AvailabilityZone': (basestring, False), - 'DBClusterIdentifier': (basestring, False), - 'DBInstanceClass': (basestring, True), - 'DBInstanceIdentifier': (basestring, False), - 'DBParameterGroupName': (basestring, False), - 'DBSnapshotIdentifier': (basestring, False), - 'DBSubnetGroupName': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), + 'AvailabilityZone': (str, False), + 'DBClusterIdentifier': (str, False), + 'DBInstanceClass': (str, True), + 'DBInstanceIdentifier': (str, False), + 'DBParameterGroupName': (str, False), + 'DBSnapshotIdentifier': (str, False), + 'DBSubnetGroupName': (str, False), + 'PreferredMaintenanceWindow': (str, False), 'Tags': (Tags, False), } @@ -66,9 +66,9 @@ class DBParameterGroup(AWSObject): resource_type = "AWS::Neptune::DBParameterGroup" props = { - 'Description': (basestring, True), - 'Family': (basestring, True), - 'Name': (basestring, False), + 'Description': (str, True), + 'Family': (str, True), + 'Name': (str, False), 'Parameters': (dict, True), 'Tags': (Tags, False), } @@ -78,8 +78,8 @@ class DBSubnetGroup(AWSObject): resource_type = "AWS::Neptune::DBSubnetGroup" props = { - 'DBSubnetGroupDescription': (basestring, True), - 'DBSubnetGroupName': (basestring, False), - 'SubnetIds': ([basestring], True), + 'DBSubnetGroupDescription': (str, True), + 'DBSubnetGroupName': (str, False), + 'SubnetIds': ([str], True), 'Tags': (Tags, False), } diff --git a/troposphere/networkfirewall.py b/troposphere/networkfirewall.py index 9786c469a..5b03817fc 100644 --- a/troposphere/networkfirewall.py +++ b/troposphere/networkfirewall.py @@ -16,7 +16,7 @@ class SubnetMapping(AWSProperty): props = { - 'SubnetId': (basestring, True), + 'SubnetId': (str, True), } @@ -25,20 +25,20 @@ class Firewall(AWSObject): props = { 'DeleteProtection': (boolean, False), - 'Description': (basestring, False), - 'FirewallName': (basestring, True), - 'FirewallPolicyArn': (basestring, True), + 'Description': (str, False), + 'FirewallName': (str, True), + 'FirewallPolicyArn': (str, True), 'FirewallPolicyChangeProtection': (boolean, False), 'SubnetChangeProtection': (boolean, False), 'SubnetMappings': ([SubnetMapping], True), 'Tags': (Tags, False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } class Dimension(AWSProperty): props = { - 'Value': (basestring, True), + 'Value': (str, True), } @@ -57,20 +57,20 @@ class ActionDefinition(AWSProperty): class CustomAction(AWSProperty): props = { 'ActionDefinition': (ActionDefinition, True), - 'ActionName': (basestring, True), + 'ActionName': (str, True), } class StatefulRuleGroupReference(AWSProperty): props = { - 'ResourceArn': (basestring, True), + 'ResourceArn': (str, True), } class StatelessRuleGroupReference(AWSProperty): props = { 'Priority': (integer, True), - 'ResourceArn': (basestring, True), + 'ResourceArn': (str, True), } @@ -79,8 +79,8 @@ class FirewallPolicy(AWSProperty): 'StatefulRuleGroupReferences': ([StatefulRuleGroupReference], False), 'StatelessCustomActions': ([CustomAction], False), - 'StatelessDefaultActions': ([basestring], True), - 'StatelessFragmentDefaultActions': ([basestring], True), + 'StatelessDefaultActions': ([str], True), + 'StatelessFragmentDefaultActions': ([str], True), 'StatelessRuleGroupReferences': ([StatelessRuleGroupReference], False), } @@ -89,8 +89,8 @@ class FirewallPolicy(AWSProperty): class LogDestinationConfig(AWSProperty): props = { 'LogDestination': (dict, True), - 'LogDestinationType': (basestring, True), - 'LogType': (basestring, True), + 'LogDestinationType': (str, True), + 'LogType': (str, True), } @@ -109,33 +109,33 @@ class RuleVariables(AWSProperty): class RulesSourceList(AWSProperty): props = { - 'GeneratedRulesType': (basestring, True), - 'TargetTypes': ([basestring], True), - 'Targets': ([basestring], True), + 'GeneratedRulesType': (str, True), + 'TargetTypes': ([str], True), + 'Targets': ([str], True), } class Header(AWSProperty): props = { - 'Destination': (basestring, True), - 'DestinationPort': (basestring, True), - 'Direction': (basestring, True), - 'Protocol': (basestring, True), - 'Source': (basestring, True), - 'SourcePort': (basestring, True), + 'Destination': (str, True), + 'DestinationPort': (str, True), + 'Direction': (str, True), + 'Protocol': (str, True), + 'Source': (str, True), + 'SourcePort': (str, True), } class RuleOption(AWSProperty): props = { - 'Keyword': (basestring, True), - 'Settings': ([basestring], False), + 'Keyword': (str, True), + 'Settings': ([str], False), } class StatefulRule(AWSProperty): props = { - 'Action': (basestring, True), + 'Action': (str, True), 'Header': (Header, True), 'RuleOptions': ([RuleOption], True), } @@ -143,7 +143,7 @@ class StatefulRule(AWSProperty): class Address(AWSProperty): props = { - 'AddressDefinition': (basestring, True), + 'AddressDefinition': (str, True), } @@ -156,8 +156,8 @@ class PortRange(AWSProperty): class TCPFlagField(AWSProperty): props = { - 'Flags': ([basestring], True), - 'Masks': ([basestring], False), + 'Flags': ([str], True), + 'Masks': ([str], False), } @@ -174,7 +174,7 @@ class MatchAttributes(AWSProperty): class RuleDefinition(AWSProperty): props = { - 'Actions': ([basestring], True), + 'Actions': ([str], True), 'MatchAttributes': (MatchAttributes, True), } @@ -196,7 +196,7 @@ class StatelessRulesAndCustomActions(AWSProperty): class RulesSource(AWSProperty): props = { 'RulesSourceList': (RulesSourceList, False), - 'RulesString': (basestring, False), + 'RulesString': (str, False), 'StatefulRules': ([StatefulRule], False), 'StatelessRulesAndCustomActions': (StatelessRulesAndCustomActions, False), diff --git a/troposphere/networkmanager.py b/troposphere/networkmanager.py index ebb956efb..4c7c1570f 100644 --- a/troposphere/networkmanager.py +++ b/troposphere/networkmanager.py @@ -10,16 +10,16 @@ class TransitGatewayRegistration(AWSObject): resource_type = "AWS::NetworkManager::TransitGatewayRegistration" props = { - 'GlobalNetworkId': (basestring, True), - 'TransitGatewayArn': (basestring, True), + 'GlobalNetworkId': (str, True), + 'TransitGatewayArn': (str, True), } class Location(AWSProperty): props = { - 'Address': (basestring, False), - 'Latitude': (basestring, False), - 'Longitude': (basestring, False), + 'Address': (str, False), + 'Latitude': (str, False), + 'Longitude': (str, False), } @@ -27,8 +27,8 @@ class Site(AWSObject): resource_type = "AWS::NetworkManager::Site" props = { - 'Description': (basestring, False), - 'GlobalNetworkId': (basestring, True), + 'Description': (str, False), + 'GlobalNetworkId': (str, True), 'Location': (Location, False), 'Tags': (Tags, False), } @@ -38,16 +38,16 @@ class LinkAssociation(AWSObject): resource_type = "AWS::NetworkManager::LinkAssociation" props = { - 'DeviceId': (basestring, True), - 'GlobalNetworkId': (basestring, True), - 'LinkId': (basestring, True), + 'DeviceId': (str, True), + 'GlobalNetworkId': (str, True), + 'LinkId': (str, True), } class Bandwidth(AWSProperty): props = { - 'DownloadSpeed': (basestring, False), - 'UploadSpeed': (basestring, False), + 'DownloadSpeed': (str, False), + 'UploadSpeed': (str, False), } @@ -56,12 +56,12 @@ class Link(AWSObject): props = { 'Bandwidth': (Bandwidth, True), - 'Description': (basestring, False), - 'GlobalNetworkId': (basestring, True), - 'Provider': (basestring, False), - 'SiteId': (basestring, True), + 'Description': (str, False), + 'GlobalNetworkId': (str, True), + 'Provider': (str, False), + 'SiteId': (str, True), 'Tags': (Tags, False), - 'Type': (basestring, False), + 'Type': (str, False), } @@ -69,7 +69,7 @@ class GlobalNetwork(AWSObject): resource_type = "AWS::NetworkManager::GlobalNetwork" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'Tags': (Tags, False), } @@ -78,15 +78,15 @@ class Device(AWSObject): resource_type = "AWS::NetworkManager::Device" props = { - 'Description': (basestring, False), - 'GlobalNetworkId': (basestring, True), - 'Location': (basestring, False), - 'Model': (basestring, False), - 'SerialNumber': (basestring, False), - 'SiteId': (basestring, False), + 'Description': (str, False), + 'GlobalNetworkId': (str, True), + 'Location': (str, False), + 'Model': (str, False), + 'SerialNumber': (str, False), + 'SiteId': (str, False), 'Tags': (Tags, False), - 'Type': (basestring, False), - 'Vendor': (basestring, False), + 'Type': (str, False), + 'Vendor': (str, False), } @@ -94,8 +94,8 @@ class CustomerGatewayAssociation(AWSObject): resource_type = "AWS::NetworkManager::CustomerGatewayAssociation" props = { - 'CustomerGatewayArn': (basestring, True), - 'DeviceId': (basestring, True), - 'GlobalNetworkId': (basestring, True), - 'LinkId': (basestring, False), + 'CustomerGatewayArn': (str, True), + 'DeviceId': (str, True), + 'GlobalNetworkId': (str, True), + 'LinkId': (str, False), } diff --git a/troposphere/openstack/heat.py b/troposphere/openstack/heat.py index 1b3bc80c7..04a16513f 100644 --- a/troposphere/openstack/heat.py +++ b/troposphere/openstack/heat.py @@ -41,13 +41,13 @@ class AWSAutoScalingGroup(AWSObject): props = { 'AvailabilityZones': (list, True), 'Cooldown': (integer, False), - 'DesiredCapacity': (basestring, False), + 'DesiredCapacity': (str, False), 'HealthCheckGracePeriod': (integer, False), - 'HealthCheckType': (basestring, False), - 'LaunchConfigurationName': (basestring, True), + 'HealthCheckType': (str, False), + 'LaunchConfigurationName': (str, True), 'LoadBalancerNames': (list, False), - 'MaxSize': (basestring, True), - 'MinSize': (basestring, True), + 'MaxSize': (str, True), + 'MinSize': (str, True), 'Tags': (list, False), 'VPCZoneIdentifier': (list, False), } diff --git a/troposphere/openstack/neutron.py b/troposphere/openstack/neutron.py index de5ffff09..5beb34721 100644 --- a/troposphere/openstack/neutron.py +++ b/troposphere/openstack/neutron.py @@ -15,9 +15,9 @@ class Firewall(AWSObject): props = { 'admin_state_up': (boolean, False), - 'description': (basestring, False), - 'firewall_policy_id': (basestring, True), - 'name': (basestring, False), + 'description': (str, False), + 'firewall_policy_id': (str, True), + 'name': (str, False), } @@ -26,9 +26,9 @@ class FirewallPolicy(AWSObject): props = { 'audited': (boolean, False), - 'description': (basestring, False), + 'description': (str, False), 'firewall_rules': (list, True), - 'name': (basestring, False), + 'name': (str, False), 'shared': (boolean, False), } @@ -37,16 +37,16 @@ class FirewallRule(AWSObject): resource_type = "OS::Neutron::FirewallRule" props = { - 'action': (basestring, False), - 'description': (basestring, False), - 'destination_ip_address': (basestring, False), + 'action': (str, False), + 'description': (str, False), + 'destination_ip_address': (str, False), 'destination_port': (network_port, False), 'enabled': (boolean, False), - 'ip_version': (basestring, False), - 'name': (basestring, False), - 'protocol': (basestring, False), + 'ip_version': (str, False), + 'name': (str, False), + 'protocol': (str, False), 'shared': (boolean, False), - 'source_ip_address': (basestring, False), + 'source_ip_address': (str, False), 'source_port': (network_port, False), } @@ -79,9 +79,9 @@ class FloatingIP(AWSObject): resource_type = "OS::Neutron::FloatingIP" props = { - 'fixed_ip_address': (basestring, False), - 'floating_network_id': (basestring, True), - 'port_id': (basestring, False), + 'fixed_ip_address': (str, False), + 'floating_network_id': (str, True), + 'port_id': (str, False), 'value_specs': (dict, False), } @@ -90,9 +90,9 @@ class FloatingIPAssociation(AWSObject): resource_type = "OS::Neutron::FloatingIPAssociation" props = { - 'fixed_ip_address': (basestring, False), - 'floatingip_id': (basestring, True), - 'port_id': (basestring, False), + 'fixed_ip_address': (str, False), + 'floatingip_id': (str, True), + 'port_id': (str, False), } @@ -102,12 +102,12 @@ class HealthMonitor(AWSObject): props = { 'admin_state_up': (boolean, False), 'delay': (positive_integer, True), - 'expected_codes': (basestring, False), - 'http_method': (basestring, False), + 'expected_codes': (str, False), + 'http_method': (str, False), 'max_retries': (integer, True), 'timeout': (integer, True), - 'type': (basestring, True), - 'url_path': (basestring, False), + 'type': (str, True), + 'url_path': (str, False), } def validate(self): @@ -124,8 +124,8 @@ def validate(self): class SessionPersistence(AWSProperty): props = { - 'cookie_name': (basestring, False), - 'type': (basestring, False), + 'cookie_name': (str, False), + 'type': (str, False), } def validate(self): @@ -146,11 +146,11 @@ def validate(self): class VIP(AWSProperty): props = { - 'address': (basestring, False), + 'address': (str, False), 'admin_state_up': (boolean, False), 'connection_limit': (integer, True), - 'description': (basestring, False), - 'name': (basestring, False), + 'description': (str, False), + 'name': (str, False), 'protocol_port': (network_port, True), 'session_persistence': (SessionPersistence, False), } @@ -161,12 +161,12 @@ class Pool(AWSObject): props = { 'admin_state_up': (boolean, False), - 'description': (basestring, False), - 'lb_method': (basestring, True), + 'description': (str, False), + 'lb_method': (str, True), 'monitors': (list, False), - 'name': (basestring, False), - 'protocol': (basestring, True), - 'subnet_id': (basestring, True), + 'name': (str, False), + 'protocol': (str, True), + 'subnet_id': (str, True), 'vip': (VIP, False), } @@ -206,9 +206,9 @@ class Net(AWSObject): props = { 'admin_state_up': (boolean, False), - 'name': (basestring, False), + 'name': (str, False), 'shared': (boolean, False), - 'tenant_id': (basestring, False), + 'tenant_id': (str, False), 'value_specs': (dict, False), } @@ -217,7 +217,7 @@ class PoolMember(AWSObject): resource_type = "OS::Neutron::PoolMember" props = { - 'address': (basestring, True), + 'address': (str, True), 'admin_state_up': (boolean, False), 'pool_id': (Pool, True), 'protocol_port': (network_port, True), @@ -227,15 +227,15 @@ class PoolMember(AWSObject): class AddressPair(AWSProperty): props = { - 'ip_address': (basestring, True), - 'mac_address': (basestring, False), + 'ip_address': (str, True), + 'mac_address': (str, False), } class FixedIP(AWSProperty): props = { - 'ip_address': (basestring, False), - 'subnet_id': (basestring, False), + 'ip_address': (str, False), + 'subnet_id': (str, False), } @@ -245,11 +245,11 @@ class Port(AWSObject): props = { 'admin_state_up': (boolean, False), 'allowed_address_pairs': (list, False), - 'device_id': (basestring, False), + 'device_id': (str, False), 'fixed_ips': (list, False), - 'mac_address': (basestring, False), - 'name': (basestring, False), - 'network_id': (basestring, True), + 'mac_address': (str, False), + 'name': (str, False), + 'network_id': (str, True), 'security_groups': (list, False), 'value_specs': (dict, False), } @@ -259,22 +259,22 @@ class SecurityGroup(AWSObject): resource_type = "OS::Neutron::SecurityGroup" props = { - 'description': (basestring, True), - 'name': (basestring, False), + 'description': (str, True), + 'name': (str, False), 'rules': (list, False), } class SecurityGroupRule(AWSProperty): props = { - 'direction': (basestring, False), - 'ethertype': (basestring, False), + 'direction': (str, False), + 'ethertype': (str, False), 'port_range_max': (network_port, False), 'port_range_min': (network_port, False), - 'protocol': (basestring, False), - 'remote_group_id': (basestring, False), - 'remote_ip_prefix': (basestring, False), - 'remote_mode': (basestring, False), + 'protocol': (str, False), + 'remote_group_id': (str, False), + 'remote_ip_prefix': (str, False), + 'remote_mode': (str, False), } def validate(self): diff --git a/troposphere/openstack/nova.py b/troposphere/openstack/nova.py index 200f630c4..1d9d18b20 100644 --- a/troposphere/openstack/nova.py +++ b/troposphere/openstack/nova.py @@ -12,9 +12,9 @@ class BlockDeviceMapping(AWSProperty): props = { 'delete_on_termination': (boolean, False), - 'device_name': (basestring, True), - 'snapshot_id': (basestring, False), - 'volume_id': (basestring, False), + 'device_name': (str, True), + 'snapshot_id': (str, False), + 'volume_id': (str, False), 'volume_size': (integer, False), } @@ -23,15 +23,15 @@ class BlockDeviceMappingV2(AWSProperty): props = { 'boot_index': (integer, False), 'delete_on_termination': (boolean, False), - 'device_name': (basestring, False), - 'device_type': (basestring, False), - 'disk_bus': (basestring, False), - 'ephemeral_format': (basestring, False), + 'device_name': (str, False), + 'device_type': (str, False), + 'disk_bus': (str, False), + 'ephemeral_format': (str, False), 'ephemeral_size': (integer, False), - 'image_id': (basestring, False), - 'snapshot_id': (basestring, False), + 'image_id': (str, False), + 'snapshot_id': (str, False), 'swap_size': (integer, False), - 'volume_id': (basestring, False), + 'volume_id': (str, False), 'volume_size': (integer, False), } @@ -60,8 +60,8 @@ def validate(self): class Network(AWSProperty): props = { - 'fixed_ip': (basestring, False), - 'network': (basestring, False), + 'fixed_ip': (str, False), + 'network': (str, False), 'port': (network_port, False), } @@ -70,7 +70,7 @@ class FloatingIP(AWSObject): resource_type = "OS::Nova::FloatingIP" props = { - 'pool': (basestring, False), + 'pool': (str, False), } @@ -78,8 +78,8 @@ class FloatingIPAssociation(AWSObject): resource_type = "OS::Nova::FloatingIPAssociation" props = { - 'floating_ip': (basestring, True), - 'server_ip': (basestring, True), + 'floating_ip': (str, True), + 'server_ip': (str, True), } @@ -87,8 +87,8 @@ class KeyPair(AWSObject): resource_type = "OS::Nova::KeyPair" props = { - 'name': (basestring, True), - 'public_key': (basestring, False), + 'name': (str, True), + 'public_key': (str, False), 'save_private_key': (boolean, False), } @@ -97,28 +97,28 @@ class Server(AWSObject): resource_type = "OS::Nova::Server" props = { - 'admin_pass': (basestring, False), - 'admin_user': (basestring, False), - 'availability_zone': (basestring, False), + 'admin_pass': (str, False), + 'admin_user': (str, False), + 'availability_zone': (str, False), 'block_device_mapping': (list, False), 'block_device_mapping_v2': (list, False), - 'config_drive': (basestring, False), - 'diskConfig': (basestring, False), - 'flavor': (basestring, False), - 'flavor_update_policy': (basestring, False), - 'image': (basestring, True), - 'image_update_policy': (basestring, False), - 'key_name': (basestring, False), + 'config_drive': (str, False), + 'diskConfig': (str, False), + 'flavor': (str, False), + 'flavor_update_policy': (str, False), + 'image': (str, True), + 'image_update_policy': (str, False), + 'key_name': (str, False), 'metadata': (dict, False), - 'name': (basestring, False), + 'name': (str, False), 'personality': (dict, False), 'networks': (list, True), - 'reservation_id': (basestring, False), + 'reservation_id': (str, False), 'scheduler_hints': (dict, False), 'security_groups': (list, False), - 'software_config_transport': (basestring, False), - 'user_data': (basestring, False), - 'user_data_format': (basestring, False), + 'software_config_transport': (str, False), + 'user_data': (str, False), + 'user_data_format': (str, False), } def validate(self): diff --git a/troposphere/opsworks.py b/troposphere/opsworks.py index 945c57237..4a5ed297d 100644 --- a/troposphere/opsworks.py +++ b/troposphere/opsworks.py @@ -9,37 +9,37 @@ class Source(AWSProperty): props = { - 'Password': (basestring, False), - 'Revision': (basestring, False), - 'SshKey': (basestring, False), - 'Type': (basestring, False), - 'Url': (basestring, False), - 'Username': (basestring, False), + 'Password': (str, False), + 'Revision': (str, False), + 'SshKey': (str, False), + 'Type': (str, False), + 'Url': (str, False), + 'Username': (str, False), } class SslConfiguration(AWSProperty): props = { - 'Certificate': (basestring, True), - 'Chain': (basestring, False), - 'PrivateKey': (basestring, True), + 'Certificate': (str, True), + 'Chain': (str, False), + 'PrivateKey': (str, True), } class ChefConfiguration(AWSProperty): props = { - 'BerkshelfVersion': (basestring, False), + 'BerkshelfVersion': (str, False), 'ManageBerkshelf': (boolean, False), } class Recipes(AWSProperty): props = { - 'Configure': ([basestring], False), - 'Deploy': ([basestring], False), - 'Setup': ([basestring], False), - 'Shutdown': ([basestring], False), - 'Undeploy': ([basestring], False), + 'Configure': ([str], False), + 'Deploy': ([str], False), + 'Setup': ([str], False), + 'Shutdown': ([str], False), + 'Undeploy': ([str], False), } @@ -55,7 +55,7 @@ class VolumeConfiguration(AWSProperty): props = { 'Encrypted': (boolean, False), 'Iops': (integer, False), - 'MountPoint': (basestring, True), + 'MountPoint': (str, True), 'NumberOfDisks': (integer, True), 'RaidLevel': (integer, False), 'Size': (integer, True), @@ -73,8 +73,8 @@ def validate(self): class StackConfigurationManager(AWSProperty): props = { - 'Name': (basestring, False), - 'Version': (basestring, False), + 'Name': (str, False), + 'Version': (str, False), } @@ -103,9 +103,9 @@ class AutoScalingThresholds(AWSProperty): class Environment(AWSProperty): props = { - 'Key': (basestring, True), + 'Key': (str, True), 'Secure': (bool, False), - 'Value': (basestring, True), + 'Value': (str, True), } @@ -131,8 +131,8 @@ def validate_data_source_type(data_source_type): class DataSource(AWSProperty): props = { - 'Arn': (basestring, False), - 'DatabaseName': (basestring, False), + 'Arn': (str, False), + 'DatabaseName': (str, False), 'Type': (validate_data_source_type, False) } @@ -144,15 +144,15 @@ class App(AWSObject): 'AppSource': (Source, False), 'Attributes': (dict, False), 'DataSources': ([DataSource], False), - 'Description': (basestring, False), - 'Domains': ([basestring], False), + 'Description': (str, False), + 'Domains': ([str], False), 'EnableSsl': (boolean, False), 'Environment': ([Environment], False), - 'Name': (basestring, True), - 'Shortname': (basestring, False), + 'Name': (str, True), + 'Shortname': (str, False), 'SslConfiguration': (SslConfiguration, False), - 'StackId': (basestring, True), - 'Type': (basestring, True), + 'StackId': (str, True), + 'Type': (str, True), } @@ -160,8 +160,8 @@ class ElasticLoadBalancerAttachment(AWSObject): resource_type = "AWS::OpsWorks::ElasticLoadBalancerAttachment" props = { - 'ElasticLoadBalancerName': (basestring, True), - 'LayerId': (basestring, True), + 'ElasticLoadBalancerName': (str, True), + 'LayerId': (str, True), 'Tags': ((Tags, list), False), } @@ -170,18 +170,18 @@ class EbsBlockDevice(AWSProperty): props = { 'DeleteOnTermination': (boolean, False), 'Iops': (integer, False), - 'SnapshotId': (basestring, False), + 'SnapshotId': (str, False), 'VolumeSize': (integer, False), - 'VolumeType': (basestring, False), + 'VolumeType': (str, False), } class BlockDeviceMapping(AWSProperty): props = { - 'DeviceName': (basestring, False), + 'DeviceName': (str, False), 'Ebs': (EbsBlockDevice, False), - 'NoDevice': (basestring, False), - 'VirtualName': (basestring, False), + 'NoDevice': (str, False), + 'VirtualName': (str, False), } def validate(self): @@ -196,27 +196,27 @@ class Instance(AWSObject): resource_type = "AWS::OpsWorks::Instance" props = { - 'AgentVersion': (basestring, False), - 'AmiId': (basestring, False), - 'Architecture': (basestring, False), - 'AutoScalingType': (basestring, False), - 'AvailabilityZone': (basestring, False), + 'AgentVersion': (str, False), + 'AmiId': (str, False), + 'Architecture': (str, False), + 'AutoScalingType': (str, False), + 'AvailabilityZone': (str, False), 'BlockDeviceMappings': ([BlockDeviceMapping], False), 'EbsOptimized': (boolean, False), - 'ElasticIps': ([basestring], False), - 'Hostname': (basestring, False), + 'ElasticIps': ([str], False), + 'Hostname': (str, False), 'InstallUpdatesOnBoot': (boolean, False), - 'InstanceType': (basestring, True), - 'LayerIds': ([basestring], True), - 'Os': (basestring, False), - 'RootDeviceType': (basestring, False), - 'SshKeyName': (basestring, False), - 'StackId': (basestring, True), - 'SubnetId': (basestring, False), - 'Tenancy': (basestring, False), + 'InstanceType': (str, True), + 'LayerIds': ([str], True), + 'Os': (str, False), + 'RootDeviceType': (str, False), + 'SshKeyName': (str, False), + 'StackId': (str, True), + 'SubnetId': (str, False), + 'Tenancy': (str, False), 'TimeBasedAutoScaling': (TimeBasedAutoScaling, False), - 'VirtualizationType': (basestring, False), - 'Volumes': ([basestring], False), + 'VirtualizationType': (str, False), + 'Volumes': ([str], False), } @@ -240,35 +240,35 @@ class Layer(AWSObject): 'Attributes': (dict, False), 'AutoAssignElasticIps': (boolean, True), 'AutoAssignPublicIps': (boolean, True), - 'CustomInstanceProfileArn': (basestring, False), - 'CustomJson': ((basestring, dict), False), + 'CustomInstanceProfileArn': (str, False), + 'CustomJson': ((str, dict), False), 'CustomRecipes': (Recipes, False), - 'CustomSecurityGroupIds': ([basestring], False), + 'CustomSecurityGroupIds': ([str], False), 'EnableAutoHealing': (boolean, True), 'InstallUpdatesOnBoot': (boolean, False), 'LifecycleEventConfiguration': (LifeCycleConfiguration, False), 'LoadBasedAutoScaling': (LoadBasedAutoScaling, False), - 'Name': (basestring, True), - 'Packages': ([basestring], False), - 'Shortname': (basestring, True), - 'StackId': (basestring, True), - 'Type': (basestring, True), + 'Name': (str, True), + 'Packages': ([str], False), + 'Shortname': (str, True), + 'StackId': (str, True), + 'Type': (str, True), 'VolumeConfigurations': ([VolumeConfiguration], False), } class RdsDbInstance(AWSProperty): props = { - 'DbPassword': (basestring, True), - 'DbUser': (basestring, True), - 'RdsDbInstanceArn': (basestring, True) + 'DbPassword': (str, True), + 'DbUser': (str, True), + 'RdsDbInstanceArn': (str, True) } class ElasticIp(AWSProperty): props = { - 'Ip': (basestring, True), - 'Name': (basestring, False), + 'Ip': (str, True), + 'Name': (str, False), } @@ -276,31 +276,31 @@ class Stack(AWSObject): resource_type = "AWS::OpsWorks::Stack" props = { - 'AgentVersion': (basestring, False), + 'AgentVersion': (str, False), 'Attributes': (dict, False), 'ChefConfiguration': (ChefConfiguration, False), - 'CloneAppIds': ([basestring], False), + 'CloneAppIds': ([str], False), 'ClonePermissions': (boolean, False), 'ConfigurationManager': (StackConfigurationManager, False), 'CustomCookbooksSource': (Source, False), - 'CustomJson': ((basestring, dict), False), - 'DefaultAvailabilityZone': (basestring, False), - 'DefaultInstanceProfileArn': (basestring, True), - 'DefaultOs': (basestring, False), - 'DefaultRootDeviceType': (basestring, False), - 'DefaultSshKeyName': (basestring, False), - 'DefaultSubnetId': (basestring, False), - 'EcsClusterArn': (basestring, False), + 'CustomJson': ((str, dict), False), + 'DefaultAvailabilityZone': (str, False), + 'DefaultInstanceProfileArn': (str, True), + 'DefaultOs': (str, False), + 'DefaultRootDeviceType': (str, False), + 'DefaultSshKeyName': (str, False), + 'DefaultSubnetId': (str, False), + 'EcsClusterArn': (str, False), 'ElasticIps': ([ElasticIp], False), - 'HostnameTheme': (basestring, False), - 'Name': (basestring, True), + 'HostnameTheme': (str, False), + 'Name': (str, True), 'RdsDbInstances': ([RdsDbInstance], False), - 'ServiceRoleArn': (basestring, True), - 'SourceStackId': (basestring, False), + 'ServiceRoleArn': (str, True), + 'SourceStackId': (str, False), 'Tags': ((Tags, list), False), 'UseCustomCookbooks': (boolean, False), 'UseOpsworksSecurityGroups': (boolean, False), - 'VpcId': (basestring, False), + 'VpcId': (str, False), } def validate(self): @@ -316,9 +316,9 @@ class UserProfile(AWSObject): props = { 'AllowSelfManagement': (boolean, False), - 'IamUserArn': (basestring, True), - 'SshPublicKey': (basestring, False), - 'SshUsername': (basestring, False), + 'IamUserArn': (str, True), + 'SshPublicKey': (str, False), + 'SshUsername': (str, False), } @@ -326,17 +326,17 @@ class Volume(AWSObject): resource_type = "AWS::OpsWorks::Volume" props = { - 'Ec2VolumeId': (basestring, True), - 'MountPoint': (basestring, False), - 'Name': (basestring, False), - 'StackId': (basestring, True), + 'Ec2VolumeId': (str, True), + 'MountPoint': (str, False), + 'Name': (str, False), + 'StackId': (str, True), } class EngineAttribute(AWSProperty): props = { - 'Name': (basestring, False), - 'Value': (basestring, False), + 'Name': (str, False), + 'Value': (str, False), } @@ -345,24 +345,24 @@ class Server(AWSObject): props = { 'AssociatePublicIpAddress': (boolean, False), - 'BackupId': (basestring, False), + 'BackupId': (str, False), 'BackupRetentionCount': (integer, False), - 'CustomCertificate': (basestring, False), - 'CustomDomain': (basestring, False), - 'CustomPrivateKey': (basestring, False), + 'CustomCertificate': (str, False), + 'CustomDomain': (str, False), + 'CustomPrivateKey': (str, False), 'DisableAutomatedBackup': (boolean, False), - 'Engine': (basestring, False), + 'Engine': (str, False), 'EngineAttributes': ([EngineAttribute], False), - 'EngineModel': (basestring, False), - 'EngineVersion': (basestring, False), - 'InstanceProfileArn': (basestring, True), - 'InstanceType': (basestring, True), - 'KeyPair': (basestring, False), - 'PreferredBackupWindow': (basestring, False), - 'PreferredMaintenanceWindow': (basestring, False), - 'SecurityGroupIds': ([basestring], False), - 'ServerName': (basestring, False), - 'ServiceRoleArn': (basestring, True), - 'SubnetIds': ([basestring], False), + 'EngineModel': (str, False), + 'EngineVersion': (str, False), + 'InstanceProfileArn': (str, True), + 'InstanceType': (str, True), + 'KeyPair': (str, False), + 'PreferredBackupWindow': (str, False), + 'PreferredMaintenanceWindow': (str, False), + 'SecurityGroupIds': ([str], False), + 'ServerName': (str, False), + 'ServiceRoleArn': (str, True), + 'SubnetIds': ([str], False), 'Tags': ((Tags, list), False), } diff --git a/troposphere/pinpoint.py b/troposphere/pinpoint.py index 235f17ffe..7eaaa3eac 100644 --- a/troposphere/pinpoint.py +++ b/troposphere/pinpoint.py @@ -18,9 +18,9 @@ class ADMChannel(AWSObject): resource_type = "AWS::Pinpoint::ADMChannel" props = { - 'ApplicationId': (basestring, True), - 'ClientId': (basestring, True), - 'ClientSecret': (basestring, True), + 'ApplicationId': (str, True), + 'ClientId': (str, True), + 'ClientSecret': (str, True), 'Enabled': (boolean, False), } @@ -29,15 +29,15 @@ class APNSChannel(AWSObject): resource_type = "AWS::Pinpoint::APNSChannel" props = { - 'ApplicationId': (basestring, True), - 'BundleId': (basestring, False), - 'Certificate': (basestring, False), - 'DefaultAuthenticationMethod': (basestring, False), + 'ApplicationId': (str, True), + 'BundleId': (str, False), + 'Certificate': (str, False), + 'DefaultAuthenticationMethod': (str, False), 'Enabled': (boolean, False), - 'PrivateKey': (basestring, False), - 'TeamId': (basestring, False), - 'TokenKey': (basestring, False), - 'TokenKeyId': (basestring, False), + 'PrivateKey': (str, False), + 'TeamId': (str, False), + 'TokenKey': (str, False), + 'TokenKeyId': (str, False), } @@ -45,15 +45,15 @@ class APNSSandboxChannel(AWSObject): resource_type = "AWS::Pinpoint::APNSSandboxChannel" props = { - 'ApplicationId': (basestring, True), - 'BundleId': (basestring, False), - 'Certificate': (basestring, False), - 'DefaultAuthenticationMethod': (basestring, False), + 'ApplicationId': (str, True), + 'BundleId': (str, False), + 'Certificate': (str, False), + 'DefaultAuthenticationMethod': (str, False), 'Enabled': (boolean, False), - 'PrivateKey': (basestring, False), - 'TeamId': (basestring, False), - 'TokenKey': (basestring, False), - 'TokenKeyId': (basestring, False), + 'PrivateKey': (str, False), + 'TeamId': (str, False), + 'TokenKey': (str, False), + 'TokenKeyId': (str, False), } @@ -61,15 +61,15 @@ class APNSVoipChannel(AWSObject): resource_type = "AWS::Pinpoint::APNSVoipChannel" props = { - 'ApplicationId': (basestring, True), - 'BundleId': (basestring, False), - 'Certificate': (basestring, False), - 'DefaultAuthenticationMethod': (basestring, False), + 'ApplicationId': (str, True), + 'BundleId': (str, False), + 'Certificate': (str, False), + 'DefaultAuthenticationMethod': (str, False), 'Enabled': (boolean, False), - 'PrivateKey': (basestring, False), - 'TeamId': (basestring, False), - 'TokenKey': (basestring, False), - 'TokenKeyId': (basestring, False), + 'PrivateKey': (str, False), + 'TeamId': (str, False), + 'TokenKey': (str, False), + 'TokenKeyId': (str, False), } @@ -77,15 +77,15 @@ class APNSVoipSandboxChannel(AWSObject): resource_type = "AWS::Pinpoint::APNSVoipSandboxChannel" props = { - 'ApplicationId': (basestring, True), - 'BundleId': (basestring, False), - 'Certificate': (basestring, False), - 'DefaultAuthenticationMethod': (basestring, False), + 'ApplicationId': (str, True), + 'BundleId': (str, False), + 'Certificate': (str, False), + 'DefaultAuthenticationMethod': (str, False), 'Enabled': (boolean, False), - 'PrivateKey': (basestring, False), - 'TeamId': (basestring, False), - 'TokenKey': (basestring, False), - 'TokenKeyId': (basestring, False), + 'PrivateKey': (str, False), + 'TeamId': (str, False), + 'TokenKey': (str, False), + 'TokenKeyId': (str, False), } @@ -93,16 +93,16 @@ class App(AWSObject): resource_type = "AWS::Pinpoint::App" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (dict, False), } class CampaignHook(AWSProperty): props = { - 'LambdaFunctionName': (basestring, False), - 'Mode': (basestring, False), - 'WebUrl': (basestring, False), + 'LambdaFunctionName': (str, False), + 'Mode': (str, False), + 'WebUrl': (str, False), } @@ -117,8 +117,8 @@ class Limits(AWSProperty): class QuietTime(AWSProperty): props = { - 'End': (basestring, True), - 'Start': (basestring, True), + 'End': (str, True), + 'Start': (str, True), } @@ -126,7 +126,7 @@ class ApplicationSettings(AWSObject): resource_type = "AWS::Pinpoint::ApplicationSettings" props = { - 'ApplicationId': (basestring, True), + 'ApplicationId': (str, True), 'CampaignHook': (CampaignHook, False), 'CloudWatchMetricsEnabled': (boolean, False), 'Limits': (Limits, False), @@ -138,47 +138,47 @@ class BaiduChannel(AWSObject): resource_type = "AWS::Pinpoint::BaiduChannel" props = { - 'ApiKey': (basestring, True), - 'ApplicationId': (basestring, True), + 'ApiKey': (str, True), + 'ApplicationId': (str, True), 'Enabled': (boolean, False), - 'SecretKey': (basestring, True), + 'SecretKey': (str, True), } class CampaignEmailMessage(AWSProperty): props = { - 'Body': (basestring, False), - 'FromAddress': (basestring, False), - 'HtmlBody': (basestring, False), - 'Title': (basestring, False), + 'Body': (str, False), + 'FromAddress': (str, False), + 'HtmlBody': (str, False), + 'Title': (str, False), } class CampaignSmsMessage(AWSProperty): props = { - 'Body': (basestring, False), - 'EntityId': (basestring, False), - 'MessageType': (basestring, False), - 'OriginationNumber': (basestring, False), - 'SenderId': (basestring, False), - 'TemplateId': (basestring, False), + 'Body': (str, False), + 'EntityId': (str, False), + 'MessageType': (str, False), + 'OriginationNumber': (str, False), + 'SenderId': (str, False), + 'TemplateId': (str, False), } class Message(AWSProperty): props = { - 'Action': (basestring, False), - 'Body': (basestring, False), - 'ImageIconUrl': (basestring, False), - 'ImageSmallIconUrl': (basestring, False), - 'ImageUrl': (basestring, False), - 'JsonBody': (basestring, False), - 'MediaUrl': (basestring, False), - 'RawContent': (basestring, False), + 'Action': (str, False), + 'Body': (str, False), + 'ImageIconUrl': (str, False), + 'ImageSmallIconUrl': (str, False), + 'ImageUrl': (str, False), + 'JsonBody': (str, False), + 'MediaUrl': (str, False), + 'RawContent': (str, False), 'SilentPush': (boolean, False), 'TimeToLive': (integer, False), - 'Title': (basestring, False), - 'Url': (basestring, False), + 'Title': (str, False), + 'Url': (str, False), } @@ -196,8 +196,8 @@ class MessageConfiguration(AWSProperty): class SetDimension(AWSProperty): props = { - 'DimensionType': (basestring, False), - 'Values': ([basestring], False), + 'DimensionType': (str, False), + 'Values': ([str], False), } @@ -212,19 +212,19 @@ class EventDimensions(AWSProperty): class CampaignEventFilter(AWSProperty): props = { 'Dimensions': (EventDimensions, False), - 'FilterType': (basestring, False), + 'FilterType': (str, False), } class Schedule(AWSProperty): props = { - 'EndTime': (basestring, False), + 'EndTime': (str, False), 'EventFilter': (CampaignEventFilter, False), - 'Frequency': (basestring, False), + 'Frequency': (str, False), 'IsLocalTime': (boolean, False), 'QuietTime': (QuietTime, False), - 'StartTime': (basestring, False), - 'TimeZone': (basestring, False), + 'StartTime': (str, False), + 'TimeZone': (str, False), } @@ -233,8 +233,8 @@ class WriteTreatmentResource(AWSProperty): 'MessageConfiguration': (MessageConfiguration, False), 'Schedule': (Schedule, False), 'SizePercent': (integer, False), - 'TreatmentDescription': (basestring, False), - 'TreatmentName': (basestring, False), + 'TreatmentDescription': (str, False), + 'TreatmentName': (str, False), } @@ -243,20 +243,20 @@ class Campaign(AWSObject): props = { 'AdditionalTreatments': ([WriteTreatmentResource], False), - 'ApplicationId': (basestring, True), + 'ApplicationId': (str, True), 'CampaignHook': (CampaignHook, False), - 'Description': (basestring, False), + 'Description': (str, False), 'HoldoutPercent': (integer, False), 'IsPaused': (boolean, False), 'Limits': (Limits, False), 'MessageConfiguration': (MessageConfiguration, True), - 'Name': (basestring, True), + 'Name': (str, True), 'Schedule': (Schedule, True), - 'SegmentId': (basestring, True), + 'SegmentId': (str, True), 'SegmentVersion': (integer, False), 'Tags': (dict, False), - 'TreatmentDescription': (basestring, False), - 'TreatmentName': (basestring, False), + 'TreatmentDescription': (str, False), + 'TreatmentName': (str, False), } @@ -264,12 +264,12 @@ class EmailChannel(AWSObject): resource_type = "AWS::Pinpoint::EmailChannel" props = { - 'ApplicationId': (basestring, True), - 'ConfigurationSet': (basestring, False), + 'ApplicationId': (str, True), + 'ConfigurationSet': (str, False), 'Enabled': (boolean, False), - 'FromAddress': (basestring, True), - 'Identity': (basestring, True), - 'RoleArn': (basestring, False), + 'FromAddress': (str, True), + 'Identity': (str, True), + 'RoleArn': (str, False), } @@ -277,13 +277,13 @@ class EmailTemplate(AWSObject): resource_type = "AWS::Pinpoint::EmailTemplate" props = { - 'DefaultSubstitutions': (basestring, False), - 'HtmlPart': (basestring, False), - 'Subject': (basestring, True), + 'DefaultSubstitutions': (str, False), + 'HtmlPart': (str, False), + 'Subject': (str, True), 'Tags': (dict, False), - 'TemplateDescription': (basestring, False), - 'TemplateName': (basestring, True), - 'TextPart': (basestring, False), + 'TemplateDescription': (str, False), + 'TemplateName': (str, True), + 'TextPart': (str, False), } @@ -291,9 +291,9 @@ class EventStream(AWSObject): resource_type = "AWS::Pinpoint::EventStream" props = { - 'ApplicationId': (basestring, True), - 'DestinationStreamArn': (basestring, True), - 'RoleArn': (basestring, True), + 'ApplicationId': (str, True), + 'DestinationStreamArn': (str, True), + 'RoleArn': (str, True), } @@ -301,43 +301,43 @@ class GCMChannel(AWSObject): resource_type = "AWS::Pinpoint::GCMChannel" props = { - 'ApiKey': (basestring, True), - 'ApplicationId': (basestring, True), + 'ApiKey': (str, True), + 'ApplicationId': (str, True), 'Enabled': (boolean, False), } class APNSPushNotificationTemplate(AWSProperty): props = { - 'Action': (basestring, False), - 'Body': (basestring, False), - 'MediaUrl': (basestring, False), - 'Sound': (basestring, False), - 'Title': (basestring, False), - 'Url': (basestring, False), + 'Action': (str, False), + 'Body': (str, False), + 'MediaUrl': (str, False), + 'Sound': (str, False), + 'Title': (str, False), + 'Url': (str, False), } class AndroidPushNotificationTemplate(AWSProperty): props = { - 'Action': (basestring, False), - 'Body': (basestring, False), - 'ImageIconUrl': (basestring, False), - 'ImageUrl': (basestring, False), - 'SmallImageIconUrl': (basestring, False), - 'Sound': (basestring, False), - 'Title': (basestring, False), - 'Url': (basestring, False), + 'Action': (str, False), + 'Body': (str, False), + 'ImageIconUrl': (str, False), + 'ImageUrl': (str, False), + 'SmallImageIconUrl': (str, False), + 'Sound': (str, False), + 'Title': (str, False), + 'Url': (str, False), } class DefaultPushNotificationTemplate(AWSProperty): props = { - 'Action': (basestring, False), - 'Body': (basestring, False), - 'Sound': (basestring, False), - 'Title': (basestring, False), - 'Url': (basestring, False), + 'Action': (str, False), + 'Body': (str, False), + 'Sound': (str, False), + 'Title': (str, False), + 'Url': (str, False), } @@ -349,11 +349,11 @@ class PushTemplate(AWSObject): 'APNS': (APNSPushNotificationTemplate, False), 'Baidu': (AndroidPushNotificationTemplate, False), 'Default': (DefaultPushNotificationTemplate, False), - 'DefaultSubstitutions': (basestring, False), + 'DefaultSubstitutions': (str, False), 'GCM': (AndroidPushNotificationTemplate, False), 'Tags': (dict, False), - 'TemplateDescription': (basestring, False), - 'TemplateName': (basestring, True), + 'TemplateDescription': (str, False), + 'TemplateName': (str, True), } @@ -361,17 +361,17 @@ class SMSChannel(AWSObject): resource_type = "AWS::Pinpoint::SMSChannel" props = { - 'ApplicationId': (basestring, True), + 'ApplicationId': (str, True), 'Enabled': (boolean, False), - 'SenderId': (basestring, False), - 'ShortCode': (basestring, False), + 'SenderId': (str, False), + 'ShortCode': (str, False), } class Recency(AWSProperty): props = { - 'Duration': (basestring, True), - 'RecencyType': (basestring, True), + 'Duration': (str, True), + 'RecencyType': (str, True), } @@ -426,7 +426,7 @@ class SegmentDimensions(AWSProperty): class SourceSegments(AWSProperty): props = { - 'Id': (basestring, True), + 'Id': (str, True), 'Version': (integer, False), } @@ -435,15 +435,15 @@ class Groups(AWSProperty): props = { 'Dimensions': ([SegmentDimensions], False), 'SourceSegments': ([SourceSegments], False), - 'SourceType': (basestring, False), - 'Type': (basestring, False), + 'SourceType': (str, False), + 'Type': (str, False), } class SegmentGroups(AWSProperty): props = { 'Groups': ([Groups], False), - 'Include': (basestring, False), + 'Include': (str, False), } @@ -451,9 +451,9 @@ class Segment(AWSObject): resource_type = "AWS::Pinpoint::Segment" props = { - 'ApplicationId': (basestring, True), + 'ApplicationId': (str, True), 'Dimensions': (SegmentDimensions, False), - 'Name': (basestring, True), + 'Name': (str, True), 'SegmentGroups': (SegmentGroups, False), 'Tags': (dict, False), } @@ -463,11 +463,11 @@ class SmsTemplate(AWSObject): resource_type = "AWS::Pinpoint::SmsTemplate" props = { - 'Body': (basestring, True), - 'DefaultSubstitutions': (basestring, False), + 'Body': (str, True), + 'DefaultSubstitutions': (str, False), 'Tags': (dict, False), - 'TemplateDescription': (basestring, False), - 'TemplateName': (basestring, True), + 'TemplateDescription': (str, False), + 'TemplateName': (str, True), } @@ -475,6 +475,6 @@ class VoiceChannel(AWSObject): resource_type = "AWS::Pinpoint::VoiceChannel" props = { - 'ApplicationId': (basestring, True), + 'ApplicationId': (str, True), 'Enabled': (boolean, False), } diff --git a/troposphere/pinpointemail.py b/troposphere/pinpointemail.py index 88b30e55b..af6e49763 100644 --- a/troposphere/pinpointemail.py +++ b/troposphere/pinpointemail.py @@ -15,7 +15,7 @@ class DeliveryOptions(AWSProperty): props = { - 'SendingPoolName': (basestring, False), + 'SendingPoolName': (str, False), } @@ -33,7 +33,7 @@ class SendingOptions(AWSProperty): class TrackingOptions(AWSProperty): props = { - 'CustomRedirectDomain': (basestring, False), + 'CustomRedirectDomain': (str, False), } @@ -42,7 +42,7 @@ class ConfigurationSet(AWSObject): props = { 'DeliveryOptions': (DeliveryOptions, False), - 'Name': (basestring, True), + 'Name': (str, True), 'ReputationOptions': (ReputationOptions, False), 'SendingOptions': (SendingOptions, False), 'Tags': (Tags, False), @@ -52,9 +52,9 @@ class ConfigurationSet(AWSObject): class DimensionConfiguration(AWSProperty): props = { - 'DefaultDimensionValue': (basestring, True), - 'DimensionName': (basestring, True), - 'DimensionValueSource': (basestring, True), + 'DefaultDimensionValue': (str, True), + 'DimensionName': (str, True), + 'DimensionValueSource': (str, True), } @@ -66,20 +66,20 @@ class CloudWatchDestination(AWSProperty): class KinesisFirehoseDestination(AWSProperty): props = { - 'DeliveryStreamArn': (basestring, True), - 'IamRoleArn': (basestring, True), + 'DeliveryStreamArn': (str, True), + 'IamRoleArn': (str, True), } class PinpointDestination(AWSProperty): props = { - 'ApplicationArn': (basestring, False), + 'ApplicationArn': (str, False), } class SnsDestination(AWSProperty): props = { - 'TopicArn': (basestring, True), + 'TopicArn': (str, True), } @@ -88,7 +88,7 @@ class EventDestination(AWSProperty): 'CloudWatchDestination': (CloudWatchDestination, False), 'Enabled': (boolean, False), 'KinesisFirehoseDestination': (KinesisFirehoseDestination, False), - 'MatchingEventTypes': ([basestring], True), + 'MatchingEventTypes': ([str], True), 'PinpointDestination': (PinpointDestination, False), 'SnsDestination': (SnsDestination, False), } @@ -98,9 +98,9 @@ class ConfigurationSetEventDestination(AWSObject): resource_type = "AWS::PinpointEmail::ConfigurationSetEventDestination" props = { - 'ConfigurationSetName': (basestring, True), + 'ConfigurationSetName': (str, True), 'EventDestination': (EventDestination, False), - 'EventDestinationName': (basestring, True), + 'EventDestinationName': (str, True), } @@ -108,15 +108,15 @@ class DedicatedIpPool(AWSObject): resource_type = "AWS::PinpointEmail::DedicatedIpPool" props = { - 'PoolName': (basestring, False), + 'PoolName': (str, False), 'Tags': (Tags, False), } class MailFromAttributes(AWSProperty): props = { - 'BehaviorOnMxFailure': (basestring, False), - 'MailFromDomain': (basestring, False), + 'BehaviorOnMxFailure': (str, False), + 'MailFromDomain': (str, False), } @@ -127,6 +127,6 @@ class Identity(AWSObject): 'DkimSigningEnabled': (boolean, False), 'FeedbackForwardingEnabled': (boolean, False), 'MailFromAttributes': (MailFromAttributes, False), - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/policies.py b/troposphere/policies.py index 4b50a8fa3..790f2c8db 100644 --- a/troposphere/policies.py +++ b/troposphere/policies.py @@ -8,7 +8,7 @@ class AutoScalingRollingUpdate(AWSProperty): 'MinInstancesInService': (integer, False), 'MinSuccessfulInstancesPercent': (integer, False), 'PauseTime': (validate_pausetime, False), - 'SuspendProcesses': ([basestring], False), + 'SuspendProcesses': ([str], False), 'WaitOnResourceSignals': (boolean, False), } @@ -27,9 +27,9 @@ class AutoScalingReplacingUpdate(AWSProperty): class CodeDeployLambdaAliasUpdate(AWSProperty): props = { - 'AfterAllowTrafficHook': (basestring, False), + 'AfterAllowTrafficHook': (str, False), 'ApplicationName': (boolean, True), - 'BeforeAllowTrafficHook': (basestring, False), + 'BeforeAllowTrafficHook': (str, False), 'DeploymentGroupName': (boolean, True), } diff --git a/troposphere/qldb.py b/troposphere/qldb.py index ca6d5c845..72fa93861 100644 --- a/troposphere/qldb.py +++ b/troposphere/qldb.py @@ -18,8 +18,8 @@ class Ledger(AWSObject): props = { 'DeletionProtection': (boolean, False), - 'Name': (basestring, False), - 'PermissionsMode': (basestring, True), + 'Name': (str, False), + 'PermissionsMode': (str, True), 'Tags': (Tags, False), } @@ -27,7 +27,7 @@ class Ledger(AWSObject): class KinesisConfiguration(AWSProperty): props = { 'AggregationEnabled': (boolean, False), - 'StreamArn': (basestring, False), + 'StreamArn': (str, False), } @@ -35,11 +35,11 @@ class Stream(AWSObject): resource_type = "AWS::QLDB::Stream" props = { - 'ExclusiveEndTime': (basestring, False), - 'InclusiveStartTime': (basestring, True), + 'ExclusiveEndTime': (str, False), + 'InclusiveStartTime': (str, True), 'KinesisConfiguration': (KinesisConfiguration, True), - 'LedgerName': (basestring, True), - 'RoleArn': (basestring, True), - 'StreamName': (basestring, True), + 'LedgerName': (str, True), + 'RoleArn': (str, True), + 'StreamName': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/quicksight.py b/troposphere/quicksight.py index 23fcbd1b9..eff1b06bd 100644 --- a/troposphere/quicksight.py +++ b/troposphere/quicksight.py @@ -16,21 +16,21 @@ class AnalysisError(AWSProperty): props = { - 'Message': (basestring, False), - 'Type': (basestring, False), + 'Message': (str, False), + 'Type': (str, False), } class DataSetReference(AWSProperty): props = { - 'DataSetArn': (basestring, True), - 'DataSetPlaceholder': (basestring, True), + 'DataSetArn': (str, True), + 'DataSetPlaceholder': (str, True), } class AnalysisSourceTemplate(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'DataSetReferences': ([DataSetReference], True), } @@ -43,29 +43,29 @@ class AnalysisSourceEntity(AWSProperty): class DateTimeParameter(AWSProperty): props = { - 'Name': (basestring, True), - 'Values': ([basestring], True), + 'Name': (str, True), + 'Values': ([str], True), } class DecimalParameter(AWSProperty): props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Values': ([double], True), } class IntegerParameter(AWSProperty): props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Values': ([double], True), } class StringParameter(AWSProperty): props = { - 'Name': (basestring, True), - 'Values': ([basestring], True), + 'Name': (str, True), + 'Values': ([str], True), } @@ -80,8 +80,8 @@ class Parameters(AWSProperty): class ResourcePermission(AWSProperty): props = { - 'Actions': ([basestring], True), - 'Principal': (basestring, True), + 'Actions': ([str], True), + 'Principal': (str, True), } @@ -89,33 +89,33 @@ class Analysis(AWSObject): resource_type = "AWS::QuickSight::Analysis" props = { - 'AnalysisId': (basestring, True), - 'AwsAccountId': (basestring, True), + 'AnalysisId': (str, True), + 'AwsAccountId': (str, True), 'Errors': ([AnalysisError], False), - 'Name': (basestring, False), + 'Name': (str, False), 'Parameters': (Parameters, False), 'Permissions': ([ResourcePermission], False), 'SourceEntity': (AnalysisSourceEntity, False), 'Tags': (Tags, False), - 'ThemeArn': (basestring, False), + 'ThemeArn': (str, False), } class AdHocFilteringOption(AWSProperty): props = { - 'AvailabilityStatus': (basestring, False), + 'AvailabilityStatus': (str, False), } class ExportToCSVOption(AWSProperty): props = { - 'AvailabilityStatus': (basestring, False), + 'AvailabilityStatus': (str, False), } class SheetControlsOption(AWSProperty): props = { - 'VisibilityState': (basestring, False), + 'VisibilityState': (str, False), } @@ -129,7 +129,7 @@ class DashboardPublishOptions(AWSProperty): class DashboardSourceTemplate(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'DataSetReferences': ([DataSetReference], True), } @@ -144,29 +144,29 @@ class Dashboard(AWSObject): resource_type = "AWS::QuickSight::Dashboard" props = { - 'AwsAccountId': (basestring, True), - 'DashboardId': (basestring, True), + 'AwsAccountId': (str, True), + 'DashboardId': (str, True), 'DashboardPublishOptions': (DashboardPublishOptions, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Parameters': (Parameters, False), 'Permissions': ([ResourcePermission], False), 'SourceEntity': (DashboardSourceEntity, False), 'Tags': (Tags, False), - 'ThemeArn': (basestring, False), - 'VersionDescription': (basestring, False), + 'ThemeArn': (str, False), + 'VersionDescription': (str, False), } class TemplateSourceAnalysis(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'DataSetReferences': ([DataSetReference], True), } class TemplateSourceTemplate(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), } @@ -181,21 +181,21 @@ class Template(AWSObject): resource_type = "AWS::QuickSight::Template" props = { - 'AwsAccountId': (basestring, True), - 'Name': (basestring, False), + 'AwsAccountId': (str, True), + 'Name': (str, False), 'Permissions': ([ResourcePermission], False), 'SourceEntity': (TemplateSourceEntity, False), 'Tags': (Tags, False), - 'TemplateId': (basestring, True), - 'VersionDescription': (basestring, False), + 'TemplateId': (str, True), + 'VersionDescription': (str, False), } class DataColorPalette(AWSProperty): props = { - 'Colors': ([basestring], False), - 'EmptyFillColor': (basestring, False), - 'MinMaxGradient': ([basestring], False), + 'Colors': ([str], False), + 'EmptyFillColor': (str, False), + 'MinMaxGradient': ([str], False), } @@ -239,7 +239,7 @@ class SheetStyle(AWSProperty): class Font(AWSProperty): props = { - 'FontFamily': (basestring, False), + 'FontFamily': (str, False), } @@ -251,22 +251,22 @@ class Typography(AWSProperty): class UIColorPalette(AWSProperty): props = { - 'Accent': (basestring, False), - 'AccentForeground': (basestring, False), - 'Danger': (basestring, False), - 'DangerForeground': (basestring, False), - 'Dimension': (basestring, False), - 'DimensionForeground': (basestring, False), - 'Measure': (basestring, False), - 'MeasureForeground': (basestring, False), - 'PrimaryBackground': (basestring, False), - 'PrimaryForeground': (basestring, False), - 'SecondaryBackground': (basestring, False), - 'SecondaryForeground': (basestring, False), - 'Success': (basestring, False), - 'SuccessForeground': (basestring, False), - 'Warning': (basestring, False), - 'WarningForeground': (basestring, False), + 'Accent': (str, False), + 'AccentForeground': (str, False), + 'Danger': (str, False), + 'DangerForeground': (str, False), + 'Dimension': (str, False), + 'DimensionForeground': (str, False), + 'Measure': (str, False), + 'MeasureForeground': (str, False), + 'PrimaryBackground': (str, False), + 'PrimaryForeground': (str, False), + 'SecondaryBackground': (str, False), + 'SecondaryForeground': (str, False), + 'Success': (str, False), + 'SuccessForeground': (str, False), + 'Warning': (str, False), + 'WarningForeground': (str, False), } @@ -283,12 +283,12 @@ class Theme(AWSObject): resource_type = "AWS::QuickSight::Theme" props = { - 'AwsAccountId': (basestring, True), - 'BaseThemeId': (basestring, False), + 'AwsAccountId': (str, True), + 'BaseThemeId': (str, False), 'Configuration': (ThemeConfiguration, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Permissions': ([ResourcePermission], False), 'Tags': (Tags, False), - 'ThemeId': (basestring, True), - 'VersionDescription': (basestring, False), + 'ThemeId': (str, True), + 'VersionDescription': (str, False), } diff --git a/troposphere/ram.py b/troposphere/ram.py index 77523369d..155d639e2 100644 --- a/troposphere/ram.py +++ b/troposphere/ram.py @@ -13,8 +13,8 @@ class ResourceShare(AWSObject): props = { 'AllowExternalPrincipals': (boolean, False), - 'Name': (basestring, True), - 'Principals': ([basestring], False), - 'ResourceArns': ([basestring], False), + 'Name': (str, True), + 'Principals': ([str], False), + 'ResourceArns': ([str], False), 'Tags': (Tags, False), } diff --git a/troposphere/rds.py b/troposphere/rds.py index d0889269b..8d09cf194 100644 --- a/troposphere/rds.py +++ b/troposphere/rds.py @@ -155,16 +155,16 @@ def validate_capacity(capacity): class DBInstanceRole(AWSProperty): props = { - 'FeatureName': (basestring, True), - 'RoleArn': (basestring, True), - 'Status': (basestring, False), + 'FeatureName': (str, True), + 'RoleArn': (str, True), + 'Status': (str, False), } class ProcessorFeature(AWSProperty): props = { - 'Name': (basestring, False), - 'Value': (basestring, False), + 'Name': (str, False), + 'Value': (str, False), } @@ -176,54 +176,54 @@ class DBInstance(AWSObject): 'AllowMajorVersionUpgrade': (boolean, False), 'AssociatedRoles': ([DBInstanceRole], False), 'AutoMinorVersionUpgrade': (boolean, False), - 'AvailabilityZone': (basestring, False), + 'AvailabilityZone': (str, False), 'BackupRetentionPeriod': (validate_backup_retention_period, False), - 'CACertificateIdentifier': (basestring, False), - 'CharacterSetName': (basestring, False), + 'CACertificateIdentifier': (str, False), + 'CharacterSetName': (str, False), 'CopyTagsToSnapshot': (boolean, False), - 'DBClusterIdentifier': (basestring, False), - 'DBInstanceClass': (basestring, True), - 'DBInstanceIdentifier': (basestring, False), - 'DBName': (basestring, False), - 'DBParameterGroupName': (basestring, False), + 'DBClusterIdentifier': (str, False), + 'DBInstanceClass': (str, True), + 'DBInstanceIdentifier': (str, False), + 'DBName': (str, False), + 'DBParameterGroupName': (str, False), 'DBSecurityGroups': (list, False), - 'DBSnapshotIdentifier': (basestring, False), - 'DBSubnetGroupName': (basestring, False), + 'DBSnapshotIdentifier': (str, False), + 'DBSubnetGroupName': (str, False), 'DeleteAutomatedBackups': (boolean, False), 'DeletionProtection': (boolean, False), - 'Domain': (basestring, False), - 'DomainIAMRoleName': (basestring, False), - 'EnableCloudwatchLogsExports': ([basestring], False), + 'Domain': (str, False), + 'DomainIAMRoleName': (str, False), + 'EnableCloudwatchLogsExports': ([str], False), 'EnableIAMDatabaseAuthentication': (boolean, False), 'EnablePerformanceInsights': (boolean, False), 'Engine': (validate_engine, False), - 'EngineVersion': (basestring, False), + 'EngineVersion': (str, False), 'Iops': (validate_iops, False), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'LicenseModel': (validate_license_model, False), - 'MasterUsername': (basestring, False), - 'MasterUserPassword': (basestring, False), + 'MasterUsername': (str, False), + 'MasterUserPassword': (str, False), 'MaxAllocatedStorage': (integer, False), 'MonitoringInterval': (positive_integer, False), - 'MonitoringRoleArn': (basestring, False), + 'MonitoringRoleArn': (str, False), 'MultiAZ': (boolean, False), - 'OptionGroupName': (basestring, False), - 'PerformanceInsightsKMSKeyId': (basestring, False), + 'OptionGroupName': (str, False), + 'PerformanceInsightsKMSKeyId': (str, False), 'PerformanceInsightsRetentionPeriod': (positive_integer, False), 'Port': (network_port, False), 'PreferredBackupWindow': (validate_backup_window, False), - 'PreferredMaintenanceWindow': (basestring, False), + 'PreferredMaintenanceWindow': (str, False), 'ProcessorFeatures': ([ProcessorFeature], False), 'PromotionTier': (positive_integer, False), 'PubliclyAccessible': (boolean, False), - 'SourceDBInstanceIdentifier': (basestring, False), - 'SourceRegion': (basestring, False), + 'SourceDBInstanceIdentifier': (str, False), + 'SourceRegion': (str, False), 'StorageEncrypted': (boolean, False), - 'StorageType': (basestring, False), + 'StorageType': (str, False), 'Tags': ((Tags, list), False), 'UseDefaultProcessorFeatures': (boolean, False), - 'Timezone': (basestring, False), - 'VPCSecurityGroups': ([basestring], False), + 'Timezone': (str, False), + 'VPCSecurityGroups': ([str], False), } def validate(self): @@ -241,7 +241,7 @@ def validate(self): 'DBSnapshotIdentifier', ) - invalid_properties = [s for s in self.properties.keys() if + invalid_properties = [s for s in list(self.properties.keys()) if s in invalid_replica_properties] if invalid_properties: @@ -303,8 +303,8 @@ class DBParameterGroup(AWSObject): resource_type = "AWS::RDS::DBParameterGroup" props = { - 'Description': (basestring, False), - 'Family': (basestring, False), + 'Description': (str, False), + 'Family': (str, False), 'Parameters': (dict, False), 'Tags': ((Tags, list), False), } @@ -312,11 +312,11 @@ class DBParameterGroup(AWSObject): class AuthFormat(AWSProperty): props = { - 'AuthScheme': (basestring, False), - 'Description': (basestring, False), - 'IAMAuth': (basestring, False), - 'SecretArn': (basestring, False), - 'UserName': (basestring, False), + 'AuthScheme': (str, False), + 'Description': (str, False), + 'IAMAuth': (str, False), + 'SecretArn': (str, False), + 'UserName': (str, False), } @@ -325,15 +325,15 @@ class DBProxy(AWSObject): props = { 'Auth': ([AuthFormat], True), - 'DBProxyName': (basestring, True), + 'DBProxyName': (str, True), 'DebugLogging': (boolean, False), - 'EngineFamily': (basestring, True), + 'EngineFamily': (str, True), 'IdleClientTimeout': (integer, False), 'RequireTLS': (boolean, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), - 'VpcSecurityGroupIds': ([basestring], False), - 'VpcSubnetIds': ([basestring], True), + 'VpcSecurityGroupIds': ([str], False), + 'VpcSubnetIds': ([str], True), } @@ -341,22 +341,22 @@ class DBProxyEndpoint(AWSObject): resource_type = "AWS::RDS::DBProxyEndpoint" props = { - 'DBProxyEndpointName': (basestring, True), - 'DBProxyName': (basestring, True), + 'DBProxyEndpointName': (str, True), + 'DBProxyName': (str, True), 'Tags': (Tags, False), - 'TargetRole': (basestring, False), - 'VpcSecurityGroupIds': ([basestring], False), - 'VpcSubnetIds': ([basestring], True), + 'TargetRole': (str, False), + 'VpcSecurityGroupIds': ([str], False), + 'VpcSubnetIds': ([str], True), } class ConnectionPoolConfigurationInfoFormat(AWSProperty): props = { 'ConnectionBorrowTimeout': (integer, False), - 'InitQuery': (basestring, False), + 'InitQuery': (str, False), 'MaxConnectionsPercent': (integer, False), 'MaxIdleConnectionsPercent': (integer, False), - 'SessionPinningFilters': ([basestring], False), + 'SessionPinningFilters': ([str], False), } @@ -366,10 +366,10 @@ class DBProxyTargetGroup(AWSObject): props = { 'ConnectionPoolConfigurationInfo': (ConnectionPoolConfigurationInfoFormat, False), - 'DBClusterIdentifiers': ([basestring], False), - 'DBInstanceIdentifiers': ([basestring], False), - 'DBProxyName': (basestring, True), - 'TargetGroupName': (basestring, True), + 'DBClusterIdentifiers': ([str], False), + 'DBInstanceIdentifiers': ([str], False), + 'DBProxyName': (str, True), + 'TargetGroupName': (str, True), } @@ -377,8 +377,8 @@ class DBSubnetGroup(AWSObject): resource_type = "AWS::RDS::DBSubnetGroup" props = { - 'DBSubnetGroupDescription': (basestring, True), - 'DBSubnetGroupName': (basestring, False), + 'DBSubnetGroupDescription': (str, True), + 'DBSubnetGroupName': (str, False), 'SubnetIds': (list, True), 'Tags': ((Tags, list), False), } @@ -386,10 +386,10 @@ class DBSubnetGroup(AWSObject): class RDSSecurityGroup(AWSProperty): props = { - 'CIDRIP': (basestring, False), - 'EC2SecurityGroupId': (basestring, False), - 'EC2SecurityGroupName': (basestring, False), - 'EC2SecurityGroupOwnerId': (basestring, False), + 'CIDRIP': (str, False), + 'EC2SecurityGroupId': (str, False), + 'EC2SecurityGroupName': (str, False), + 'EC2SecurityGroupOwnerId': (str, False), } @@ -397,9 +397,9 @@ class DBSecurityGroup(AWSObject): resource_type = "AWS::RDS::DBSecurityGroup" props = { - 'EC2VpcId': (basestring, False), + 'EC2VpcId': (str, False), 'DBSecurityGroupIngress': (list, True), - 'GroupDescription': (basestring, True), + 'GroupDescription': (str, True), 'Tags': ((Tags, list), False), } @@ -408,11 +408,11 @@ class DBSecurityGroupIngress(AWSObject): resource_type = "AWS::RDS::DBSecurityGroupIngress" props = { - 'CIDRIP': (basestring, False), - 'DBSecurityGroupName': (basestring, True), - 'EC2SecurityGroupId': (basestring, False), - 'EC2SecurityGroupName': (basestring, False), - 'EC2SecurityGroupOwnerId': (basestring, False), + 'CIDRIP': (str, False), + 'DBSecurityGroupName': (str, True), + 'EC2SecurityGroupId': (str, False), + 'EC2SecurityGroupName': (str, False), + 'EC2SecurityGroupOwnerId': (str, False), } @@ -421,10 +421,10 @@ class EventSubscription(AWSObject): props = { 'Enabled': (boolean, False), - 'EventCategories': ([basestring], False), - 'SnsTopicArn': (basestring, True), - 'SourceIds': ([basestring], False), - 'SourceType': (basestring, False), + 'EventCategories': ([str], False), + 'SnsTopicArn': (str, True), + 'SourceIds': ([str], False), + 'SourceType': (str, False), } @@ -433,29 +433,29 @@ class GlobalCluster(AWSObject): props = { 'DeletionProtection': (boolean, False), - 'Engine': (basestring, False), - 'EngineVersion': (basestring, False), - 'GlobalClusterIdentifier': (basestring, False), - 'SourceDBClusterIdentifier': (basestring, False), + 'Engine': (str, False), + 'EngineVersion': (str, False), + 'GlobalClusterIdentifier': (str, False), + 'SourceDBClusterIdentifier': (str, False), 'StorageEncrypted': (boolean, False), } class OptionSetting(AWSProperty): props = { - 'Name': (basestring, False), - 'Value': (basestring, False), + 'Name': (str, False), + 'Value': (str, False), } class OptionConfiguration(AWSProperty): props = { - 'DBSecurityGroupMemberships': ([basestring], False), - 'OptionName': (basestring, True), + 'DBSecurityGroupMemberships': ([str], False), + 'OptionName': (str, True), 'OptionSettings': ([OptionSetting], False), - 'OptionVersion': (basestring, False), + 'OptionVersion': (str, False), 'Port': (network_port, False), - 'VpcSecurityGroupMemberships': ([basestring], False), + 'VpcSecurityGroupMemberships': ([str], False), } @@ -463,9 +463,9 @@ class OptionGroup(AWSObject): resource_type = "AWS::RDS::OptionGroup" props = { - 'EngineName': (basestring, True), - 'MajorEngineVersion': (basestring, True), - 'OptionGroupDescription': (basestring, True), + 'EngineName': (str, True), + 'MajorEngineVersion': (str, True), + 'OptionGroupDescription': (str, True), 'OptionConfigurations': ([OptionConfiguration], True), 'Tags': ((Tags, list), False), } @@ -475,8 +475,8 @@ class DBClusterParameterGroup(AWSObject): resource_type = "AWS::RDS::DBClusterParameterGroup" props = { - 'Description': (basestring, True), - 'Family': (basestring, True), + 'Description': (str, True), + 'Family': (str, True), 'Parameters': (dict, False), 'Tags': ((Tags, list), False), } @@ -484,9 +484,9 @@ class DBClusterParameterGroup(AWSObject): class DBClusterRole(AWSProperty): props = { - 'FeatureName': (basestring, False), - 'RoleArn': (basestring, True), - 'Status': (basestring, False), + 'FeatureName': (str, False), + 'RoleArn': (str, True), + 'Status': (str, False), } @@ -504,34 +504,34 @@ class DBCluster(AWSObject): props = { 'AssociatedRoles': ([DBClusterRole], False), - 'AvailabilityZones': ([basestring], False), + 'AvailabilityZones': ([str], False), 'BacktrackWindow': (integer_range(0, 259200), False), 'BackupRetentionPeriod': (validate_backup_retention_period, False), - 'DatabaseName': (basestring, False), - 'DBClusterIdentifier': (basestring, False), - 'DBClusterParameterGroupName': (basestring, False), - 'DBSubnetGroupName': (basestring, False), + 'DatabaseName': (str, False), + 'DBClusterIdentifier': (str, False), + 'DBClusterParameterGroupName': (str, False), + 'DBSubnetGroupName': (str, False), 'DeletionProtection': (boolean, False), - 'EnableCloudwatchLogsExports': ([basestring], False), + 'EnableCloudwatchLogsExports': ([str], False), 'EnableHttpEndpoint': (boolean, False), 'EnableIAMDatabaseAuthentication': (boolean, False), 'Engine': (validate_engine, True), 'EngineMode': (validate_engine_mode, False), - 'EngineVersion': (basestring, False), - 'KmsKeyId': (basestring, False), - 'MasterUsername': (basestring, False), - 'MasterUserPassword': (basestring, False), + 'EngineVersion': (str, False), + 'KmsKeyId': (str, False), + 'MasterUsername': (str, False), + 'MasterUserPassword': (str, False), 'Port': (network_port, False), 'PreferredBackupWindow': (validate_backup_window, False), - 'PreferredMaintenanceWindow': (basestring, False), - 'ReplicationSourceIdentifier': (basestring, False), - 'RestoreType': (basestring, False), + 'PreferredMaintenanceWindow': (str, False), + 'ReplicationSourceIdentifier': (str, False), + 'RestoreType': (str, False), 'ScalingConfiguration': (ScalingConfiguration, False), - 'SnapshotIdentifier': (basestring, False), - 'SourceDBClusterIdentifier': (basestring, False), - 'SourceRegion': (basestring, False), + 'SnapshotIdentifier': (str, False), + 'SourceDBClusterIdentifier': (str, False), + 'SourceRegion': (str, False), 'StorageEncrypted': (boolean, False), 'Tags': ((Tags, list), False), 'UseLatestRestorableTime': (boolean, False), - 'VpcSecurityGroupIds': ([basestring], False), + 'VpcSecurityGroupIds': ([str], False), } diff --git a/troposphere/redshift.py b/troposphere/redshift.py index beaf0df2e..45820e4e1 100644 --- a/troposphere/redshift.py +++ b/troposphere/redshift.py @@ -9,8 +9,8 @@ class LoggingProperties(AWSProperty): props = { - 'BucketName': (basestring, True), - 'S3KeyPrefix': (basestring, False), + 'BucketName': (str, True), + 'S3KeyPrefix': (str, False), } @@ -20,31 +20,31 @@ class Cluster(AWSObject): props = { 'AllowVersionUpgrade': (boolean, False), 'AutomatedSnapshotRetentionPeriod': (integer, False), - 'AvailabilityZone': (basestring, False), - 'ClusterIdentifier': (basestring, False), - 'ClusterParameterGroupName': (basestring, False), + 'AvailabilityZone': (str, False), + 'ClusterIdentifier': (str, False), + 'ClusterParameterGroupName': (str, False), 'ClusterSecurityGroups': (list, False), - 'ClusterSubnetGroupName': (basestring, False), - 'ClusterType': (basestring, True), - 'ClusterVersion': (basestring, False), - 'DBName': (basestring, True), - 'ElasticIp': (basestring, False), + 'ClusterSubnetGroupName': (str, False), + 'ClusterType': (str, True), + 'ClusterVersion': (str, False), + 'DBName': (str, True), + 'ElasticIp': (str, False), 'Encrypted': (boolean, False), - 'HsmClientCertificateIdentifier': (basestring, False), - 'HsmConfigurationIdentifier': (basestring, False), - 'IamRoles': ([basestring], False), - 'KmsKeyId': (basestring, False), + 'HsmClientCertificateIdentifier': (str, False), + 'HsmConfigurationIdentifier': (str, False), + 'IamRoles': ([str], False), + 'KmsKeyId': (str, False), 'LoggingProperties': (LoggingProperties, False), - 'MasterUsername': (basestring, True), - 'MasterUserPassword': (basestring, True), - 'NodeType': (basestring, True), + 'MasterUsername': (str, True), + 'MasterUserPassword': (str, True), + 'NodeType': (str, True), 'NumberOfNodes': (integer, False), # Conditional - 'OwnerAccount': (basestring, False), + 'OwnerAccount': (str, False), 'Port': (integer, False), - 'PreferredMaintenanceWindow': (basestring, False), + 'PreferredMaintenanceWindow': (str, False), 'PubliclyAccessible': (boolean, False), - 'SnapshotClusterIdentifier': (basestring, False), - 'SnapshotIdentifier': (basestring, False), + 'SnapshotClusterIdentifier': (str, False), + 'SnapshotIdentifier': (str, False), 'Tags': (Tags, False), 'VpcSecurityGroupIds': (list, False), } @@ -52,8 +52,8 @@ class Cluster(AWSObject): class AmazonRedshiftParameter(AWSProperty): props = { - 'ParameterName': (basestring, True), - 'ParameterValue': (basestring, True), + 'ParameterName': (str, True), + 'ParameterValue': (str, True), } @@ -61,8 +61,8 @@ class ClusterParameterGroup(AWSObject): resource_type = "AWS::Redshift::ClusterParameterGroup" props = { - 'Description': (basestring, True), - 'ParameterGroupFamily': (basestring, True), + 'Description': (str, True), + 'ParameterGroupFamily': (str, True), 'Parameters': ([AmazonRedshiftParameter], False), 'Tags': (Tags, False), } @@ -72,7 +72,7 @@ class ClusterSecurityGroup(AWSObject): resource_type = "AWS::Redshift::ClusterSecurityGroup" props = { - 'Description': (basestring, True), + 'Description': (str, True), 'Tags': (Tags, False), } @@ -81,10 +81,10 @@ class ClusterSecurityGroupIngress(AWSObject): resource_type = "AWS::Redshift::ClusterSecurityGroupIngress" props = { - 'ClusterSecurityGroupName': (basestring, True), - 'CIDRIP': (basestring, False), - 'EC2SecurityGroupName': (basestring, False), - 'EC2SecurityGroupOwnerId': (basestring, False), + 'ClusterSecurityGroupName': (str, True), + 'CIDRIP': (str, False), + 'EC2SecurityGroupName': (str, False), + 'EC2SecurityGroupOwnerId': (str, False), } @@ -92,7 +92,7 @@ class ClusterSubnetGroup(AWSObject): resource_type = "AWS::Redshift::ClusterSubnetGroup" props = { - 'Description': (basestring, True), + 'Description': (str, True), 'SubnetIds': (list, True), 'Tags': (Tags, False), } diff --git a/troposphere/resourcegroups.py b/troposphere/resourcegroups.py index bb6bcbf0c..c6f97cc86 100644 --- a/troposphere/resourcegroups.py +++ b/troposphere/resourcegroups.py @@ -9,15 +9,15 @@ class TagFilter(AWSProperty): props = { - 'Key': (basestring, False), - 'Values': ([basestring], False), + 'Key': (str, False), + 'Values': ([str], False), } class Query(AWSProperty): props = { - 'ResourceTypeFilters': ([basestring], False), - 'StackIdentifier': (basestring, False), + 'ResourceTypeFilters': ([str], False), + 'StackIdentifier': (str, False), 'TagFilters': ([TagFilter], False), } @@ -33,8 +33,8 @@ class Group(AWSObject): resource_type = "AWS::ResourceGroups::Group" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'ResourceQuery': (ResourceQuery, False), 'Tags': (Tags, False), } diff --git a/troposphere/robomaker.py b/troposphere/robomaker.py index 52d1c4bcd..d0b00ed6a 100644 --- a/troposphere/robomaker.py +++ b/troposphere/robomaker.py @@ -12,7 +12,7 @@ class Fleet(AWSObject): resource_type = "AWS::RoboMaker::Fleet" props = { - 'Name': (basestring, False), + 'Name': (str, False), 'Tags': (Tags, False), } @@ -21,26 +21,26 @@ class Robot(AWSObject): resource_type = "AWS::RoboMaker::Robot" props = { - 'Architecture': (basestring, True), - 'Fleet': (basestring, False), - 'GreengrassGroupId': (basestring, True), - 'Name': (basestring, False), + 'Architecture': (str, True), + 'Fleet': (str, False), + 'GreengrassGroupId': (str, True), + 'Name': (str, False), 'Tags': (Tags, False), } class RobotSoftwareSuite(AWSProperty): props = { - 'Name': (basestring, True), - 'Version': (basestring, True), + 'Name': (str, True), + 'Version': (str, True), } class SourceConfig(AWSProperty): props = { - 'Architecture': (basestring, True), - 'S3Bucket': (basestring, True), - 'S3Key': (basestring, True), + 'Architecture': (str, True), + 'S3Bucket': (str, True), + 'S3Key': (str, True), } @@ -48,8 +48,8 @@ class RobotApplication(AWSObject): resource_type = "AWS::RoboMaker::RobotApplication" props = { - 'CurrentRevisionId': (basestring, False), - 'Name': (basestring, False), + 'CurrentRevisionId': (str, False), + 'Name': (str, False), 'RobotSoftwareSuite': (RobotSoftwareSuite, True), 'Sources': ([SourceConfig], True), 'Tags': (Tags, False), @@ -60,22 +60,22 @@ class RobotApplicationVersion(AWSObject): resource_type = "AWS::RoboMaker::RobotApplicationVersion" props = { - 'Application': (basestring, True), - 'CurrentRevisionId': (basestring, False), + 'Application': (str, True), + 'CurrentRevisionId': (str, False), } class RenderingEngine(AWSProperty): props = { - 'Name': (basestring, True), - 'Version': (basestring, True), + 'Name': (str, True), + 'Version': (str, True), } class SimulationSoftwareSuite(AWSProperty): props = { - 'Name': (basestring, True), - 'Version': (basestring, True), + 'Name': (str, True), + 'Version': (str, True), } @@ -83,8 +83,8 @@ class SimulationApplication(AWSObject): resource_type = "AWS::RoboMaker::SimulationApplication" props = { - 'CurrentRevisionId': (basestring, False), - 'Name': (basestring, False), + 'CurrentRevisionId': (str, False), + 'Name': (str, False), 'RenderingEngine': (RenderingEngine, True), 'RobotSoftwareSuite': (RobotSoftwareSuite, True), 'SimulationSoftwareSuite': (SimulationSoftwareSuite, True), @@ -97,6 +97,6 @@ class SimulationApplicationVersion(AWSObject): resource_type = "AWS::RoboMaker::SimulationApplicationVersion" props = { - 'Application': (basestring, True), - 'CurrentRevisionId': (basestring, False), + 'Application': (str, True), + 'CurrentRevisionId': (str, False), } diff --git a/troposphere/route53.py b/troposphere/route53.py index 4a6e25ac9..540512a63 100644 --- a/troposphere/route53.py +++ b/troposphere/route53.py @@ -23,7 +23,7 @@ class DNSSEC(AWSObject): resource_type = "AWS::Route53::DNSSEC" props = { - 'HostedZoneId': (basestring, True), + 'HostedZoneId': (str, True), } @@ -31,17 +31,17 @@ class KeySigningKey(AWSObject): resource_type = "AWS::Route53::KeySigningKey" props = { - 'HostedZoneId': (basestring, True), - 'KeyManagementServiceArn': (basestring, True), - 'Name': (basestring, True), - 'Status': (basestring, True), + 'HostedZoneId': (str, True), + 'KeyManagementServiceArn': (str, True), + 'Name': (str, True), + 'Status': (str, True), } class AliasTarget(AWSProperty): props = { - 'HostedZoneId': (basestring, True), - 'DNSName': (basestring, True), + 'HostedZoneId': (str, True), + 'DNSName': (str, True), 'EvaluateTargetHealth': (boolean, False) } @@ -62,28 +62,28 @@ def __init__(self, class GeoLocation(AWSProperty): props = { - 'ContinentCode': (basestring, False), - 'CountryCode': (basestring, False), - 'SubdivisionCode': (basestring, False), + 'ContinentCode': (str, False), + 'CountryCode': (str, False), + 'SubdivisionCode': (str, False), } class BaseRecordSet(object): props = { 'AliasTarget': (AliasTarget, False), - 'Comment': (basestring, False), - 'Failover': (basestring, False), + 'Comment': (str, False), + 'Failover': (str, False), 'GeoLocation': (GeoLocation, False), - 'HealthCheckId': (basestring, False), - 'HostedZoneId': (basestring, False), - 'HostedZoneName': (basestring, False), + 'HealthCheckId': (str, False), + 'HostedZoneId': (str, False), + 'HostedZoneName': (str, False), 'MultiValueAnswer': (boolean, False), - 'Name': (basestring, True), - 'Region': (basestring, False), + 'Name': (str, True), + 'Region': (str, False), 'ResourceRecords': (list, False), - 'SetIdentifier': (basestring, False), + 'SetIdentifier': (str, False), 'TTL': (integer, False), - 'Type': (basestring, True), + 'Type': (str, True), 'Weight': (integer, False), } @@ -102,38 +102,38 @@ class RecordSetGroup(AWSObject): resource_type = "AWS::Route53::RecordSetGroup" props = { - 'HostedZoneId': (basestring, False), - 'HostedZoneName': (basestring, False), + 'HostedZoneId': (str, False), + 'HostedZoneName': (str, False), 'RecordSets': (list, False), - 'Comment': (basestring, False), + 'Comment': (str, False), } class AlarmIdentifier(AWSProperty): props = { - 'Name': (basestring, True), - 'Region': (basestring, True), + 'Name': (str, True), + 'Region': (str, True), } class HealthCheckConfiguration(AWSProperty): props = { 'AlarmIdentifier': (AlarmIdentifier, False), - 'ChildHealthChecks': ([basestring], False), + 'ChildHealthChecks': ([str], False), 'EnableSNI': (boolean, False), 'FailureThreshold': (positive_integer, False), - 'FullyQualifiedDomainName': (basestring, False), + 'FullyQualifiedDomainName': (str, False), 'HealthThreshold': (positive_integer, False), - 'InsufficientDataHealthStatus': (basestring, False), + 'InsufficientDataHealthStatus': (str, False), 'Inverted': (boolean, False), - 'IPAddress': (basestring, False), + 'IPAddress': (str, False), 'MeasureLatency': (boolean, False), 'Port': (network_port, False), - 'Regions': ([basestring], False), + 'Regions': ([str], False), 'RequestInterval': (positive_integer, False), - 'ResourcePath': (basestring, False), - 'SearchString': (basestring, False), - 'Type': (basestring, True), + 'ResourcePath': (str, False), + 'SearchString': (str, False), + 'Type': (str, True), } @@ -148,20 +148,20 @@ class HealthCheck(AWSObject): class HostedZoneConfiguration(AWSProperty): props = { - 'Comment': (basestring, False), + 'Comment': (str, False), } class HostedZoneVPCs(AWSProperty): props = { - 'VPCId': (basestring, True), - 'VPCRegion': (basestring, True), + 'VPCId': (str, True), + 'VPCRegion': (str, True), } class QueryLoggingConfig(AWSProperty): props = { - 'CloudWatchLogsLogGroupArn': (basestring, True), + 'CloudWatchLogsLogGroupArn': (str, True), } @@ -171,7 +171,7 @@ class HostedZone(AWSObject): props = { 'HostedZoneConfig': (HostedZoneConfiguration, False), 'HostedZoneTags': (Tags, False), - 'Name': (basestring, True), + 'Name': (str, True), 'QueryLoggingConfig': (QueryLoggingConfig, False), 'VPCs': ([HostedZoneVPCs], False), } @@ -181,14 +181,14 @@ class ResolverDNSSECConfig(AWSObject): resource_type = "AWS::Route53Resolver::ResolverDNSSECConfig" props = { - 'ResourceId': (basestring, False), + 'ResourceId': (str, False), } class IpAddressRequest(AWSProperty): props = { - 'Ip': (basestring, False), - 'SubnetId': (basestring, True), + 'Ip': (str, False), + 'SubnetId': (str, True), } @@ -196,10 +196,10 @@ class ResolverEndpoint(AWSObject): resource_type = "AWS::Route53Resolver::ResolverEndpoint" props = { - 'Direction': (basestring, True), + 'Direction': (str, True), 'IpAddresses': ([IpAddressRequest], True), - 'Name': (basestring, False), - 'SecurityGroupIds': ([basestring], True), + 'Name': (str, False), + 'SecurityGroupIds': ([str], True), 'Tags': (Tags, False), } @@ -208,8 +208,8 @@ class ResolverQueryLoggingConfig(AWSObject): resource_type = "AWS::Route53Resolver::ResolverQueryLoggingConfig" props = { - 'DestinationArn': (basestring, False), - 'Name': (basestring, False), + 'DestinationArn': (str, False), + 'Name': (str, False), } @@ -218,15 +218,15 @@ class ResolverQueryLoggingConfigAssociation(AWSObject): "AWS::Route53Resolver::ResolverQueryLoggingConfigAssociation" props = { - 'ResolverQueryLogConfigId': (basestring, False), - 'ResourceId': (basestring, False), + 'ResolverQueryLogConfigId': (str, False), + 'ResourceId': (str, False), } class TargetAddress(AWSProperty): props = { - 'Ip': (basestring, True), - 'Port': (basestring, True), + 'Ip': (str, True), + 'Port': (str, True), } @@ -234,9 +234,9 @@ class ResolverRule(AWSObject): resource_type = "AWS::Route53Resolver::ResolverRule" props = { - 'DomainName': (basestring, True), - 'Name': (basestring, False), - 'ResolverEndpointId': (basestring, False), + 'DomainName': (str, True), + 'Name': (str, False), + 'ResolverEndpointId': (str, False), 'RuleType': (validate_ruletype, True), 'Tags': (Tags, False), 'TargetIps': ([TargetAddress], False), @@ -247,7 +247,7 @@ class ResolverRuleAssociation(AWSObject): resource_type = "AWS::Route53Resolver::ResolverRuleAssociation" props = { - 'Name': (basestring, False), - 'ResolverRuleId': (basestring, True), - 'VPCId': (basestring, True), + 'Name': (str, False), + 'ResolverRuleId': (str, True), + 'VPCId': (str, True), } diff --git a/troposphere/s3.py b/troposphere/s3.py index 97d13aa81..b71703f0a 100644 --- a/troposphere/s3.py +++ b/troposphere/s3.py @@ -29,7 +29,7 @@ class PublicAccessBlockConfiguration(AWSProperty): class VpcConfiguration(AWSProperty): props = { - 'VpcId': (basestring, False), + 'VpcId': (str, False), } @@ -37,10 +37,10 @@ class AccessPoint(AWSObject): resource_type = "AWS::S3::AccessPoint" props = { - 'Bucket': (basestring, True), - 'CreationDate': (basestring, False), - 'Name': (basestring, False), - 'NetworkOrigin': (basestring, False), + 'Bucket': (str, True), + 'CreationDate': (str, False), + 'Name': (str, False), + 'NetworkOrigin': (str, False), 'Policy': (dict, False), 'PolicyStatus': (dict, False), 'PublicAccessBlockConfiguration': @@ -51,11 +51,11 @@ class AccessPoint(AWSObject): class CorsRules(AWSProperty): props = { - 'AllowedHeaders': ([basestring], False), - 'AllowedMethods': ([basestring], True), - 'AllowedOrigins': ([basestring], True), - 'ExposedHeaders': ([basestring], False), - 'Id': (basestring, False), + 'AllowedHeaders': ([str], False), + 'AllowedMethods': ([str], True), + 'AllowedOrigins': ([str], True), + 'ExposedHeaders': ([str], False), + 'Id': (str, False), 'MaxAge': (positive_integer, False), } @@ -68,7 +68,7 @@ class CorsConfiguration(AWSProperty): class VersioningConfiguration(AWSProperty): props = { - 'Status': (basestring, False), + 'Status': (str, False), } @@ -80,25 +80,25 @@ class AccelerateConfiguration(AWSProperty): class RedirectAllRequestsTo(AWSProperty): props = { - 'HostName': (basestring, True), - 'Protocol': (basestring, False), + 'HostName': (str, True), + 'Protocol': (str, False), } class RedirectRule(AWSProperty): props = { - 'HostName': (basestring, False), - 'HttpRedirectCode': (basestring, False), - 'Protocol': (basestring, False), - 'ReplaceKeyPrefixWith': (basestring, False), - 'ReplaceKeyWith': (basestring, False), + 'HostName': (str, False), + 'HttpRedirectCode': (str, False), + 'Protocol': (str, False), + 'ReplaceKeyPrefixWith': (str, False), + 'ReplaceKeyWith': (str, False), } class RoutingRuleCondition(AWSProperty): props = { - 'HttpErrorCodeReturnedEquals': (basestring, False), - 'KeyPrefixEquals': (basestring, False), + 'HttpErrorCodeReturnedEquals': (str, False), + 'KeyPrefixEquals': (str, False), } @@ -111,8 +111,8 @@ class RoutingRule(AWSProperty): class WebsiteConfiguration(AWSProperty): props = { - 'IndexDocument': (basestring, False), - 'ErrorDocument': (basestring, False), + 'IndexDocument': (str, False), + 'ErrorDocument': (str, False), 'RedirectAllRequestsTo': (RedirectAllRequestsTo, False), 'RoutingRules': ([RoutingRule], False), } @@ -120,8 +120,8 @@ class WebsiteConfiguration(AWSProperty): class LifecycleRuleTransition(AWSProperty): props = { - 'StorageClass': (basestring, True), - 'TransitionDate': (basestring, False), + 'StorageClass': (str, True), + 'TransitionDate': (str, False), 'TransitionInDays': (positive_integer, False), } @@ -134,15 +134,15 @@ class AbortIncompleteMultipartUpload(AWSProperty): class NoncurrentVersionTransition(AWSProperty): props = { - 'StorageClass': (basestring, True), + 'StorageClass': (str, True), 'TransitionInDays': (positive_integer, True), } class TagFilter(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -150,14 +150,14 @@ class LifecycleRule(AWSProperty): props = { 'AbortIncompleteMultipartUpload': (AbortIncompleteMultipartUpload, False), - 'ExpirationDate': (basestring, False), + 'ExpirationDate': (str, False), 'ExpirationInDays': (positive_integer, False), - 'Id': (basestring, False), + 'Id': (str, False), 'NoncurrentVersionExpirationInDays': (positive_integer, False), 'NoncurrentVersionTransition': (NoncurrentVersionTransition, False), 'NoncurrentVersionTransitions': ([NoncurrentVersionTransition], False), - 'Prefix': (basestring, False), - 'Status': (basestring, True), + 'Prefix': (str, False), + 'Status': (str, True), 'TagFilters': ([TagFilter], False), 'Transition': (LifecycleRuleTransition, False), 'Transitions': ([LifecycleRuleTransition], False) @@ -210,14 +210,14 @@ class LifecycleConfiguration(AWSProperty): class LoggingConfiguration(AWSProperty): props = { 'DestinationBucketName': (s3_bucket_name, False), - 'LogFilePrefix': (basestring, False), + 'LogFilePrefix': (str, False), } class Rules(AWSProperty): props = { - 'Name': (basestring, True), - 'Value': (basestring, True) + 'Name': (str, True), + 'Value': (str, True) } @@ -235,32 +235,32 @@ class Filter(AWSProperty): class LambdaConfigurations(AWSProperty): props = { - 'Event': (basestring, True), + 'Event': (str, True), 'Filter': (Filter, False), - 'Function': (basestring, True), + 'Function': (str, True), } class QueueConfigurations(AWSProperty): props = { - 'Event': (basestring, True), + 'Event': (str, True), 'Filter': (Filter, False), - 'Queue': (basestring, True), + 'Queue': (str, True), } class TopicConfigurations(AWSProperty): props = { - 'Event': (basestring, True), + 'Event': (str, True), 'Filter': (Filter, False), - 'Topic': (basestring, True), + 'Topic': (str, True), } class MetricsConfiguration(AWSProperty): props = { - 'Id': (basestring, True), - 'Prefix': (basestring, False), + 'Id': (str, True), + 'Prefix': (str, False), 'TagFilters': ([TagFilter], False), } @@ -275,7 +275,7 @@ class NotificationConfiguration(AWSProperty): class OwnershipControlsRule(AWSProperty): props = { - 'ObjectOwnership': (basestring, False), + 'ObjectOwnership': (str, False), } @@ -287,19 +287,19 @@ class OwnershipControls(AWSProperty): class DeleteMarkerReplication(AWSProperty): props = { - 'Status': (basestring, False), + 'Status': (str, False), } class AccessControlTranslation(AWSProperty): props = { - 'Owner': (basestring, True), + 'Owner': (str, True), } class EncryptionConfiguration(AWSProperty): props = { - 'ReplicaKmsKeyID': (basestring, True), + 'ReplicaKmsKeyID': (str, True), } @@ -312,13 +312,13 @@ class ReplicationTimeValue(AWSProperty): class Metrics(AWSProperty): props = { 'EventThreshold': (ReplicationTimeValue, False), - 'Status': (basestring, True), + 'Status': (str, True), } class ReplicationTime(AWSProperty): props = { - 'Status': (basestring, True), + 'Status': (str, True), 'Time': (ReplicationTimeValue, True), } @@ -326,18 +326,18 @@ class ReplicationTime(AWSProperty): class ReplicationConfigurationRulesDestination(AWSProperty): props = { 'AccessControlTranslation': (AccessControlTranslation, False), - 'Account': (basestring, False), - 'Bucket': (basestring, True), + 'Account': (str, False), + 'Bucket': (str, True), 'EncryptionConfiguration': (EncryptionConfiguration, False), 'Metrics': (Metrics, False), 'ReplicationTime': (ReplicationTime, False), - 'StorageClass': (basestring, False), + 'StorageClass': (str, False), } class ReplicationRuleAndOperator(AWSProperty): props = { - 'Prefix': (basestring, False), + 'Prefix': (str, False), 'TagFilters': ([TagFilter], False), } @@ -345,20 +345,20 @@ class ReplicationRuleAndOperator(AWSProperty): class ReplicationRuleFilter(AWSProperty): props = { 'And': (ReplicationRuleAndOperator, False), - 'Prefix': (basestring, False), + 'Prefix': (str, False), 'TagFilter': (TagFilter, False), } class ReplicaModifications(AWSProperty): props = { - 'Status': (basestring, True), + 'Status': (str, True), } class SseKmsEncryptedObjects(AWSProperty): props = { - 'Status': (basestring, True), + 'Status': (str, True), } @@ -374,34 +374,34 @@ class ReplicationConfigurationRules(AWSProperty): 'DeleteMarkerReplication': (DeleteMarkerReplication, False), 'Destination': (ReplicationConfigurationRulesDestination, True), 'Filter': (ReplicationRuleFilter, False), - 'Id': (basestring, False), - 'Prefix': (basestring, True), + 'Id': (str, False), + 'Prefix': (str, True), 'Priority': (integer, False), 'SourceSelectionCriteria': (SourceSelectionCriteria, False), - 'Status': (basestring, True) + 'Status': (str, True) } class ReplicationConfiguration(AWSProperty): props = { - 'Role': (basestring, True), + 'Role': (str, True), 'Rules': ([ReplicationConfigurationRules], True) } class Destination(AWSProperty): props = { - 'BucketAccountId': (basestring, False), - 'BucketArn': (basestring, True), - 'Format': (basestring, True), - 'Prefix': (basestring, False), + 'BucketAccountId': (str, False), + 'BucketArn': (str, True), + 'Format': (str, True), + 'Prefix': (str, False), } class DataExport(AWSProperty): props = { 'Destination': (Destination, True), - 'OutputSchemaVersion': (basestring, True), + 'OutputSchemaVersion': (str, True), } @@ -413,8 +413,8 @@ class StorageClassAnalysis(AWSProperty): class AnalyticsConfiguration(AWSProperty): props = { - 'Id': (basestring, True), - 'Prefix': (basestring, False), + 'Id': (str, True), + 'Prefix': (str, False), 'StorageClassAnalysis': (StorageClassAnalysis, True), 'TagFilters': ([TagFilter], False), } @@ -422,8 +422,8 @@ class AnalyticsConfiguration(AWSProperty): class ServerSideEncryptionByDefault(AWSProperty): props = { - 'KMSMasterKeyID': (basestring, False), - 'SSEAlgorithm': (basestring, True), + 'KMSMasterKeyID': (str, False), + 'SSEAlgorithm': (str, True), } @@ -446,18 +446,18 @@ class InventoryConfiguration(AWSProperty): props = { 'Destination': (Destination, True), 'Enabled': (boolean, True), - 'Id': (basestring, True), - 'IncludedObjectVersions': (basestring, True), - 'OptionalFields': ([basestring], True), - 'Prefix': (basestring, False), - 'ScheduleFrequency': (basestring, True), + 'Id': (str, True), + 'IncludedObjectVersions': (str, True), + 'OptionalFields': ([str], True), + 'Prefix': (str, False), + 'ScheduleFrequency': (str, True), } class DefaultRetention(AWSProperty): props = { 'Days': (integer, False), - 'Mode': (basestring, False), + 'Mode': (str, False), 'Years': (integer, False), } @@ -470,7 +470,7 @@ class ObjectLockRule(AWSProperty): class ObjectLockConfiguration(AWSProperty): props = { - 'ObjectLockEnabled': (basestring, False), + 'ObjectLockEnabled': (str, False), 'Rule': (ObjectLockRule, False), } @@ -480,7 +480,7 @@ class Bucket(AWSObject): props = { 'AccelerateConfiguration': (AccelerateConfiguration, False), - 'AccessControl': (basestring, False), + 'AccessControl': (str, False), 'AnalyticsConfigurations': ([AnalyticsConfiguration], False), 'BucketEncryption': (BucketEncryption, False), 'BucketName': (s3_bucket_name, False), @@ -524,7 +524,7 @@ class BucketPolicy(AWSObject): resource_type = "AWS::S3::BucketPolicy" props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'PolicyDocument': (policytypes, True), } @@ -537,7 +537,7 @@ class ActivityMetrics(AWSProperty): class SelectionCriteria(AWSProperty): props = { - 'Delimiter': (basestring, False), + 'Delimiter': (str, False), 'MaxDepth': (integer, False), 'MinStorageBytesPercentage': (double, False), } @@ -572,14 +572,14 @@ class AccountLevel(AWSProperty): class AwsOrg(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), } class BucketsAndRegions(AWSProperty): props = { - 'Buckets': ([basestring], False), - 'Regions': ([basestring], False), + 'Buckets': ([str], False), + 'Regions': ([str], False), } @@ -589,10 +589,10 @@ class StorageLensConfiguration(AWSProperty): 'AwsOrg': (AwsOrg, False), 'DataExport': (DataExport, False), 'Exclude': (BucketsAndRegions, False), - 'Id': (basestring, True), + 'Id': (str, True), 'Include': (BucketsAndRegions, False), 'IsEnabled': (boolean, True), - 'StorageLensArn': (basestring, False), + 'StorageLensArn': (str, False), } diff --git a/troposphere/s3objectlambda.py b/troposphere/s3objectlambda.py index 03e3e2f01..542fd6f9c 100644 --- a/troposphere/s3objectlambda.py +++ b/troposphere/s3objectlambda.py @@ -14,16 +14,16 @@ class TransformationConfiguration(AWSProperty): props = { - 'Actions': ([basestring], False), + 'Actions': ([str], False), 'ContentTransformation': (dict, False), } class ObjectLambdaConfiguration(AWSProperty): props = { - 'AllowedFeatures': ([basestring], False), + 'AllowedFeatures': ([str], False), 'CloudWatchMetricsEnabled': (boolean, False), - 'SupportingAccessPoint': (basestring, True), + 'SupportingAccessPoint': (str, True), 'TransformationConfigurations': ([TransformationConfiguration], True), } @@ -33,7 +33,7 @@ class AccessPoint(AWSObject): resource_type = "AWS::S3ObjectLambda::AccessPoint" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'ObjectLambdaConfiguration': (ObjectLambdaConfiguration, False), } @@ -42,6 +42,6 @@ class AccessPointPolicy(AWSObject): resource_type = "AWS::S3ObjectLambda::AccessPointPolicy" props = { - 'ObjectLambdaAccessPoint': (basestring, True), + 'ObjectLambdaAccessPoint': (str, True), 'PolicyDocument': (dict, True), } diff --git a/troposphere/s3outposts.py b/troposphere/s3outposts.py index 6770cd539..78a71d4ea 100644 --- a/troposphere/s3outposts.py +++ b/troposphere/s3outposts.py @@ -15,7 +15,7 @@ class VpcConfiguration(AWSProperty): props = { - 'VpcId': (basestring, False), + 'VpcId': (str, False), } @@ -23,8 +23,8 @@ class AccessPoint(AWSObject): resource_type = "AWS::S3Outposts::AccessPoint" props = { - 'Bucket': (basestring, True), - 'Name': (basestring, True), + 'Bucket': (str, True), + 'Name': (str, True), 'Policy': (dict, False), 'VpcConfiguration': (VpcConfiguration, True), } @@ -40,11 +40,11 @@ class Rule(AWSProperty): props = { 'AbortIncompleteMultipartUpload': (AbortIncompleteMultipartUpload, False), - 'ExpirationDate': (basestring, False), + 'ExpirationDate': (str, False), 'ExpirationInDays': (integer, False), 'Filter': (dict, False), - 'Id': (basestring, False), - 'Status': (basestring, False), + 'Id': (str, False), + 'Status': (str, False), } @@ -58,9 +58,9 @@ class Bucket(AWSObject): resource_type = "AWS::S3Outposts::Bucket" props = { - 'BucketName': (basestring, True), + 'BucketName': (str, True), 'LifecycleConfiguration': (LifecycleConfiguration, False), - 'OutpostId': (basestring, True), + 'OutpostId': (str, True), 'Tags': (Tags, False), } @@ -69,7 +69,7 @@ class BucketPolicy(AWSObject): resource_type = "AWS::S3Outposts::BucketPolicy" props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'PolicyDocument': (dict, True), } @@ -78,7 +78,7 @@ class Endpoint(AWSObject): resource_type = "AWS::S3Outposts::Endpoint" props = { - 'OutpostId': (basestring, True), - 'SecurityGroupId': (basestring, True), - 'SubnetId': (basestring, True), + 'OutpostId': (str, True), + 'SecurityGroupId': (str, True), + 'SubnetId': (str, True), } diff --git a/troposphere/sagemaker.py b/troposphere/sagemaker.py index a0ef71258..5e16d3c96 100644 --- a/troposphere/sagemaker.py +++ b/troposphere/sagemaker.py @@ -9,9 +9,9 @@ class ResourceSpec(AWSProperty): props = { - 'InstanceType': (basestring, False), - 'SageMakerImageArn': (basestring, False), - 'SageMakerImageVersionArn': (basestring, False), + 'InstanceType': (str, False), + 'SageMakerImageArn': (str, False), + 'SageMakerImageVersionArn': (str, False), } @@ -19,12 +19,12 @@ class App(AWSObject): resource_type = "AWS::SageMaker::App" props = { - 'AppName': (basestring, True), - 'AppType': (basestring, True), - 'DomainId': (basestring, True), + 'AppName': (str, True), + 'AppType': (str, True), + 'DomainId': (str, True), 'ResourceSpec': (ResourceSpec, False), 'Tags': (Tags, False), - 'UserProfileName': (basestring, True), + 'UserProfileName': (str, True), } @@ -32,14 +32,14 @@ class FileSystemConfig(AWSProperty): props = { 'DefaultGid': (integer, False), 'DefaultUid': (integer, False), - 'MountPath': (basestring, False), + 'MountPath': (str, False), } class KernelSpec(AWSProperty): props = { - 'DisplayName': (basestring, False), - 'Name': (basestring, True), + 'DisplayName': (str, False), + 'Name': (str, True), } @@ -54,7 +54,7 @@ class AppImageConfig(AWSObject): resource_type = "AWS::SageMaker::AppImageConfig" props = { - 'AppImageConfigName': (basestring, True), + 'AppImageConfigName': (str, True), 'KernelGatewayImageConfig': (KernelGatewayImageConfig, False), 'Tags': (Tags, False), } @@ -62,9 +62,9 @@ class AppImageConfig(AWSObject): class GitConfig(AWSProperty): props = { - 'Branch': (basestring, False), - 'RepositoryUrl': (basestring, True), - 'SecretArn': (basestring, False), + 'Branch': (str, False), + 'RepositoryUrl': (str, True), + 'SecretArn': (str, False), } @@ -72,37 +72,37 @@ class CodeRepository(AWSObject): resource_type = "AWS::SageMaker::CodeRepository" props = { - 'CodeRepositoryName': (basestring, False), + 'CodeRepositoryName': (str, False), 'GitConfig': (GitConfig, True), } class DataQualityAppSpecification(AWSProperty): props = { - 'ContainerArguments': ([basestring], False), - 'ContainerEntrypoint': ([basestring], False), + 'ContainerArguments': ([str], False), + 'ContainerEntrypoint': ([str], False), 'Environment': (dict, False), - 'ImageUri': (basestring, True), - 'PostAnalyticsProcessorSourceUri': (basestring, False), - 'RecordPreprocessorSourceUri': (basestring, False), + 'ImageUri': (str, True), + 'PostAnalyticsProcessorSourceUri': (str, False), + 'RecordPreprocessorSourceUri': (str, False), } class ConstraintsResource(AWSProperty): props = { - 'S3Uri': (basestring, False), + 'S3Uri': (str, False), } class StatisticsResource(AWSProperty): props = { - 'S3Uri': (basestring, False), + 'S3Uri': (str, False), } class DataQualityBaselineConfig(AWSProperty): props = { - 'BaseliningJobName': (basestring, False), + 'BaseliningJobName': (str, False), 'ConstraintsResource': (ConstraintsResource, False), 'StatisticsResource': (StatisticsResource, False), } @@ -110,10 +110,10 @@ class DataQualityBaselineConfig(AWSProperty): class EndpointInput(AWSProperty): props = { - 'EndpointName': (basestring, True), - 'LocalPath': (basestring, True), - 'S3DataDistributionType': (basestring, False), - 'S3InputMode': (basestring, False), + 'EndpointName': (str, True), + 'LocalPath': (str, True), + 'S3DataDistributionType': (str, False), + 'S3InputMode': (str, False), } @@ -125,9 +125,9 @@ class DataQualityJobInput(AWSProperty): class S3Output(AWSProperty): props = { - 'LocalPath': (basestring, True), - 'S3UploadMode': (basestring, False), - 'S3Uri': (basestring, True), + 'LocalPath': (str, True), + 'S3UploadMode': (str, False), + 'S3Uri': (str, True), } @@ -139,7 +139,7 @@ class MonitoringOutput(AWSProperty): class MonitoringOutputConfig(AWSProperty): props = { - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), 'MonitoringOutputs': ([MonitoringOutput], True), } @@ -147,8 +147,8 @@ class MonitoringOutputConfig(AWSProperty): class ClusterConfig(AWSProperty): props = { 'InstanceCount': (integer, True), - 'InstanceType': (basestring, True), - 'VolumeKmsKeyId': (basestring, False), + 'InstanceType': (str, True), + 'VolumeKmsKeyId': (str, False), 'VolumeSizeInGB': (integer, True), } @@ -161,8 +161,8 @@ class MonitoringResources(AWSProperty): class VpcConfig(AWSProperty): props = { - 'Subnets': ([basestring], True), - 'SecurityGroupIds': ([basestring], True), + 'Subnets': ([str], True), + 'SecurityGroupIds': ([str], True), } @@ -188,10 +188,10 @@ class DataQualityJobDefinition(AWSObject): 'DataQualityBaselineConfig': (DataQualityBaselineConfig, False), 'DataQualityJobInput': (DataQualityJobInput, True), 'DataQualityJobOutputConfig': (MonitoringOutputConfig, True), - 'JobDefinitionName': (basestring, False), + 'JobDefinitionName': (str, False), 'JobResources': (MonitoringResources, True), 'NetworkConfig': (NetworkConfig, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'StoppingCondition': (StoppingCondition, False), 'Tags': (Tags, False), } @@ -202,15 +202,15 @@ class Device(AWSObject): props = { 'Device': (dict, False), - 'DeviceFleetName': (basestring, True), + 'DeviceFleetName': (str, True), 'Tags': (Tags, False), } class EdgeOutputConfig(AWSProperty): props = { - 'KmsKeyId': (basestring, False), - 'S3OutputLocation': (basestring, True), + 'KmsKeyId': (str, False), + 'S3OutputLocation': (str, True), } @@ -218,10 +218,10 @@ class DeviceFleet(AWSObject): resource_type = "AWS::SageMaker::DeviceFleet" props = { - 'Description': (basestring, False), - 'DeviceFleetName': (basestring, True), + 'Description': (str, False), + 'DeviceFleetName': (str, True), 'OutputConfig': (EdgeOutputConfig, True), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), } @@ -234,8 +234,8 @@ class JupyterServerAppSettings(AWSProperty): class CustomImage(AWSProperty): props = { - 'AppImageConfigName': (basestring, True), - 'ImageName': (basestring, True), + 'AppImageConfigName': (str, True), + 'ImageName': (str, True), 'ImageVersionNumber': (integer, False), } @@ -249,18 +249,18 @@ class KernelGatewayAppSettings(AWSProperty): class SharingSettings(AWSProperty): props = { - 'NotebookOutputOption': (basestring, False), - 'S3KmsKeyId': (basestring, False), - 'S3OutputPath': (basestring, False), + 'NotebookOutputOption': (str, False), + 'S3KmsKeyId': (str, False), + 'S3OutputPath': (str, False), } class UserSettings(AWSProperty): props = { - 'ExecutionRole': (basestring, False), + 'ExecutionRole': (str, False), 'JupyterServerAppSettings': (JupyterServerAppSettings, False), 'KernelGatewayAppSettings': (KernelGatewayAppSettings, False), - 'SecurityGroups': ([basestring], False), + 'SecurityGroups': ([str], False), 'SharingSettings': (SharingSettings, False), } @@ -269,20 +269,20 @@ class Domain(AWSObject): resource_type = "AWS::SageMaker::Domain" props = { - 'AppNetworkAccessType': (basestring, False), - 'AuthMode': (basestring, True), + 'AppNetworkAccessType': (str, False), + 'AuthMode': (str, True), 'DefaultUserSettings': (UserSettings, True), - 'DomainName': (basestring, True), - 'KmsKeyId': (basestring, False), - 'SubnetIds': ([basestring], True), + 'DomainName': (str, True), + 'KmsKeyId': (str, False), + 'SubnetIds': ([str], True), 'Tags': (Tags, False), - 'VpcId': (basestring, True), + 'VpcId': (str, True), } class Alarm(AWSProperty): props = { - 'AlarmName': (basestring, True), + 'AlarmName': (str, True), } @@ -294,7 +294,7 @@ class AutoRollbackConfig(AWSProperty): class CapacitySize(AWSProperty): props = { - 'Type': (basestring, True), + 'Type': (str, True), 'Value': (integer, True), } @@ -302,7 +302,7 @@ class CapacitySize(AWSProperty): class TrafficRoutingConfig(AWSProperty): props = { 'CanarySize': (CapacitySize, False), - 'Type': (basestring, True), + 'Type': (str, True), 'WaitIntervalInSeconds': (integer, False), } @@ -324,7 +324,7 @@ class DeploymentConfig(AWSProperty): class VariantProperty(AWSProperty): props = { - 'VariantPropertyType': (basestring, False), + 'VariantPropertyType': (str, False), } @@ -333,8 +333,8 @@ class Endpoint(AWSObject): props = { 'DeploymentConfig': (DeploymentConfig, False), - 'EndpointConfigName': (basestring, True), - 'EndpointName': (basestring, False), + 'EndpointConfigName': (str, True), + 'EndpointName': (str, False), 'ExcludeRetainedVariantProperties': ([VariantProperty], False), 'RetainAllVariantProperties': (boolean, False), 'Tags': (Tags, False), @@ -343,14 +343,14 @@ class Endpoint(AWSObject): class CaptureContentTypeHeader(AWSProperty): props = { - 'CsvContentTypes': ([basestring], False), - 'JsonContentTypes': ([basestring], False), + 'CsvContentTypes': ([str], False), + 'JsonContentTypes': ([str], False), } class CaptureOption(AWSProperty): props = { - 'CaptureMode': (basestring, True), + 'CaptureMode': (str, True), } @@ -358,19 +358,19 @@ class DataCaptureConfig(AWSProperty): props = { 'CaptureContentTypeHeader': (CaptureContentTypeHeader, False), 'CaptureOptions': ([CaptureOption], True), - 'DestinationS3Uri': (basestring, True), + 'DestinationS3Uri': (str, True), 'EnableCapture': (boolean, False), 'InitialSamplingPercentage': (integer, True), - 'KmsKeyId': (basestring, False), + 'KmsKeyId': (str, False), } class ProductionVariant(AWSProperty): props = { - 'ModelName': (basestring, True), - 'VariantName': (basestring, True), + 'ModelName': (str, True), + 'VariantName': (str, True), 'InitialInstanceCount': (integer, True), - 'InstanceType': (basestring, True), + 'InstanceType': (str, True), 'InitialVariantWeight': (float, True) } @@ -380,8 +380,8 @@ class EndpointConfig(AWSObject): props = { 'DataCaptureConfig': (DataCaptureConfig, False), - 'EndpointConfigName': (basestring, False), - 'KmsKeyId': (basestring, False), + 'EndpointConfigName': (str, False), + 'KmsKeyId': (str, False), 'ProductionVariants': ([ProductionVariant], True), 'Tags': (Tags, False), } @@ -389,8 +389,8 @@ class EndpointConfig(AWSObject): class FeatureDefinition(AWSProperty): props = { - 'FeatureName': (basestring, True), - 'FeatureType': (basestring, True), + 'FeatureName': (str, True), + 'FeatureType': (str, True), } @@ -398,14 +398,14 @@ class FeatureGroup(AWSObject): resource_type = "AWS::SageMaker::FeatureGroup" props = { - 'Description': (basestring, False), - 'EventTimeFeatureName': (basestring, True), + 'Description': (str, False), + 'EventTimeFeatureName': (str, True), 'FeatureDefinitions': ([FeatureDefinition], True), - 'FeatureGroupName': (basestring, True), + 'FeatureGroupName': (str, True), 'OfflineStoreConfig': (dict, False), 'OnlineStoreConfig': (dict, False), - 'RecordIdentifierFeatureName': (basestring, True), - 'RoleArn': (basestring, False), + 'RecordIdentifierFeatureName': (str, True), + 'RoleArn': (str, False), 'Tags': (Tags, False), } @@ -414,10 +414,10 @@ class Image(AWSObject): resource_type = "AWS::SageMaker::Image" props = { - 'ImageDescription': (basestring, False), - 'ImageDisplayName': (basestring, False), - 'ImageName': (basestring, True), - 'ImageRoleArn': (basestring, True), + 'ImageDescription': (str, False), + 'ImageDisplayName': (str, False), + 'ImageName': (str, True), + 'ImageRoleArn': (str, True), 'Tags': (Tags, False), } @@ -426,39 +426,39 @@ class ImageVersion(AWSObject): resource_type = "AWS::SageMaker::ImageVersion" props = { - 'BaseImage': (basestring, True), - 'ImageName': (basestring, True), + 'BaseImage': (str, True), + 'ImageName': (str, True), } class ImageConfig(AWSProperty): props = { - 'RepositoryAccessMode': (basestring, True), + 'RepositoryAccessMode': (str, True), } class MultiModelConfig(AWSProperty): props = { - 'ModelCacheSetting': (basestring, False), + 'ModelCacheSetting': (str, False), } class ContainerDefinition(AWSProperty): props = { - 'ContainerHostname': (basestring, False), + 'ContainerHostname': (str, False), 'Environment': (dict, False), - 'Image': (basestring, False), + 'Image': (str, False), 'ImageConfig': (ImageConfig, False), - 'Mode': (basestring, False), - 'ModelDataUrl': (basestring, False), - 'ModelPackageName': (basestring, False), + 'Mode': (str, False), + 'ModelDataUrl': (str, False), + 'ModelPackageName': (str, False), 'MultiModelConfig': (MultiModelConfig, False), } class InferenceExecutionConfig(AWSProperty): props = { - 'Mode': (basestring, True), + 'Mode': (str, True), } @@ -468,9 +468,9 @@ class Model(AWSObject): props = { 'Containers': ([ContainerDefinition], False), 'EnableNetworkIsolation': (boolean, False), - 'ExecutionRoleArn': (basestring, True), + 'ExecutionRoleArn': (str, True), 'InferenceExecutionConfig': (InferenceExecutionConfig, False), - 'ModelName': (basestring, False), + 'ModelName': (str, False), 'PrimaryContainer': (ContainerDefinition, False), 'Tags': (Tags, False), 'VpcConfig': (VpcConfig, False), @@ -479,22 +479,22 @@ class Model(AWSObject): class ModelBiasAppSpecification(AWSProperty): props = { - 'ConfigUri': (basestring, True), + 'ConfigUri': (str, True), 'Environment': (dict, False), - 'ImageUri': (basestring, True), + 'ImageUri': (str, True), } class ModelBiasBaselineConfig(AWSProperty): props = { - 'BaseliningJobName': (basestring, False), + 'BaseliningJobName': (str, False), 'ConstraintsResource': (ConstraintsResource, False), } class MonitoringGroundTruthS3Input(AWSProperty): props = { - 'S3Uri': (basestring, True), + 'S3Uri': (str, True), } @@ -509,14 +509,14 @@ class ModelBiasJobDefinition(AWSObject): resource_type = "AWS::SageMaker::ModelBiasJobDefinition" props = { - 'JobDefinitionName': (basestring, False), + 'JobDefinitionName': (str, False), 'JobResources': (MonitoringResources, True), 'ModelBiasAppSpecification': (ModelBiasAppSpecification, True), 'ModelBiasBaselineConfig': (ModelBiasBaselineConfig, False), 'ModelBiasJobInput': (ModelBiasJobInput, True), 'ModelBiasJobOutputConfig': (MonitoringOutputConfig, True), 'NetworkConfig': (NetworkConfig, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'StoppingCondition': (StoppingCondition, False), 'Tags': (Tags, False), } @@ -524,15 +524,15 @@ class ModelBiasJobDefinition(AWSObject): class ModelExplainabilityAppSpecification(AWSProperty): props = { - 'ConfigUri': (basestring, True), + 'ConfigUri': (str, True), 'Environment': (dict, False), - 'ImageUri': (basestring, True), + 'ImageUri': (str, True), } class ModelExplainabilityBaselineConfig(AWSProperty): props = { - 'BaseliningJobName': (basestring, False), + 'BaseliningJobName': (str, False), 'ConstraintsResource': (ConstraintsResource, False), } @@ -547,7 +547,7 @@ class ModelExplainabilityJobDefinition(AWSObject): resource_type = "AWS::SageMaker::ModelExplainabilityJobDefinition" props = { - 'JobDefinitionName': (basestring, False), + 'JobDefinitionName': (str, False), 'JobResources': (MonitoringResources, True), 'ModelExplainabilityAppSpecification': (ModelExplainabilityAppSpecification, True), @@ -557,7 +557,7 @@ class ModelExplainabilityJobDefinition(AWSObject): 'ModelExplainabilityJobOutputConfig': (MonitoringOutputConfig, True), 'NetworkConfig': (NetworkConfig, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'StoppingCondition': (StoppingCondition, False), 'Tags': (Tags, False), } @@ -567,8 +567,8 @@ class ModelPackageGroup(AWSObject): resource_type = "AWS::SageMaker::ModelPackageGroup" props = { - 'ModelPackageGroupDescription': (basestring, False), - 'ModelPackageGroupName': (basestring, True), + 'ModelPackageGroupDescription': (str, False), + 'ModelPackageGroupName': (str, True), 'ModelPackageGroupPolicy': (dict, False), 'Tags': (Tags, False), } @@ -576,19 +576,19 @@ class ModelPackageGroup(AWSObject): class ModelQualityAppSpecification(AWSProperty): props = { - 'ContainerArguments': ([basestring], False), - 'ContainerEntrypoint': ([basestring], False), + 'ContainerArguments': ([str], False), + 'ContainerEntrypoint': ([str], False), 'Environment': (dict, False), - 'ImageUri': (basestring, True), - 'PostAnalyticsProcessorSourceUri': (basestring, False), - 'ProblemType': (basestring, True), - 'RecordPreprocessorSourceUri': (basestring, False), + 'ImageUri': (str, True), + 'PostAnalyticsProcessorSourceUri': (str, False), + 'ProblemType': (str, True), + 'RecordPreprocessorSourceUri': (str, False), } class ModelQualityBaselineConfig(AWSProperty): props = { - 'BaseliningJobName': (basestring, False), + 'BaseliningJobName': (str, False), 'ConstraintsResource': (ConstraintsResource, False), } @@ -604,7 +604,7 @@ class ModelQualityJobDefinition(AWSObject): resource_type = "AWS::SageMaker::ModelQualityJobDefinition" props = { - 'JobDefinitionName': (basestring, False), + 'JobDefinitionName': (str, False), 'JobResources': (MonitoringResources, True), 'ModelQualityAppSpecification': (ModelQualityAppSpecification, True), @@ -612,7 +612,7 @@ class ModelQualityJobDefinition(AWSObject): 'ModelQualityJobInput': (ModelQualityJobInput, True), 'ModelQualityJobOutputConfig': (MonitoringOutputConfig, True), 'NetworkConfig': (NetworkConfig, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'StoppingCondition': (StoppingCondition, False), 'Tags': (Tags, False), } @@ -620,14 +620,14 @@ class ModelQualityJobDefinition(AWSObject): class MonitoringExecutionSummary(AWSProperty): props = { - 'CreationTime': (basestring, True), - 'EndpointName': (basestring, False), - 'FailureReason': (basestring, False), - 'LastModifiedTime': (basestring, True), - 'MonitoringExecutionStatus': (basestring, True), - 'MonitoringScheduleName': (basestring, True), - 'ProcessingJobArn': (basestring, False), - 'ScheduledTime': (basestring, True), + 'CreationTime': (str, True), + 'EndpointName': (str, False), + 'FailureReason': (str, False), + 'LastModifiedTime': (str, True), + 'MonitoringExecutionStatus': (str, True), + 'MonitoringScheduleName': (str, True), + 'ProcessingJobArn': (str, False), + 'ScheduledTime': (str, True), } @@ -640,11 +640,11 @@ class BaselineConfig(AWSProperty): class MonitoringAppSpecification(AWSProperty): props = { - 'ContainerArguments': ([basestring], False), - 'ContainerEntrypoint': ([basestring], False), - 'ImageUri': (basestring, True), - 'PostAnalyticsProcessorSourceUri': (basestring, False), - 'RecordPreprocessorSourceUri': (basestring, False), + 'ContainerArguments': ([str], False), + 'ContainerEntrypoint': ([str], False), + 'ImageUri': (str, True), + 'PostAnalyticsProcessorSourceUri': (str, False), + 'RecordPreprocessorSourceUri': (str, False), } @@ -669,14 +669,14 @@ class MonitoringJobDefinition(AWSProperty): 'MonitoringOutputConfig': (MonitoringOutputConfig, True), 'MonitoringResources': (MonitoringResources, True), 'NetworkConfig': (NetworkConfig, False), - 'RoleArn': (basestring, True), + 'RoleArn': (str, True), 'StoppingCondition': (StoppingCondition, False), } class ScheduleConfig(AWSProperty): props = { - 'ScheduleExpression': (basestring, True), + 'ScheduleExpression': (str, True), } @@ -691,16 +691,16 @@ class MonitoringSchedule(AWSObject): resource_type = "AWS::SageMaker::MonitoringSchedule" props = { - 'CreationTime': (basestring, False), - 'EndpointName': (basestring, False), - 'FailureReason': (basestring, False), - 'LastModifiedTime': (basestring, False), + 'CreationTime': (str, False), + 'EndpointName': (str, False), + 'FailureReason': (str, False), + 'LastModifiedTime': (str, False), 'LastMonitoringExecutionSummary': (MonitoringExecutionSummary, False), - 'MonitoringScheduleArn': (basestring, False), + 'MonitoringScheduleArn': (str, False), 'MonitoringScheduleConfig': (MonitoringScheduleConfig, True), - 'MonitoringScheduleName': (basestring, True), - 'MonitoringScheduleStatus': (basestring, False), + 'MonitoringScheduleName': (str, True), + 'MonitoringScheduleStatus': (str, False), 'Tags': (Tags, False), } @@ -709,18 +709,18 @@ class NotebookInstance(AWSObject): resource_type = "AWS::SageMaker::NotebookInstance" props = { - 'AcceleratorTypes': ([basestring], False), - 'AdditionalCodeRepositories': ([basestring], False), - 'DefaultCodeRepository': (basestring, False), - 'DirectInternetAccess': (basestring, False), - 'InstanceType': (basestring, True), - 'KmsKeyId': (basestring, False), - 'LifecycleConfigName': (basestring, False), - 'NotebookInstanceName': (basestring, False), - 'RoleArn': (basestring, True), - 'RootAccess': (basestring, False), - 'SecurityGroupIds': ([basestring], False), - 'SubnetId': (basestring, False), + 'AcceleratorTypes': ([str], False), + 'AdditionalCodeRepositories': ([str], False), + 'DefaultCodeRepository': (str, False), + 'DirectInternetAccess': (str, False), + 'InstanceType': (str, True), + 'KmsKeyId': (str, False), + 'LifecycleConfigName': (str, False), + 'NotebookInstanceName': (str, False), + 'RoleArn': (str, True), + 'RootAccess': (str, False), + 'SecurityGroupIds': ([str], False), + 'SubnetId': (str, False), 'Tags': (Tags, False), 'VolumeSizeInGB': (integer, False), } @@ -728,7 +728,7 @@ class NotebookInstance(AWSObject): class NotebookInstanceLifecycleHook(AWSProperty): props = { - 'Content': (basestring, False), + 'Content': (str, False), } @@ -736,7 +736,7 @@ class NotebookInstanceLifecycleConfig(AWSObject): resource_type = "AWS::SageMaker::NotebookInstanceLifecycleConfig" props = { - 'NotebookInstanceLifecycleConfigName': (basestring, False), + 'NotebookInstanceLifecycleConfigName': (str, False), 'OnCreate': ([NotebookInstanceLifecycleHook], False), 'OnStart': ([NotebookInstanceLifecycleHook], False), } @@ -747,10 +747,10 @@ class Pipeline(AWSObject): props = { 'PipelineDefinition': (dict, True), - 'PipelineDescription': (basestring, False), - 'PipelineDisplayName': (basestring, False), - 'PipelineName': (basestring, True), - 'RoleArn': (basestring, True), + 'PipelineDescription': (str, False), + 'PipelineDisplayName': (str, False), + 'PipelineName': (str, True), + 'RoleArn': (str, True), 'Tags': (Tags, False), } @@ -759,8 +759,8 @@ class Project(AWSObject): resource_type = "AWS::SageMaker::Project" props = { - 'ProjectDescription': (basestring, False), - 'ProjectName': (basestring, True), + 'ProjectDescription': (str, False), + 'ProjectName': (str, True), 'ServiceCatalogProvisioningDetails': (dict, True), 'Tags': (Tags, False), } @@ -770,20 +770,20 @@ class UserProfile(AWSObject): resource_type = "AWS::SageMaker::UserProfile" props = { - 'DomainId': (basestring, True), - 'SingleSignOnUserIdentifier': (basestring, False), - 'SingleSignOnUserValue': (basestring, False), + 'DomainId': (str, True), + 'SingleSignOnUserIdentifier': (str, False), + 'SingleSignOnUserValue': (str, False), 'Tags': (Tags, False), - 'UserProfileName': (basestring, True), + 'UserProfileName': (str, True), 'UserSettings': (UserSettings, False), } class CognitoMemberDefinition(AWSProperty): props = { - 'CognitoClientId': (basestring, True), - 'CognitoUserGroup': (basestring, True), - 'CognitoUserPool': (basestring, True), + 'CognitoClientId': (str, True), + 'CognitoUserGroup': (str, True), + 'CognitoUserPool': (str, True), } @@ -795,7 +795,7 @@ class MemberDefinition(AWSProperty): class NotificationConfiguration(AWSProperty): props = { - 'NotificationTopicArn': (basestring, True), + 'NotificationTopicArn': (str, True), } @@ -803,9 +803,9 @@ class Workteam(AWSObject): resource_type = "AWS::SageMaker::Workteam" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'MemberDefinitions': ([MemberDefinition], False), 'NotificationConfiguration': (NotificationConfiguration, False), 'Tags': (Tags, False), - 'WorkteamName': (basestring, False), + 'WorkteamName': (str, False), } diff --git a/troposphere/secretsmanager.py b/troposphere/secretsmanager.py index b7a137a3a..00970065f 100644 --- a/troposphere/secretsmanager.py +++ b/troposphere/secretsmanager.py @@ -26,20 +26,20 @@ class ResourcePolicy(AWSObject): props = { 'BlockPublicPolicy': (boolean, False), - 'SecretId': (basestring, True), + 'SecretId': (str, True), 'ResourcePolicy': (policytypes, True), } class HostedRotationLambda(AWSProperty): props = { - 'KmsKeyArn': (basestring, False), - 'MasterSecretArn': (basestring, False), - 'MasterSecretKmsKeyArn': (basestring, False), - 'RotationLambdaName': (basestring, False), - 'RotationType': (basestring, True), - 'VpcSecurityGroupIds': (basestring, False), - 'VpcSubnetIds': (basestring, False), + 'KmsKeyArn': (str, False), + 'MasterSecretArn': (str, False), + 'MasterSecretKmsKeyArn': (str, False), + 'RotationLambdaName': (str, False), + 'RotationType': (str, True), + 'VpcSecurityGroupIds': (str, False), + 'VpcSubnetIds': (str, False), } @@ -54,31 +54,31 @@ class RotationSchedule(AWSObject): props = { 'HostedRotationLambda': (HostedRotationLambda, False), - 'RotationLambdaARN': (basestring, False), + 'RotationLambdaARN': (str, False), 'RotationRules': (RotationRules, False), - 'SecretId': (basestring, True), + 'SecretId': (str, True), } class GenerateSecretString(AWSProperty): props = { - 'ExcludeCharacters': (basestring, False), + 'ExcludeCharacters': (str, False), 'ExcludeLowercase': (boolean, False), 'ExcludeNumbers': (boolean, False), 'ExcludePunctuation': (boolean, False), 'ExcludeUppercase': (boolean, False), - 'GenerateStringKey': (basestring, False), + 'GenerateStringKey': (str, False), 'IncludeSpace': (boolean, False), 'PasswordLength': (integer, False), 'RequireEachIncludedType': (boolean, False), - 'SecretStringTemplate': (basestring, False), + 'SecretStringTemplate': (str, False), } class ReplicaRegion(AWSProperty): props = { - 'KmsKeyId': (basestring, False), - 'Region': (basestring, True), + 'KmsKeyId': (str, False), + 'Region': (str, True), } @@ -86,12 +86,12 @@ class Secret(AWSObject): resource_type = "AWS::SecretsManager::Secret" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'GenerateSecretString': (GenerateSecretString, False), - 'KmsKeyId': (basestring, False), - 'Name': (basestring, False), + 'KmsKeyId': (str, False), + 'Name': (str, False), 'ReplicaRegions': ([ReplicaRegion], False), - 'SecretString': (basestring, False), + 'SecretString': (str, False), 'Tags': ((Tags, list), False), } @@ -100,7 +100,7 @@ class SecretTargetAttachment(AWSObject): resource_type = "AWS::SecretsManager::SecretTargetAttachment" props = { - 'SecretId': (basestring, True), - 'TargetId': (basestring, True), + 'SecretId': (str, True), + 'TargetId': (str, True), 'TargetType': (validate_target_types, True), } diff --git a/troposphere/serverless.py b/troposphere/serverless.py index 40ba2d5be..5ab0750f1 100644 --- a/troposphere/serverless.py +++ b/troposphere/serverless.py @@ -21,9 +21,9 @@ try: from awacs.aws import PolicyDocument - policytypes = (dict, list, basestring, PolicyDocument) + policytypes = (dict, list, str, PolicyDocument) except ImportError: - policytypes = (dict, list, basestring) + policytypes = (dict, list, str) assert types # silence pyflakes @@ -37,8 +37,8 @@ def primary_key_type_validator(x): class DeadLetterQueue(AWSProperty): props = { - 'Type': (basestring, False), - 'TargetArn': (basestring, False) + 'Type': (str, False), + 'TargetArn': (str, False) } def validate(self): @@ -50,26 +50,26 @@ def validate(self): class S3Location(AWSProperty): props = { - "Bucket": (basestring, True), - "Key": (basestring, True), - "Version": (basestring, False), + "Bucket": (str, True), + "Key": (str, True), + "Version": (str, False), } class Hooks(AWSProperty): props = { - "PreTraffic": (basestring, False), - "PostTraffic": (basestring, False), + "PreTraffic": (str, False), + "PostTraffic": (str, False), } class DeploymentPreference(AWSProperty): props = { - "Type": (basestring, True), + "Type": (str, True), "Alarms": (list, False), "Hooks": (Hooks, False), "Enabled": (bool, False), - "Role": (basestring, False), + "Role": (str, False), } @@ -77,26 +77,26 @@ class Function(AWSObject): resource_type = "AWS::Serverless::Function" props = { - 'Handler': (basestring, True), - 'Runtime': (basestring, True), - 'CodeUri': ((S3Location, basestring), False), - 'InlineCode': (basestring, False), - 'FunctionName': (basestring, False), - 'Description': (basestring, False), + 'Handler': (str, True), + 'Runtime': (str, True), + 'CodeUri': ((S3Location, str), False), + 'InlineCode': (str, False), + 'FunctionName': (str, False), + 'Description': (str, False), 'MemorySize': (validate_memory_size, False), 'Timeout': (positive_integer, False), - 'Role': (basestring, False), + 'Role': (str, False), 'Policies': (policytypes, False), 'Environment': (Environment, False), 'VpcConfig': (VPCConfig, False), 'Events': (dict, False), 'Tags': (dict, False), - 'Tracing': (basestring, False), - 'KmsKeyArn': (basestring, False), + 'Tracing': (str, False), + 'KmsKeyArn': (str, False), 'DeadLetterQueue': (DeadLetterQueue, False), 'DeploymentPreference': (DeploymentPreference, False), - 'Layers': ([basestring], False), - 'AutoPublishAlias': (basestring, False), + 'Layers': ([str], False), + 'AutoPublishAlias': (str, False), 'ReservedConcurrentExecutions': (positive_integer, False), 'ProvisionedConcurrencyConfig': (ProvisionedConcurrencyConfiguration, False), @@ -127,57 +127,57 @@ def validate(self): class CognitoAuthIdentity(AWSProperty): props = { - 'Header': (basestring, False), - 'ValidationExpression': (basestring, False), + 'Header': (str, False), + 'ValidationExpression': (str, False), } class LambdaTokenAuthIdentity(AWSProperty): props = { - 'Header': (basestring, False), - 'ValidationExpression': (basestring, False), - 'ReauthorizeEvery': (basestring, False), + 'Header': (str, False), + 'ValidationExpression': (str, False), + 'ReauthorizeEvery': (str, False), } class LambdaRequestAuthIdentity(AWSProperty): props = { - 'Headers': ([basestring], False), - 'QueryStrings': ([basestring], False), - 'StageVariables': ([basestring], False), - 'Context': ([basestring], False), - 'ReauthorizeEvery': (basestring, False), + 'Headers': ([str], False), + 'QueryStrings': ([str], False), + 'StageVariables': ([str], False), + 'Context': ([str], False), + 'ReauthorizeEvery': (str, False), } class CognitoAuth(AWSProperty): props = { - 'UserPoolArn': (basestring, False), + 'UserPoolArn': (str, False), 'Identity': (CognitoAuthIdentity, False), } class LambdaTokenAuth(AWSProperty): props = { - 'FunctionPayloadType': (basestring, False), - 'FunctionArn': (basestring, False), - 'FunctionInvokeRole': (basestring, False), + 'FunctionPayloadType': (str, False), + 'FunctionArn': (str, False), + 'FunctionInvokeRole': (str, False), 'Identity': (LambdaTokenAuthIdentity, False), } class LambdaRequestAuth(AWSProperty): props = { - 'FunctionPayloadType': (basestring, False), - 'FunctionArn': (basestring, False), - 'FunctionInvokeRole': (basestring, False), + 'FunctionPayloadType': (str, False), + 'FunctionArn': (str, False), + 'FunctionInvokeRole': (str, False), 'Identity': (LambdaRequestAuthIdentity, False), } class Authorizers(AWSProperty): props = { - 'DefaultAuthorizer': (basestring, False), + 'DefaultAuthorizer': (str, False), 'CognitoAuth': (CognitoAuth, False), 'LambdaTokenAuth': (LambdaTokenAuth, False), 'LambdaRequestAuth': (LambdaRequestAuth, False), @@ -201,28 +201,28 @@ class Auth(AWSProperty): 'AddDefaultAuthorizerToCorsPreflight': (bool, False), 'ApiKeyRequired': (bool, False), 'Authorizers': (Authorizers, False), - 'DefaultAuthorizer': (basestring, False), - 'InvokeRole': (basestring, False), + 'DefaultAuthorizer': (str, False), + 'InvokeRole': (str, False), 'ResourcePolicy': (ResourcePolicyStatement, False), } class Cors(AWSProperty): props = { - 'AllowCredentials': (basestring, False), - 'AllowHeaders': (basestring, False), - 'AllowMethods': (basestring, False), - 'AllowOrigin': (basestring, True), - 'MaxAge': (basestring, False), + 'AllowCredentials': (str, False), + 'AllowHeaders': (str, False), + 'AllowMethods': (str, False), + 'AllowOrigin': (str, True), + 'MaxAge': (str, False), } class Route53(AWSProperty): props = { - 'DistributionDomainName': (basestring, False), + 'DistributionDomainName': (str, False), 'EvaluateTargetHealth': (bool, False), - 'HostedZoneId': (basestring, False), - 'HostedZoneName': (basestring, False), + 'HostedZoneId': (str, False), + 'HostedZoneName': (str, False), 'IpV6': (bool, False), } @@ -237,9 +237,9 @@ def validate(self): class Domain(AWSProperty): props = { 'BasePath': (list, False), - 'CertificateArn': (basestring, True), - 'DomainName': (basestring, True), - 'EndpointConfiguration': (basestring, False), + 'CertificateArn': (str, True), + 'DomainName': (str, True), + 'EndpointConfiguration': (str, False), 'Route53': (Route53, False), } @@ -254,7 +254,7 @@ def validate(self): class EndpointConfiguration(AWSProperty): props = { - "Type": (basestring, False), + "Type": (str, False), "VPCEndpointIds": (list, False) } @@ -276,19 +276,19 @@ class Api(AWSObject): props = { 'AccessLogSetting': (AccessLogSetting, False), 'Auth': (Auth, False), - 'BinaryMediaTypes': ([basestring], False), + 'BinaryMediaTypes': ([str], False), 'CacheClusterEnabled': (bool, False), - 'CacheClusterSize': (basestring, False), + 'CacheClusterSize': (str, False), 'CanarySetting': (CanarySetting, False), - 'Cors': ((basestring, Cors), False), + 'Cors': ((str, Cors), False), 'DefinitionBody': (dict, False), - 'DefinitionUri': (basestring, False), + 'DefinitionUri': (str, False), 'Domain': (Domain, False), 'EndpointConfiguration': (EndpointConfiguration, False), 'MethodSettings': ([MethodSetting], False), - 'Name': (basestring, False), - 'OpenApiVersion': (basestring, False), - 'StageName': (basestring, True), + 'Name': (str, False), + 'OpenApiVersion': (str, False), + 'StageName': (str, True), "TracingEnabled": (bool, False), 'Variables': (dict, False), } @@ -303,7 +303,7 @@ def validate(self): class PrimaryKey(AWSProperty): props = { - 'Name': (basestring, False), + 'Name': (str, False), 'Type': (primary_key_type_validator, False) } @@ -316,7 +316,7 @@ class SimpleTable(AWSObject): 'ProvisionedThroughput': (ProvisionedThroughput, False), 'SSESpecification': (SSESpecification, False), 'Tags': (dict, False), - 'TableName': (basestring, False), + 'TableName': (str, False), } @@ -324,12 +324,12 @@ class LayerVersion(AWSObject): resource_type = "AWS::Serverless::LayerVersion" props = { - 'CompatibleRuntimes': ([basestring], False), - 'ContentUri': ((S3Location, basestring), True), - 'Description': (basestring, False), - 'LayerName': (basestring, False), - 'LicenseInfo': (basestring, False), - 'RetentionPolicy': (basestring, False), + 'CompatibleRuntimes': ([str], False), + 'ContentUri': ((S3Location, str), True), + 'Description': (str, False), + 'LayerName': (str, False), + 'LicenseInfo': (str, False), + 'RetentionPolicy': (str, False), } @@ -337,7 +337,7 @@ class S3Event(AWSObject): resource_type = 'S3' props = { - 'Bucket': (basestring, True), + 'Bucket': (str, True), 'Events': (list, True), 'Filter': (Filter, False) } @@ -347,7 +347,7 @@ class SNSEvent(AWSObject): resource_type = 'SNS' props = { - 'Topic': (basestring, True) + 'Topic': (str, True) } @@ -365,7 +365,7 @@ class KinesisEvent(AWSObject): resource_type = 'Kinesis' props = { - 'Stream': (basestring, True), + 'Stream': (str, True), 'StartingPosition': (starting_position_validator, True), 'BatchSize': (positive_integer, False), 'BisectBatchOnFunctionError': (bool, False), @@ -382,7 +382,7 @@ class DynamoDBEvent(AWSObject): resource_type = 'DynamoDB' props = { - 'Stream': (basestring, True), + 'Stream': (str, True), 'StartingPosition': (starting_position_validator, True), 'BatchSize': (positive_integer, False) } @@ -390,7 +390,7 @@ class DynamoDBEvent(AWSObject): class RequestModel(AWSProperty): props = { - 'Model': (basestring, True), + 'Model': (str, True), 'Required': (bool, False) } @@ -400,11 +400,11 @@ class ApiEvent(AWSObject): props = { 'Auth': (Auth, False), - 'Path': (basestring, True), - 'Method': (basestring, True), + 'Path': (str, True), + 'Method': (str, True), 'RequestModel': (RequestModel, False), - 'RequestParameters': (basestring, False), - 'RestApiId': (basestring, False) + 'RequestParameters': (str, False), + 'RestApiId': (str, False) } @@ -412,11 +412,11 @@ class ScheduleEvent(AWSObject): resource_type = 'Schedule' props = { - 'Schedule': (basestring, True), - 'Input': (basestring, False), - 'Description': (basestring, False), + 'Schedule': (str, True), + 'Input': (str, False), + 'Description': (str, False), 'Enabled': (bool, False), - 'Name': (basestring, False) + 'Name': (str, False) } @@ -425,8 +425,8 @@ class CloudWatchEvent(AWSObject): props = { 'Pattern': (dict, True), - 'Input': (basestring, False), - 'InputPath': (basestring, False) + 'Input': (str, False), + 'InputPath': (str, False) } @@ -434,8 +434,8 @@ class IoTRuleEvent(AWSObject): resource_type = 'IoTRule' props = { - 'Sql': (basestring, True), - 'AwsIotSqlVersion': (basestring, False) + 'Sql': (str, True), + 'AwsIotSqlVersion': (str, False) } @@ -448,7 +448,7 @@ class SQSEvent(AWSObject): resource_type = 'SQS' props = { - 'Queue': (basestring, True), + 'Queue': (str, True), 'BatchSize': (positive_integer, True) } @@ -459,8 +459,8 @@ def validate(self): class ApplicationLocation(AWSProperty): props = { - "ApplicationId": (basestring, True), - "SemanticVersion": (basestring, True), + "ApplicationId": (str, True), + "SemanticVersion": (str, True), } @@ -468,8 +468,8 @@ class Application(AWSObject): resource_type = "AWS::Serverless::Application" props = { - 'Location': ((ApplicationLocation, basestring), True), - 'NotificationARNs': ([basestring], False), + 'Location': ((ApplicationLocation, str), True), + 'NotificationARNs': ([str], False), 'Parameters': (dict, False), 'Tags': (dict, False), 'TimeoutInMinutes': (positive_integer, False), diff --git a/troposphere/servicecatalog.py b/troposphere/servicecatalog.py index 8eb000fc7..7f7788f62 100644 --- a/troposphere/servicecatalog.py +++ b/troposphere/servicecatalog.py @@ -11,17 +11,17 @@ class AcceptedPortfolioShare(AWSObject): resource_type = "AWS::ServiceCatalog::AcceptedPortfolioShare" props = { - 'AcceptLanguage': (basestring, False), - 'PortfolioId': (basestring, True), + 'AcceptLanguage': (str, False), + 'PortfolioId': (str, True), } class ProvisioningArtifactProperties(AWSProperty): props = { - 'Description': (basestring, False), + 'Description': (str, False), 'DisableTemplateValidation': (boolean, False), 'Info': (dict, True), - 'Name': (basestring, False), + 'Name': (str, False), } @@ -29,37 +29,37 @@ class CloudFormationProduct(AWSObject): resource_type = "AWS::ServiceCatalog::CloudFormationProduct" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'Distributor': (basestring, False), - 'Name': (basestring, True), - 'Owner': (basestring, True), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'Distributor': (str, False), + 'Name': (str, True), + 'Owner': (str, True), 'ProvisioningArtifactParameters': ([ProvisioningArtifactProperties], True), 'ReplaceProvisioningArtifacts': (boolean, False), - 'SupportDescription': (basestring, False), - 'SupportEmail': (basestring, False), - 'SupportUrl': (basestring, False), + 'SupportDescription': (str, False), + 'SupportEmail': (str, False), + 'SupportUrl': (str, False), 'Tags': (Tags, False), } class ProvisioningParameter(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } class ProvisioningPreferences(AWSProperty): props = { - 'StackSetAccounts': ([basestring], False), + 'StackSetAccounts': ([str], False), 'StackSetFailureToleranceCount': (integer, False), 'StackSetFailureTolerancePercentage': (integer, False), 'StackSetMaxConcurrencyCount': (integer, False), 'StackSetMaxConcurrencyPercentage': (integer, False), - 'StackSetOperationType': (basestring, False), - 'StackSetRegions': ([basestring], False), + 'StackSetOperationType': (str, False), + 'StackSetRegions': ([str], False), } @@ -67,15 +67,15 @@ class CloudFormationProvisionedProduct(AWSObject): resource_type = "AWS::ServiceCatalog::CloudFormationProvisionedProduct" props = { - 'AcceptLanguage': (basestring, False), - 'NotificationArns': ([basestring], False), - 'PathId': (basestring, False), - 'PathName': (basestring, False), - 'ProductId': (basestring, False), - 'ProductName': (basestring, False), - 'ProvisionedProductName': (basestring, False), - 'ProvisioningArtifactId': (basestring, False), - 'ProvisioningArtifactName': (basestring, False), + 'AcceptLanguage': (str, False), + 'NotificationArns': ([str], False), + 'PathId': (str, False), + 'PathName': (str, False), + 'ProductId': (str, False), + 'ProductName': (str, False), + 'ProvisionedProductName': (str, False), + 'ProvisioningArtifactId': (str, False), + 'ProvisioningArtifactName': (str, False), 'ProvisioningParameters': ([ProvisioningParameter], False), 'ProvisioningPreferences': (ProvisioningPreferences, False), 'Tags': (Tags, False), @@ -86,11 +86,11 @@ class LaunchNotificationConstraint(AWSObject): resource_type = "AWS::ServiceCatalog::LaunchNotificationConstraint" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'NotificationArns': ([basestring], True), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'NotificationArns': ([str], True), + 'PortfolioId': (str, True), + 'ProductId': (str, True), } @@ -98,12 +98,12 @@ class LaunchRoleConstraint(AWSObject): resource_type = "AWS::ServiceCatalog::LaunchRoleConstraint" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'LocalRoleName': (basestring, False), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), - 'RoleArn': (basestring, False), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'LocalRoleName': (str, False), + 'PortfolioId': (str, True), + 'ProductId': (str, True), + 'RoleArn': (str, False), } @@ -111,11 +111,11 @@ class LaunchTemplateConstraint(AWSObject): resource_type = "AWS::ServiceCatalog::LaunchTemplateConstraint" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), - 'Rules': (basestring, True), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'PortfolioId': (str, True), + 'ProductId': (str, True), + 'Rules': (str, True), } @@ -123,10 +123,10 @@ class Portfolio(AWSObject): resource_type = "AWS::ServiceCatalog::Portfolio" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'DisplayName': (basestring, True), - 'ProviderName': (basestring, True), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'DisplayName': (str, True), + 'ProviderName': (str, True), 'Tags': (Tags, False), } @@ -135,10 +135,10 @@ class PortfolioPrincipalAssociation(AWSObject): resource_type = "AWS::ServiceCatalog::PortfolioPrincipalAssociation" props = { - 'AcceptLanguage': (basestring, False), - 'PortfolioId': (basestring, True), - 'PrincipalARN': (basestring, True), - 'PrincipalType': (basestring, True), + 'AcceptLanguage': (str, False), + 'PortfolioId': (str, True), + 'PrincipalARN': (str, True), + 'PrincipalType': (str, True), } @@ -146,10 +146,10 @@ class PortfolioProductAssociation(AWSObject): resource_type = "AWS::ServiceCatalog::PortfolioProductAssociation" props = { - 'AcceptLanguage': (basestring, False), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), - 'SourcePortfolioId': (basestring, False), + 'AcceptLanguage': (str, False), + 'PortfolioId': (str, True), + 'ProductId': (str, True), + 'SourcePortfolioId': (str, False), } @@ -157,9 +157,9 @@ class PortfolioShare(AWSObject): resource_type = "AWS::ServiceCatalog::PortfolioShare" props = { - 'AcceptLanguage': (basestring, False), - 'AccountId': (basestring, True), - 'PortfolioId': (basestring, True), + 'AcceptLanguage': (str, False), + 'AccountId': (str, True), + 'PortfolioId': (str, True), 'ShareTagOptions': (boolean, False), } @@ -180,18 +180,18 @@ class ResourceUpdateConstraint(AWSObject): resource_type = "AWS::ServiceCatalog::ResourceUpdateConstraint" props = { - 'AcceptLanguage': (basestring, False), - 'Description': (basestring, False), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), + 'AcceptLanguage': (str, False), + 'Description': (str, False), + 'PortfolioId': (str, True), + 'ProductId': (str, True), 'TagUpdateOnProvisionedProduct': (validate_tag_update, True), } class DefinitionParameter(AWSProperty): props = { - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -199,11 +199,11 @@ class ServiceAction(AWSObject): resource_type = "AWS::ServiceCatalog::ServiceAction" props = { - 'AcceptLanguage': (basestring, False), + 'AcceptLanguage': (str, False), 'Definition': ([DefinitionParameter], True), - 'DefinitionType': (basestring, True), - 'Description': (basestring, False), - 'Name': (basestring, True), + 'DefinitionType': (str, True), + 'Description': (str, False), + 'Name': (str, True), } @@ -211,9 +211,9 @@ class ServiceActionAssociation(AWSObject): resource_type = "AWS::ServiceCatalog::ServiceActionAssociation" props = { - 'ProductId': (basestring, True), - 'ProvisioningArtifactId': (basestring, True), - 'ServiceActionId': (basestring, True), + 'ProductId': (str, True), + 'ProvisioningArtifactId': (str, True), + 'ServiceActionId': (str, True), } @@ -221,15 +221,15 @@ class StackSetConstraint(AWSObject): resource_type = "AWS::ServiceCatalog::StackSetConstraint" props = { - 'AcceptLanguage': (basestring, False), - 'AccountList': ([basestring], True), - 'AdminRole': (basestring, True), - 'Description': (basestring, True), - 'ExecutionRole': (basestring, True), - 'PortfolioId': (basestring, True), - 'ProductId': (basestring, True), - 'RegionList': ([basestring], True), - 'StackInstanceControl': (basestring, True), + 'AcceptLanguage': (str, False), + 'AccountList': ([str], True), + 'AdminRole': (str, True), + 'Description': (str, True), + 'ExecutionRole': (str, True), + 'PortfolioId': (str, True), + 'ProductId': (str, True), + 'RegionList': ([str], True), + 'StackInstanceControl': (str, True), } @@ -238,8 +238,8 @@ class TagOption(AWSObject): props = { 'Active': (boolean, False), - 'Key': (basestring, True), - 'Value': (basestring, True), + 'Key': (str, True), + 'Value': (str, True), } @@ -247,6 +247,6 @@ class TagOptionAssociation(AWSObject): resource_type = "AWS::ServiceCatalog::TagOptionAssociation" props = { - 'ResourceId': (basestring, True), - 'TagOptionId': (basestring, True), + 'ResourceId': (str, True), + 'TagOptionId': (str, True), } diff --git a/troposphere/servicecatalogappregistry.py b/troposphere/servicecatalogappregistry.py index bec4282c3..d0f2ac9a8 100644 --- a/troposphere/servicecatalogappregistry.py +++ b/troposphere/servicecatalogappregistry.py @@ -16,8 +16,8 @@ class Application(AWSObject): resource_type = "AWS::ServiceCatalogAppRegistry::Application" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -32,8 +32,8 @@ class AttributeGroup(AWSObject): props = { 'Attributes': (Attributes, True), - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -42,8 +42,8 @@ class AttributeGroupAssociation(AWSObject): resource_type = "AWS::ServiceCatalogAppRegistry::AttributeGroupAssociation" props = { - 'Application': (basestring, True), - 'AttributeGroup': (basestring, True), + 'Application': (str, True), + 'AttributeGroup': (str, True), } @@ -51,7 +51,7 @@ class ResourceAssociation(AWSObject): resource_type = "AWS::ServiceCatalogAppRegistry::ResourceAssociation" props = { - 'Application': (basestring, True), - 'Resource': (basestring, True), - 'ResourceType': (basestring, True), + 'Application': (str, True), + 'Resource': (str, True), + 'ResourceType': (str, True), } diff --git a/troposphere/servicediscovery.py b/troposphere/servicediscovery.py index fd8279977..80293f9e2 100644 --- a/troposphere/servicediscovery.py +++ b/troposphere/servicediscovery.py @@ -11,8 +11,8 @@ class Instance(AWSObject): props = { 'InstanceAttributes': (dict, True), - 'InstanceId': (basestring, False), - 'ServiceId': (basestring, True), + 'InstanceId': (str, False), + 'ServiceId': (str, True), } @@ -20,10 +20,10 @@ class PrivateDnsNamespace(AWSObject): resource_type = "AWS::ServiceDiscovery::PrivateDnsNamespace" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), - 'Vpc': (basestring, True), + 'Vpc': (str, True), } @@ -31,8 +31,8 @@ class PublicDnsNamespace(AWSObject): resource_type = "AWS::ServiceDiscovery::PublicDnsNamespace" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } @@ -40,8 +40,8 @@ class PublicDnsNamespace(AWSObject): class HealthCheckConfig(AWSProperty): props = { 'FailureThreshold': (float, False), - 'ResourcePath': (basestring, False), - 'Type': (basestring, True), + 'ResourcePath': (str, False), + 'Type': (str, True), } @@ -53,16 +53,16 @@ class HealthCheckCustomConfig(AWSProperty): class DnsRecord(AWSProperty): props = { - 'TTL': (basestring, True), - 'Type': (basestring, True), + 'TTL': (str, True), + 'Type': (str, True), } class DnsConfig(AWSProperty): props = { 'DnsRecords': ([DnsRecord], True), - 'NamespaceId': (basestring, False), - 'RoutingPolicy': (basestring, False), + 'NamespaceId': (str, False), + 'RoutingPolicy': (str, False), } @@ -70,12 +70,12 @@ class Service(AWSObject): resource_type = "AWS::ServiceDiscovery::Service" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'DnsConfig': (DnsConfig, False), 'HealthCheckConfig': (HealthCheckConfig, False), 'HealthCheckCustomConfig': (HealthCheckCustomConfig, False), - 'Name': (basestring, False), - 'NamespaceId': (basestring, False), + 'Name': (str, False), + 'NamespaceId': (str, False), 'Tags': (Tags, False), } @@ -84,7 +84,7 @@ class HttpNamespace(AWSObject): resource_type = "AWS::ServiceDiscovery::HttpNamespace" props = { - 'Description': (basestring, False), - 'Name': (basestring, True), + 'Description': (str, False), + 'Name': (str, True), 'Tags': (Tags, False), } diff --git a/troposphere/ses.py b/troposphere/ses.py index 745046fd9..ef32ab7ff 100644 --- a/troposphere/ses.py +++ b/troposphere/ses.py @@ -9,9 +9,9 @@ class DimensionConfiguration(AWSProperty): props = { - 'DefaultDimensionValue': (basestring, True), - 'DimensionName': (basestring, True), - 'DimensionValueSource': (basestring, True), + 'DefaultDimensionValue': (str, True), + 'DimensionName': (str, True), + 'DimensionValueSource': (str, True), } @@ -23,8 +23,8 @@ class CloudWatchDestination(AWSProperty): class KinesisFirehoseDestination(AWSProperty): props = { - 'DeliveryStreamARN': (basestring, True), - 'IAMRoleARN': (basestring, True), + 'DeliveryStreamARN': (str, True), + 'IAMRoleARN': (str, True), } @@ -33,8 +33,8 @@ class EventDestination(AWSProperty): 'CloudWatchDestination': (CloudWatchDestination, False), 'Enabled': (boolean, False), 'KinesisFirehoseDestination': (KinesisFirehoseDestination, False), - 'MatchingEventTypes': ([basestring], True), - 'Name': (basestring, False), + 'MatchingEventTypes': ([str], True), + 'Name': (str, False), } @@ -42,7 +42,7 @@ class ConfigurationSetEventDestination(AWSObject): resource_type = "AWS::SES::ConfigurationSetEventDestination" props = { - 'ConfigurationSetName': (basestring, True), + 'ConfigurationSetName': (str, True), 'EventDestination': (EventDestination, True), } @@ -51,21 +51,21 @@ class ConfigurationSet(AWSObject): resource_type = "AWS::SES::ConfigurationSet" props = { - 'Name': (basestring, False), + 'Name': (str, False), } class IpFilter(AWSProperty): props = { - 'Cidr': (basestring, True), - 'Policy': (basestring, True), + 'Cidr': (str, True), + 'Policy': (str, True), } class Filter(AWSProperty): props = { 'IpFilter': (IpFilter, True), - 'Name': (basestring, False), + 'Name': (str, False), } @@ -81,62 +81,62 @@ class ReceiptRuleSet(AWSObject): resource_type = "AWS::SES::ReceiptRuleSet" props = { - 'RuleSetName': (basestring, False), + 'RuleSetName': (str, False), } class AddHeaderAction(AWSProperty): props = { - 'HeaderName': (basestring, True), - 'HeaderValue': (basestring, True), + 'HeaderName': (str, True), + 'HeaderValue': (str, True), } class BounceAction(AWSProperty): props = { - 'Message': (basestring, True), - 'Sender': (basestring, True), - 'SmtpReplyCode': (basestring, True), - 'StatusCode': (basestring, False), - 'TopicArn': (basestring, False), + 'Message': (str, True), + 'Sender': (str, True), + 'SmtpReplyCode': (str, True), + 'StatusCode': (str, False), + 'TopicArn': (str, False), } class LambdaAction(AWSProperty): props = { - 'FunctionArn': (basestring, True), - 'InvocationType': (basestring, False), - 'TopicArn': (basestring, False), + 'FunctionArn': (str, True), + 'InvocationType': (str, False), + 'TopicArn': (str, False), } class S3Action(AWSProperty): props = { - 'BucketName': (basestring, True), - 'KmsKeyArn': (basestring, False), - 'ObjectKeyPrefix': (basestring, False), - 'TopicArn': (basestring, False), + 'BucketName': (str, True), + 'KmsKeyArn': (str, False), + 'ObjectKeyPrefix': (str, False), + 'TopicArn': (str, False), } class SNSAction(AWSProperty): props = { - 'Encoding': (basestring, False), - 'TopicArn': (basestring, False), + 'Encoding': (str, False), + 'TopicArn': (str, False), } class StopAction(AWSProperty): props = { - 'Scope': (basestring, True), - 'TopicArn': (basestring, False), + 'Scope': (str, True), + 'TopicArn': (str, False), } class WorkmailAction(AWSProperty): props = { - 'OrganizationArn': (basestring, True), - 'TopicArn': (basestring, False), + 'OrganizationArn': (str, True), + 'TopicArn': (str, False), } @@ -156,10 +156,10 @@ class Rule(AWSProperty): props = { 'Actions': ([Action], False), 'Enabled': (boolean, False), - 'Name': (basestring, False), - 'Recipients': ([basestring], False), + 'Name': (str, False), + 'Recipients': ([str], False), 'ScanEnabled': (boolean, False), - 'TlsPolicy': (basestring, False), + 'TlsPolicy': (str, False), } @@ -167,18 +167,18 @@ class ReceiptRule(AWSObject): resource_type = "AWS::SES::ReceiptRule" props = { - 'After': (basestring, False), + 'After': (str, False), 'Rule': (Rule, True), - 'RuleSetName': (basestring, True), + 'RuleSetName': (str, True), } class EmailTemplate(AWSProperty): props = { - 'HtmlPart': (basestring, False), - 'SubjectPart': (basestring, False), - 'TemplateName': (basestring, False), - 'TextPart': (basestring, False), + 'HtmlPart': (str, False), + 'SubjectPart': (str, False), + 'TemplateName': (str, False), + 'TextPart': (str, False), } diff --git a/troposphere/sns.py b/troposphere/sns.py index 562f90bd8..64338fb2c 100644 --- a/troposphere/sns.py +++ b/troposphere/sns.py @@ -10,8 +10,8 @@ class Subscription(AWSProperty): props = { - 'Endpoint': (basestring, True), - 'Protocol': (basestring, True), + 'Endpoint': (str, True), + 'Protocol': (str, True), } @@ -20,13 +20,13 @@ class SubscriptionResource(AWSObject): props = { 'DeliveryPolicy': (dict, False), - 'Endpoint': (basestring, False), + 'Endpoint': (str, False), 'FilterPolicy': (dict, False), - 'Protocol': (basestring, True), + 'Protocol': (str, True), 'RawMessageDelivery': (boolean, False), 'RedrivePolicy': (dict, False), - 'Region': (basestring, False), - 'TopicArn': (basestring, True), + 'Region': (str, False), + 'TopicArn': (str, True), } @@ -44,10 +44,10 @@ class Topic(AWSObject): props = { 'ContentBasedDeduplication': (boolean, False), - 'DisplayName': (basestring, False), + 'DisplayName': (str, False), 'FifoTopic': (boolean, False), - 'KmsMasterKeyId': (basestring, False), + 'KmsMasterKeyId': (str, False), 'Subscription': ([Subscription], False), 'Tags': (Tags, False), - 'TopicName': (basestring, False), + 'TopicName': (str, False), } diff --git a/troposphere/sqs.py b/troposphere/sqs.py index fb396839d..0ac00b369 100644 --- a/troposphere/sqs.py +++ b/troposphere/sqs.py @@ -10,7 +10,7 @@ class RedrivePolicy(AWSProperty): props = { - 'deadLetterTargetArn': (basestring, False), + 'deadLetterTargetArn': (str, False), 'maxReceiveCount': (integer, False), } @@ -22,11 +22,11 @@ class Queue(AWSObject): 'ContentBasedDeduplication': (bool, False), 'DelaySeconds': (integer, False), 'FifoQueue': (bool, False), - 'KmsMasterKeyId': (basestring, False), + 'KmsMasterKeyId': (str, False), 'KmsDataKeyReusePeriodSeconds': (integer, False), 'MaximumMessageSize': (integer, False), 'MessageRetentionPeriod': (integer, False), - 'QueueName': (basestring, False), + 'QueueName': (str, False), 'ReceiveMessageWaitTimeSeconds': (integer, False), 'RedrivePolicy': (RedrivePolicy, False), 'Tags': (Tags, False), diff --git a/troposphere/ssm.py b/troposphere/ssm.py index 46adaa784..1254cc0b8 100644 --- a/troposphere/ssm.py +++ b/troposphere/ssm.py @@ -11,7 +11,7 @@ class NotificationConfig(AWSProperty): props = { - 'NotificationArn': (basestring, False), + 'NotificationArn': (str, False), 'NotificationEvents': (notification_event, False), 'NotificationType': (notification_type, False), } @@ -19,52 +19,52 @@ class NotificationConfig(AWSProperty): class LoggingInfo(AWSProperty): props = { - 'Region': (basestring, True), + 'Region': (str, True), 'S3Bucket': (s3_bucket_name, True), - 'S3Prefix': (basestring, False), + 'S3Prefix': (str, False), } class MaintenanceWindowAutomationParameters(AWSProperty): props = { - 'DocumentVersion': (basestring, False), + 'DocumentVersion': (str, False), 'Parameters': (dict, False), } class MaintenanceWindowLambdaParameters(AWSProperty): props = { - 'ClientContext': (basestring, False), + 'ClientContext': (str, False), 'Payload': (json_checker, False), - 'Qualifier': (basestring, False), + 'Qualifier': (str, False), } class MaintenanceWindowRunCommandParameters(AWSProperty): props = { - 'Comment': (basestring, False), - 'DocumentHash': (basestring, False), - 'DocumentHashType': (basestring, False), + 'Comment': (str, False), + 'DocumentHash': (str, False), + 'DocumentHashType': (str, False), 'NotificationConfig': (NotificationConfig, False), 'OutputS3BucketName': (s3_bucket_name, False), - 'OutputS3KeyPrefix': (basestring, False), + 'OutputS3KeyPrefix': (str, False), 'Parameters': (dict, False), - 'ServiceRoleArn': (basestring, False), + 'ServiceRoleArn': (str, False), 'TimeoutSeconds': (integer, False), } class MaintenanceWindowStepFunctionsParameters(AWSProperty): props = { - 'Input': (basestring, False), - 'Name': (basestring, False), + 'Input': (str, False), + 'Name': (str, False), } class PatchFilter(AWSProperty): props = { - 'Key': (basestring, True), - 'Values': ([basestring], True), + 'Key': (str, True), + 'Values': ([str], True), } @@ -104,15 +104,15 @@ class TaskInvocationParameters(AWSProperty): class Targets(AWSProperty): props = { - 'Key': (basestring, True), - 'Values': ([basestring], True), + 'Key': (str, True), + 'Values': ([str], True), } class S3OutputLocation(AWSProperty): props = { - 'OutputS3BucketName': (basestring, False), - 'OutputS3KeyPrefix': (basestring, False), + 'OutputS3BucketName': (str, False), + 'OutputS3KeyPrefix': (str, False), } @@ -126,13 +126,13 @@ class Association(AWSObject): resource_type = "AWS::SSM::Association" props = { - 'AssociationName': (basestring, False), - 'DocumentVersion': (basestring, False), - 'InstanceId': (basestring, False), - 'Name': (basestring, True), + 'AssociationName': (str, False), + 'DocumentVersion': (str, False), + 'InstanceId': (str, False), + 'Name': (str, True), 'OutputLocation': (InstanceAssociationOutputLocation, False), 'Parameters': (dict, False), - 'ScheduleExpression': (basestring, False), + 'ScheduleExpression': (str, False), 'Targets': ([Targets], False), 'WaitForSuccessTimeoutSeconds': (integer, False), } @@ -144,8 +144,8 @@ class Document(AWSObject): props = { # Need a better implementation of the SSM Document 'Content': (dict, True), - 'DocumentType': (basestring, False), - 'Name': (basestring, False), + 'DocumentType': (str, False), + 'Name': (str, False), 'Tags': (Tags, False), } @@ -156,13 +156,13 @@ class MaintenanceWindow(AWSObject): props = { 'AllowUnassociatedTargets': (boolean, True), 'Cutoff': (integer, True), - 'Description': (basestring, False), + 'Description': (str, False), 'Duration': (integer, True), - 'EndDate': (basestring, False), - 'Name': (basestring, True), - 'Schedule': (basestring, True), - 'ScheduleTimezone': (basestring, False), - 'StartDate': (basestring, False), + 'EndDate': (str, False), + 'Name': (str, True), + 'Schedule': (str, True), + 'ScheduleTimezone': (str, False), + 'StartDate': (str, False), 'Tags': (Tags, False), } @@ -171,12 +171,12 @@ class MaintenanceWindowTarget(AWSObject): resource_type = "AWS::SSM::MaintenanceWindowTarget" props = { - 'Description': (basestring, False), - 'Name': (basestring, False), - 'OwnerInformation': (basestring, False), - 'ResourceType': (basestring, True), + 'Description': (str, False), + 'Name': (str, False), + 'OwnerInformation': (str, False), + 'ResourceType': (str, True), 'Targets': ([Targets], True), - 'WindowId': (basestring, True), + 'WindowId': (str, True), } @@ -184,19 +184,19 @@ class MaintenanceWindowTask(AWSObject): resource_type = "AWS::SSM::MaintenanceWindowTask" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'LoggingInfo': (LoggingInfo, False), - 'MaxConcurrency': (basestring, False), - 'MaxErrors': (basestring, True), - 'Name': (basestring, False), + 'MaxConcurrency': (str, False), + 'MaxErrors': (str, True), + 'Name': (str, False), 'Priority': (integer, True), - 'ServiceRoleArn': (basestring, True), + 'ServiceRoleArn': (str, True), 'Targets': ([Targets], True), - 'TaskArn': (basestring, True), + 'TaskArn': (str, True), 'TaskInvocationParameters': (TaskInvocationParameters, False), 'TaskParameters': (dict, False), 'TaskType': (task_type, True), - 'WindowId': (basestring, False), + 'WindowId': (str, False), } @@ -204,23 +204,23 @@ class Parameter(AWSObject): resource_type = "AWS::SSM::Parameter" props = { - 'AllowedPattern': (basestring, False), - 'DataType': (basestring, False), - 'Description': (basestring, False), - 'Name': (basestring, False), - 'Policies': (basestring, False), + 'AllowedPattern': (str, False), + 'DataType': (str, False), + 'Description': (str, False), + 'Name': (str, False), + 'Policies': (str, False), 'Tags': (dict, False), - 'Tier': (basestring, False), - 'Type': (basestring, True), - 'Value': (basestring, True), + 'Tier': (str, False), + 'Type': (str, True), + 'Value': (str, True), } class PatchSource(AWSProperty): props = { - 'Configuration': (basestring, False), - 'Name': (basestring, False), - 'Products': ([basestring], False), + 'Configuration': (str, False), + 'Name': (str, False), + 'Products': ([str], False), } @@ -229,16 +229,16 @@ class PatchBaseline(AWSObject): props = { 'ApprovalRules': (RuleGroup, False), - 'ApprovedPatches': ([basestring], False), + 'ApprovedPatches': ([str], False), 'ApprovedPatchesComplianceLevel': (compliance_level, False), 'ApprovedPatchesEnableNonSecurity': (boolean, False), - 'Description': (basestring, False), + 'Description': (str, False), 'GlobalFilters': (PatchFilterGroup, False), - 'Name': (basestring, True), + 'Name': (str, True), 'OperatingSystem': (operating_system, False), - 'PatchGroups': ([basestring], False), - 'RejectedPatches': ([basestring], False), - 'RejectedPatchesAction': (basestring, False), + 'PatchGroups': ([str], False), + 'RejectedPatches': ([str], False), + 'RejectedPatchesAction': (str, False), 'Sources': ([PatchSource], False), 'Tags': (Tags, False), } @@ -246,8 +246,8 @@ class PatchBaseline(AWSObject): class AwsOrganizationsSource(AWSProperty): props = { - 'OrganizationalUnits': ([basestring], False), - 'OrganizationSourceType': (basestring, True), + 'OrganizationalUnits': ([str], False), + 'OrganizationSourceType': (str, True), } @@ -255,8 +255,8 @@ class SyncSource(AWSProperty): props = { 'AwsOrganizationsSource': (AwsOrganizationsSource, False), 'IncludeFutureRegions': (boolean, False), - 'SourceRegions': ([basestring], True), - 'SourceType': (basestring, True), + 'SourceRegions': ([str], True), + 'SourceType': (str, True), } @@ -265,12 +265,12 @@ class ResourceDataSync(AWSObject): resource_type = "AWS::SSM::ResourceDataSync" props = { - 'BucketName': (basestring, True), - 'BucketPrefix': (basestring, False), - 'BucketRegion': (basestring, True), - 'KMSKeyArn': (basestring, False), - 'SyncFormat': (basestring, True), - 'SyncName': (basestring, True), + 'BucketName': (str, True), + 'BucketPrefix': (str, False), + 'BucketRegion': (str, True), + 'KMSKeyArn': (str, False), + 'SyncFormat': (str, True), + 'SyncName': (str, True), 'SyncSource': (SyncSource, False), - 'SyncType': (basestring, False), + 'SyncType': (str, False), } diff --git a/troposphere/sso.py b/troposphere/sso.py index fa2cbab6d..fc3330b0c 100644 --- a/troposphere/sso.py +++ b/troposphere/sso.py @@ -16,18 +16,18 @@ class Assignment(AWSObject): resource_type = "AWS::SSO::Assignment" props = { - 'InstanceArn': (basestring, True), - 'PermissionSetArn': (basestring, True), - 'PrincipalId': (basestring, True), - 'PrincipalType': (basestring, True), - 'TargetId': (basestring, True), - 'TargetType': (basestring, True), + 'InstanceArn': (str, True), + 'PermissionSetArn': (str, True), + 'PrincipalId': (str, True), + 'PrincipalType': (str, True), + 'TargetId': (str, True), + 'TargetType': (str, True), } class AccessControlAttributeValueSourceList(AWSProperty): props = { - 'AccessControlAttributeValueSourceList': ([basestring], False), + 'AccessControlAttributeValueSourceList': ([str], False), } @@ -39,7 +39,7 @@ class AccessControlAttributeValue(AWSProperty): class AccessControlAttribute(AWSProperty): props = { - 'Key': (basestring, True), + 'Key': (str, True), 'Value': (AccessControlAttributeValue, True), } @@ -49,7 +49,7 @@ class InstanceAccessControlAttributeConfiguration(AWSObject): props = { 'AccessControlAttributes': ([AccessControlAttribute], False), - 'InstanceArn': (basestring, True), + 'InstanceArn': (str, True), } @@ -57,12 +57,12 @@ class PermissionSet(AWSObject): resource_type = "AWS::SSO::PermissionSet" props = { - 'Description': (basestring, False), + 'Description': (str, False), 'InlinePolicy': (dict, False), - 'InstanceArn': (basestring, True), - 'ManagedPolicies': ([basestring], False), - 'Name': (basestring, True), - 'RelayStateType': (basestring, False), - 'SessionDuration': (basestring, False), + 'InstanceArn': (str, True), + 'ManagedPolicies': ([str], False), + 'Name': (str, True), + 'RelayStateType': (str, False), + 'SessionDuration': (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/stepfunctions.py b/troposphere/stepfunctions.py index 29b231c44..69c4a78b1 100644 --- a/troposphere/stepfunctions.py +++ b/troposphere/stepfunctions.py @@ -17,14 +17,14 @@ class Activity(AWSObject): resource_type = "AWS::StepFunctions::Activity" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'Tags': (Tags, False), } class CloudWatchLogsLogGroup(AWSProperty): props = { - 'LogGroupArn': (basestring, False), + 'LogGroupArn': (str, False), } @@ -38,15 +38,15 @@ class LoggingConfiguration(AWSProperty): props = { 'Destinations': ([LogDestination], False), 'IncludeExecutionData': (boolean, False), - 'Level': (basestring, False), + 'Level': (str, False), } class S3Location(AWSProperty): props = { - 'Bucket': (basestring, True), - 'Key': (basestring, True), - 'Version': (basestring, False), + 'Bucket': (str, True), + 'Key': (str, True), + 'Version': (str, False), } @@ -62,12 +62,12 @@ class StateMachine(AWSObject): props = { 'Definition': (dict, False), 'DefinitionS3Location': (S3Location, False), - 'DefinitionString': (basestring, False), + 'DefinitionString': (str, False), 'DefinitionSubstitutions': (dict, False), 'LoggingConfiguration': (LoggingConfiguration, False), - 'RoleArn': (basestring, True), - 'StateMachineName': (basestring, False), - 'StateMachineType': (basestring, False), + 'RoleArn': (str, True), + 'StateMachineName': (str, False), + 'StateMachineType': (str, False), 'Tags': (Tags, False), 'TracingConfiguration': (TracingConfiguration, False), } diff --git a/troposphere/synthetics.py b/troposphere/synthetics.py index 57addc9f5..e4bc0b294 100644 --- a/troposphere/synthetics.py +++ b/troposphere/synthetics.py @@ -9,16 +9,16 @@ class VPCConfig(AWSProperty): props = { - 'SecurityGroupIds': ([basestring], True), - 'SubnetIds': ([basestring], True), - 'VpcId': (basestring, False), + 'SecurityGroupIds': ([str], True), + 'SubnetIds': ([str], True), + 'VpcId': (str, False), } class Schedule(AWSProperty): props = { - 'DurationInSeconds': (basestring, False), - 'Expression': (basestring, True), + 'DurationInSeconds': (str, False), + 'Expression': (str, True), } @@ -31,11 +31,11 @@ class RunConfig(AWSProperty): class Code(AWSProperty): props = { - 'Handler': (basestring, False), - 'S3Bucket': (basestring, False), - 'S3Key': (basestring, False), - 'S3ObjectVersion': (basestring, False), - 'Script': (basestring, False), + 'Handler': (str, False), + 'S3Bucket': (str, False), + 'S3Key': (str, False), + 'S3ObjectVersion': (str, False), + 'Script': (str, False), } @@ -43,11 +43,11 @@ class Canary(AWSObject): resource_type = "AWS::Synthetics::Canary" props = { - 'ArtifactS3Location': (basestring, True), + 'ArtifactS3Location': (str, True), 'Code': (Code, True), - 'ExecutionRoleArn': (basestring, True), + 'ExecutionRoleArn': (str, True), 'FailureRetentionPeriod': (integer, False), - 'Name': (basestring, True), + 'Name': (str, True), 'RunConfig': (RunConfig, False), 'RuntimeVersion': (canary_runtime_version, True), 'Schedule': (Schedule, True), diff --git a/troposphere/template_generator.py b/troposphere/template_generator.py index 6b1d68b58..f6582d001 100644 --- a/troposphere/template_generator.py +++ b/troposphere/template_generator.py @@ -60,18 +60,18 @@ def __init__(self, cf_template, **kwargs): self.set_description(cf_template['Description']) if 'Metadata' in cf_template: self.add_metadata(cf_template['Metadata']) - for k, v in cf_template.get('Parameters', {}).iteritems(): + for k, v in cf_template.get('Parameters', {}).items(): self.add_parameter(self._create_instance(Parameter, v, k)) - for k, v in cf_template.get('Mappings', {}).iteritems(): + for k, v in cf_template.get('Mappings', {}).items(): self.add_mapping(k, self._convert_definition(v)) - for k, v in cf_template.get('Conditions', {}).iteritems(): + for k, v in cf_template.get('Conditions', {}).items(): self.add_condition(k, self._convert_definition(v, k)) - for k, v in cf_template.get('Resources', {}).iteritems(): + for k, v in cf_template.get('Resources', {}).items(): self.add_resource(self._convert_definition( v, k, self._get_resource_type_cls(k, v) )) - for k, v in cf_template.get('Outputs', {}).iteritems(): + for k, v in cf_template.get('Outputs', {}).items(): self.add_output(self._create_instance(Output, v, k)) @property @@ -179,19 +179,19 @@ def _convert_definition(self, definition, ref=None, cls=None): if len(definition) == 1: # This might be a function? function_type = self._get_function_type( - definition.keys()[0]) + list(definition.keys())[0]) if function_type: return self._create_instance( - function_type, definition.values()[0]) + function_type, list(definition.values())[0]) # nothing special here - return as dict d = {} - for k, v in definition.iteritems(): + for k, v in definition.items(): d[k] = self._convert_definition(v) return d elif (isinstance(definition, Sequence) and - not isinstance(definition, basestring)): + not isinstance(definition, str)): return [self._convert_definition(v) for v in definition] # anything else is returned as-is @@ -216,7 +216,7 @@ def _create_instance(self, cls, args, ref=None): if isinstance(cls, Sequence): if len(cls) == 1: # a list of 1 type means we must provide a list of such objects - if (isinstance(args, basestring) or + if (isinstance(args, str) or not isinstance(args, Sequence)): args = [args] return [self._create_instance(cls[0], v) for v in args] @@ -240,7 +240,7 @@ def _create_instance(self, cls, args, ref=None): return cls(arg_dict) if (isinstance(args, Sequence) and - not isinstance(args, basestring)): + not isinstance(args, str)): return cls(*self._convert_definition(args)) if issubclass(cls, autoscaling.Metadata): diff --git a/troposphere/timestream.py b/troposphere/timestream.py index e92d6c3f2..e388f3c9a 100644 --- a/troposphere/timestream.py +++ b/troposphere/timestream.py @@ -15,8 +15,8 @@ class Database(AWSObject): resource_type = "AWS::Timestream::Database" props = { - 'DatabaseName': (basestring, False), - 'KmsKeyId': (basestring, False), + 'DatabaseName': (str, False), + 'KmsKeyId': (str, False), 'Tags': (Tags, False), } @@ -25,8 +25,8 @@ class Table(AWSObject): resource_type = "AWS::Timestream::Table" props = { - 'DatabaseName': (basestring, True), + 'DatabaseName': (str, True), 'RetentionProperties': (dict, False), - 'TableName': (basestring, False), + 'TableName': (str, False), 'Tags': (Tags, False), } diff --git a/troposphere/transfer.py b/troposphere/transfer.py index 41d530032..05143f6aa 100644 --- a/troposphere/transfer.py +++ b/troposphere/transfer.py @@ -26,18 +26,18 @@ def validate_homedirectory_type(homedirectory_type): class EndpointDetails(AWSProperty): props = { - 'AddressAllocationIds': ([basestring], False), - 'SecurityGroupIds': ([basestring], False), - 'SubnetIds': ([basestring], False), - 'VpcEndpointId': (basestring, False), - 'VpcId': (basestring, False), + 'AddressAllocationIds': ([str], False), + 'SecurityGroupIds': ([str], False), + 'SubnetIds': ([str], False), + 'VpcEndpointId': (str, False), + 'VpcId': (str, False), } class IdentityProviderDetails(AWSProperty): props = { - 'InvocationRole': (basestring, True), - 'Url': (basestring, True), + 'InvocationRole': (str, True), + 'Url': (str, True), } @@ -45,22 +45,22 @@ class Server(AWSObject): resource_type = "AWS::Transfer::Server" props = { - 'Certificate': (basestring, False), + 'Certificate': (str, False), 'EndpointDetails': (EndpointDetails, False), - 'EndpointType': (basestring, False), + 'EndpointType': (str, False), 'IdentityProviderDetails': (IdentityProviderDetails, False), - 'IdentityProviderType': (basestring, False), - 'LoggingRole': (basestring, False), - 'Protocols': ([basestring], False), - 'SecurityPolicyName': (basestring, False), + 'IdentityProviderType': (str, False), + 'LoggingRole': (str, False), + 'Protocols': ([str], False), + 'SecurityPolicyName': (str, False), 'Tags': (Tags, False), } class HomeDirectoryMapEntry(AWSProperty): props = { - 'Entry': (basestring, True), - 'Target': (basestring, True), + 'Entry': (str, True), + 'Target': (str, True), } @@ -68,13 +68,13 @@ class User(AWSObject): resource_type = "AWS::Transfer::User" props = { - 'HomeDirectory': (basestring, False), + 'HomeDirectory': (str, False), 'HomeDirectoryMappings': ([HomeDirectoryMapEntry], False), 'HomeDirectoryType': (validate_homedirectory_type, False), - 'Policy': (basestring, False), - 'Role': (basestring, True), - 'ServerId': (basestring, True), - 'SshPublicKeys': ([basestring], False), + 'Policy': (str, False), + 'Role': (str, True), + 'ServerId': (str, True), + 'SshPublicKeys': ([str], False), 'Tags': (Tags, False), - 'UserName': (basestring, True), + 'UserName': (str, True), } diff --git a/troposphere/utils.py b/troposphere/utils.py index 670a68022..c668e98a9 100644 --- a/troposphere/utils.py +++ b/troposphere/utils.py @@ -2,7 +2,7 @@ def _tail_print(e): - print("%s %s %s" % (e.resource_status, e.resource_type, e.event_id)) + print(("%s %s %s" % (e.resource_status, e.resource_type, e.event_id))) def get_events(conn, stackname): diff --git a/troposphere/validators.py b/troposphere/validators.py index 6c07e9584..3c42da54f 100644 --- a/troposphere/validators.py +++ b/troposphere/validators.py @@ -249,7 +249,7 @@ def check_required(class_name, properties, conditionals): def json_checker(prop): from . import AWSHelperFn - if isinstance(prop, basestring): + if isinstance(prop, str): # Verify it is a valid json string json.loads(prop) return prop diff --git a/troposphere/waf.py b/troposphere/waf.py index 7b137fdf7..124fac7b1 100644 --- a/troposphere/waf.py +++ b/troposphere/waf.py @@ -15,33 +15,33 @@ class Action(AWSProperty): class FieldToMatch(AWSProperty): props = { - 'Data': (basestring, False), # Conditional - 'Type': (basestring, True) + 'Data': (str, False), # Conditional + 'Type': (str, True) } class ByteMatchTuples(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'PositionalConstraint': (basestring, True), - 'TargetString': (basestring, False), # Conditional - 'TargetStringBase64': (basestring, False), # Conditional - 'TextTransformation': (basestring, True) + 'PositionalConstraint': (str, True), + 'TargetString': (str, False), # Conditional + 'TargetStringBase64': (str, False), # Conditional + 'TextTransformation': (str, True) } class IPSetDescriptors(AWSProperty): props = { - 'Type': (basestring, True), - 'Value': (basestring, True) + 'Type': (str, True), + 'Value': (str, True) } class Predicates(AWSProperty): props = { - 'DataId': (basestring, True), + 'DataId': (str, True), 'Negated': (boolean, True), - 'Type': (basestring, True) + 'Type': (str, True) } @@ -49,14 +49,14 @@ class Rules(AWSProperty): props = { 'Action': (Action, True), 'Priority': (integer, True), - 'RuleId': (basestring, True) + 'RuleId': (str, True) } class SqlInjectionMatchTuples(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'TextTransformation': (basestring, True) + 'TextTransformation': (str, True) } @@ -65,7 +65,7 @@ class ByteMatchSet(AWSObject): props = { 'ByteMatchTuples': ([ByteMatchTuples], False), - 'Name': (basestring, True) + 'Name': (str, True) } @@ -74,7 +74,7 @@ class IPSet(AWSObject): props = { 'IPSetDescriptors': ([IPSetDescriptors], False), - 'Name': (basestring, True) + 'Name': (str, True) } @@ -82,8 +82,8 @@ class Rule(AWSObject): resource_type = "AWS::WAF::Rule" props = { - 'MetricName': (basestring, True), - 'Name': (basestring, True), + 'MetricName': (str, True), + 'Name': (str, True), 'Predicates': ([Predicates], False) } @@ -92,7 +92,7 @@ class SqlInjectionMatchSet(AWSObject): resource_type = "AWS::WAF::SqlInjectionMatchSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'SqlInjectionMatchTuples': ([SqlInjectionMatchTuples], False) } @@ -102,18 +102,18 @@ class WebACL(AWSObject): props = { 'DefaultAction': (Action, True), - 'MetricName': (basestring, True), - 'Name': (basestring, True), + 'MetricName': (str, True), + 'Name': (str, True), 'Rules': ([Rules], False) } class SizeConstraint(AWSProperty): props = { - 'ComparisonOperator': (basestring, True), + 'ComparisonOperator': (str, True), 'FieldToMatch': (FieldToMatch, True), 'Size': (integer, True), - 'TextTransformation': (basestring, True), + 'TextTransformation': (str, True), } @@ -121,7 +121,7 @@ class SizeConstraintSet(AWSObject): resource_type = "AWS::WAF::SizeConstraintSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'SizeConstraints': ([SizeConstraint], False), } @@ -129,7 +129,7 @@ class SizeConstraintSet(AWSObject): class XssMatchTuple(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'TextTransformation': (basestring, True), + 'TextTransformation': (str, True), } @@ -137,6 +137,6 @@ class XssMatchSet(AWSObject): resource_type = "AWS::WAF::XssMatchSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'XssMatchTuples': ([XssMatchTuple], False), } diff --git a/troposphere/wafregional.py b/troposphere/wafregional.py index 8b6b1460b..d508f0baa 100644 --- a/troposphere/wafregional.py +++ b/troposphere/wafregional.py @@ -15,40 +15,40 @@ class Action(AWSProperty): class FieldToMatch(AWSProperty): props = { - 'Data': (basestring, False), # Conditional - 'Type': (basestring, True) + 'Data': (str, False), # Conditional + 'Type': (str, True) } class ByteMatchTuples(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'PositionalConstraint': (basestring, True), - 'TargetString': (basestring, False), # Conditional - 'TargetStringBase64': (basestring, False), # Conditional - 'TextTransformation': (basestring, True) + 'PositionalConstraint': (str, True), + 'TargetString': (str, False), # Conditional + 'TargetStringBase64': (str, False), # Conditional + 'TextTransformation': (str, True) } class IPSetDescriptors(AWSProperty): props = { - 'Type': (basestring, True), - 'Value': (basestring, True) + 'Type': (str, True), + 'Value': (str, True) } class Predicates(AWSProperty): props = { - 'DataId': (basestring, True), + 'DataId': (str, True), 'Negated': (boolean, True), - 'Type': (basestring, True) + 'Type': (str, True) } class GeoMatchConstraints(AWSProperty): props = { - 'Type': (basestring, True), - 'Value': (basestring, True) + 'Type': (str, True), + 'Value': (str, True) } @@ -56,14 +56,14 @@ class Rules(AWSProperty): props = { 'Action': (Action, True), 'Priority': (integer, True), - 'RuleId': (basestring, True) + 'RuleId': (str, True) } class SqlInjectionMatchTuples(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'TextTransformation': (basestring, True) + 'TextTransformation': (str, True) } @@ -72,7 +72,7 @@ class ByteMatchSet(AWSObject): props = { 'ByteMatchTuples': ([ByteMatchTuples], False), - 'Name': (basestring, True) + 'Name': (str, True) } @@ -81,7 +81,7 @@ class IPSet(AWSObject): props = { 'IPSetDescriptors': ([IPSetDescriptors], False), - 'Name': (basestring, True) + 'Name': (str, True) } @@ -89,8 +89,8 @@ class Rule(AWSObject): resource_type = "AWS::WAFRegional::Rule" props = { - 'MetricName': (basestring, True), - 'Name': (basestring, True), + 'MetricName': (str, True), + 'Name': (str, True), 'Predicates': ([Predicates], False) } @@ -99,7 +99,7 @@ class SqlInjectionMatchSet(AWSObject): resource_type = "AWS::WAFRegional::SqlInjectionMatchSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'SqlInjectionMatchTuples': ([SqlInjectionMatchTuples], False) } @@ -109,8 +109,8 @@ class WebACL(AWSObject): props = { 'DefaultAction': (Action, True), - 'MetricName': (basestring, True), - 'Name': (basestring, True), + 'MetricName': (str, True), + 'Name': (str, True), 'Rules': ([Rules], False) } @@ -119,17 +119,17 @@ class WebACLAssociation(AWSObject): resource_type = "AWS::WAFRegional::WebACLAssociation" props = { - 'ResourceArn': (basestring, True), - 'WebACLId': (basestring, True), + 'ResourceArn': (str, True), + 'WebACLId': (str, True), } class SizeConstraint(AWSProperty): props = { - 'ComparisonOperator': (basestring, True), + 'ComparisonOperator': (str, True), 'FieldToMatch': (FieldToMatch, True), 'Size': (integer, True), - 'TextTransformation': (basestring, True), + 'TextTransformation': (str, True), } @@ -137,7 +137,7 @@ class SizeConstraintSet(AWSObject): resource_type = "AWS::WAFRegional::SizeConstraintSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'SizeConstraints': ([SizeConstraint], False), } @@ -145,7 +145,7 @@ class SizeConstraintSet(AWSObject): class XssMatchTuple(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), - 'TextTransformation': (basestring, True), + 'TextTransformation': (str, True), } @@ -153,7 +153,7 @@ class XssMatchSet(AWSObject): resource_type = "AWS::WAFRegional::XssMatchSet" props = { - 'Name': (basestring, True), + 'Name': (str, True), 'XssMatchTuples': ([XssMatchTuple], False), } @@ -162,8 +162,8 @@ class RegexPatternSet(AWSObject): resource_type = "AWS::WAFRegional::RegexPatternSet" props = { - 'Name': (basestring, True), - 'RegexPatternStrings': ([basestring], True), + 'Name': (str, True), + 'RegexPatternStrings': ([str], True), } @@ -172,9 +172,9 @@ class RateBasedRule(AWSObject): props = { 'MatchPredicates': ([Predicates], False), - 'MetricName': (basestring, True), - 'Name': (basestring, True), - 'RateKey': (basestring, True), + 'MetricName': (str, True), + 'Name': (str, True), + 'RateKey': (str, True), 'RateLimit': (integer, True), } @@ -184,5 +184,5 @@ class GeoMatchSet(AWSObject): props = { 'GeoMatchConstraints': ([GeoMatchConstraints], False), - 'Name': (basestring, True), + 'Name': (str, True), } diff --git a/troposphere/wafv2.py b/troposphere/wafv2.py index 65eca6b67..1917d3511 100644 --- a/troposphere/wafv2.py +++ b/troposphere/wafv2.py @@ -54,13 +54,13 @@ def validate_positional_constraint(positional_constraint): class ExcludedRule(AWSProperty): props = { - 'Name': (basestring, False) + 'Name': (str, False) } class RuleGroupReferenceStatement(AWSProperty): props = { - 'Arn': (basestring, False), + 'Arn': (str, False), 'ExcludedRules': ([ExcludedRule], False) } @@ -74,13 +74,13 @@ class TextTransformation(AWSProperty): class SingleHeader(AWSProperty): props = { - 'Name': (basestring, False) + 'Name': (str, False) } class SingleQueryArgument(AWSProperty): props = { - 'Name': (basestring, False) + 'Name': (str, False) } @@ -128,7 +128,7 @@ class FieldToMatch(AWSProperty): class RegexPatternSetReferenceStatement(AWSProperty): props = { - 'Arn': (basestring, True), + 'Arn': (str, True), 'FieldToMatch': (FieldToMatch, True), 'TextTransformations': ([TextTransformation], True) } @@ -161,37 +161,37 @@ class ByteMatchStatement(AWSProperty): props = { 'FieldToMatch': (FieldToMatch, True), 'PositionalConstraint': (validate_positional_constraint, True), - 'SearchString': (basestring, True), - 'SearchStringBase64': (basestring, False), + 'SearchString': (str, True), + 'SearchStringBase64': (str, False), 'TextTransformations': ([TextTransformation], True) } class ForwardedIPConfiguration(AWSProperty): props = { - 'FallbackBehavior': (basestring, True), - 'HeaderName': (basestring, True), + 'FallbackBehavior': (str, True), + 'HeaderName': (str, True), } class GeoMatchStatement(AWSProperty): props = { - 'CountryCodes': ([basestring], False), + 'CountryCodes': ([str], False), 'ForwardedIPConfig': (ForwardedIPConfiguration, False), } class IPSetForwardedIPConfiguration(AWSProperty): props = { - 'FallbackBehavior': (basestring, True), - 'HeaderName': (basestring, True), - 'Position': (basestring, True), + 'FallbackBehavior': (str, True), + 'HeaderName': (str, True), + 'Position': (str, True), } class IPSetReferenceStatement(AWSProperty): props = { - 'Arn': (basestring, False), + 'Arn': (str, False), 'IPSetForwardedIPConfig': (IPSetForwardedIPConfiguration, False), } @@ -199,8 +199,8 @@ class IPSetReferenceStatement(AWSProperty): class ManagedRuleGroupStatement(AWSProperty): props = { 'ExcludedRules': ([ExcludedRule], False), - 'Name': (basestring, False), - 'VendorName': (basestring, False), + 'Name': (str, False), + 'VendorName': (str, False), } @@ -240,7 +240,7 @@ class OrStatementTwo(AWSProperty): class RateBasedStatementTwo(AWSProperty): props = { - 'AggregateKeyType': (basestring, False), + 'AggregateKeyType': (str, False), 'ForwardedIPConfig': (ForwardedIPConfiguration, False), 'Limit': (integer, False), 'ScopeDownStatement': StatementThree @@ -287,7 +287,7 @@ class OrStatementOne(AWSProperty): class RateBasedStatementOne(AWSProperty): props = { - 'AggregateKeyType': (basestring, False), + 'AggregateKeyType': (str, False), 'ForwardedIPConfig': (ForwardedIPConfiguration, False), 'Limit': (integer, False), 'ScopeDownStatement': (StatementTwo, False) @@ -317,7 +317,7 @@ class StatementOne(AWSProperty): class VisibilityConfig(AWSProperty): props = { 'CloudWatchMetricsEnabled': (boolean, False), - 'MetricName': (basestring, False), + 'MetricName': (str, False), 'SampledRequestsEnabled': (boolean, False) } @@ -364,7 +364,7 @@ class OverrideAction(AWSProperty): class WebACLRule(AWSProperty): props = { 'Action': (RuleAction, False), - 'Name': (basestring, False), + 'Name': (str, False), 'OverrideAction': (OverrideAction, False), 'Priority': (integer, False), 'Statement': (StatementOne, False), @@ -384,10 +384,10 @@ class WebACL(AWSObject): props = { 'DefaultAction': (DefaultAction, False), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), 'Rules': ([WebACLRule], False), - 'Scope': (basestring, True), + 'Scope': (str, True), 'Tags': (Tags, False), 'VisibilityConfig': (VisibilityConfig, False) } @@ -397,11 +397,11 @@ class IPSet(AWSObject): resource_type = "AWS::WAFv2::IPSet" props = { - 'Addresses': ([basestring], False), - 'Description': (basestring, False), + 'Addresses': ([str], False), + 'Description': (str, False), 'IPAddressVersion': (validate_ipaddress_version, False), - 'Name': (basestring, False), - 'Scope': (basestring, True), + 'Name': (str, False), + 'Scope': (str, True), 'Tags': (Tags, False), } @@ -410,10 +410,10 @@ class RegexPatternSet(AWSObject): resource_type = "AWS::WAFv2::RegexPatternSet" props = { - 'Description': (basestring, False), - 'Name': (basestring, False), - 'RegularExpressionList': ([basestring], True), - 'Scope': (basestring, True), + 'Description': (str, False), + 'Name': (str, False), + 'RegularExpressionList': ([str], True), + 'Scope': (str, True), 'Tags': (Tags, False), } @@ -421,7 +421,7 @@ class RegexPatternSet(AWSObject): class RuleGroupRule(AWSProperty): props = { 'Action': (RuleAction, False), - 'Name': (basestring, False), + 'Name': (str, False), 'Priority': (integer, False), 'Statement': (StatementOne, False), 'VisibilityConfig': (VisibilityConfig, False) @@ -433,10 +433,10 @@ class RuleGroup(AWSObject): props = { 'Capacity': (integer, False), - 'Description': (basestring, False), - 'Name': (basestring, False), + 'Description': (str, False), + 'Name': (str, False), 'Rules': ([RuleGroupRule], False), - 'Scope': (basestring, False), + 'Scope': (str, False), 'Tags': (Tags, False), 'VisibilityConfig': (VisibilityConfig, False) } @@ -446,6 +446,6 @@ class WebACLAssociation(AWSObject): resource_type = "AWS::WAFv2::WebACLAssociation" props = { - 'ResourceArn': (basestring, True), - 'WebACLArn': (basestring, True), + 'ResourceArn': (str, True), + 'WebACLArn': (str, True), } diff --git a/troposphere/workspaces.py b/troposphere/workspaces.py index a659db340..4852134f8 100644 --- a/troposphere/workspaces.py +++ b/troposphere/workspaces.py @@ -18,16 +18,16 @@ class ConnectionAlias(AWSObject): resource_type = "AWS::WorkSpaces::ConnectionAlias" props = { - 'ConnectionString': (basestring, True), + 'ConnectionString': (str, True), 'Tags': (Tags, False), } class WorkspaceProperties(AWSProperty): props = { - 'ComputeTypeName': (basestring, False), + 'ComputeTypeName': (str, False), 'RootVolumeSizeGib': (integer, False), - 'RunningMode': (basestring, False), + 'RunningMode': (str, False), 'RunningModeAutoStopTimeoutInMinutes': (integer, False), 'UserVolumeSizeGib': (integer, False), } @@ -37,12 +37,12 @@ class Workspace(AWSObject): resource_type = "AWS::WorkSpaces::Workspace" props = { - 'BundleId': (basestring, True), - 'DirectoryId': (basestring, True), + 'BundleId': (str, True), + 'DirectoryId': (str, True), 'RootVolumeEncryptionEnabled': (boolean, False), 'Tags': (Tags, False), - 'UserName': (basestring, True), + 'UserName': (str, True), 'UserVolumeEncryptionEnabled': (boolean, False), - 'VolumeEncryptionKey': (basestring, False), + 'VolumeEncryptionKey': (str, False), 'WorkspaceProperties': (WorkspaceProperties, False), } From d78f78476457cff4bc0d24474af972db8809a003 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sun, 21 Mar 2021 12:41:52 +0100 Subject: [PATCH 02/10] Require Python >= 3.6 --- .travis.yml | 5 +---- setup.py | 12 +++--------- 2 files changed, 4 insertions(+), 13 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2ac24e336..87fd0b45f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,12 +1,10 @@ language: python dist: xenial python: - - "2.7" - - "3.5" - "3.6" - "3.7.3" - "3.8" - - "3.9-dev" + - "3.9" env: global: - TROPO_REAL_BOOL=true @@ -18,7 +16,6 @@ install: - pip install --upgrade flake8 before_script: - - if [[ $TRAVIS_PYTHON_VERSION == 3* ]]; then 2to3 -n -w --no-diffs troposphere scripts/cfn2py scripts/gen.py examples/CustomResource.py tests; fi - flake8 --version - flake8 . --show-source diff --git a/setup.py b/setup.py index b373c79a9..b87124052 100644 --- a/setup.py +++ b/setup.py @@ -10,10 +10,6 @@ # ---------------------------------------------------------------------------- -# ---- Future - - - # ---- System import os from setuptools import setup @@ -67,12 +63,12 @@ def get_version(): "Operating System :: POSIX :: Linux", "Programming Language :: Python", + "Programming Language :: Python :: 3 :: Only", + "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.6", - "Programming Language :: Python :: 3.5", - "Programming Language :: Python :: 2.7", ], packages=[ @@ -85,11 +81,9 @@ def get_version(): 'scripts/cfn2py' ], - python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*", + python_requires=">=3.6", install_requires=file_contents("requirements.txt"), test_suite="tests", tests_require=["awacs>=0.8"], extras_require={'policy': ['awacs>=0.8']}, - - use_2to3=True, ) From 4cedb7bfe10bd13388d44b1935e95b2ffa014ea3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sun, 21 Mar 2021 12:44:12 +0100 Subject: [PATCH 03/10] [utils,examples] Revert changes to print functions made by 2to3 --- examples/ApiGateway.py | 2 +- examples/ApplicationAutoScalingSample.py | 2 +- examples/ApplicationELB.py | 2 +- examples/ApplicationLB_FixedActions.py | 2 +- examples/AuroraServerlessRDS_SecretsManager.py | 2 +- examples/Autoscaling.py | 2 +- examples/AutoscalingHTTPRequests.py | 2 +- examples/Backup.py | 2 +- examples/Batch.py | 2 +- examples/CertificateManagerSample.py | 2 +- examples/ClassExtensions.py | 2 +- examples/CloudFormation_Init_ConfigSet.py | 2 +- examples/CloudFront_Distribution_S3.py | 2 +- examples/CloudFront_StreamingDistribution_S3.py | 2 +- examples/CloudTrail.py | 2 +- examples/CloudWatchEventsSample.py | 2 +- examples/CodeBuild.py | 2 +- examples/CodeDeploy.py | 2 +- examples/CodePipeline.py | 2 +- examples/CustomResource.py | 2 +- examples/Dlm.py | 2 +- examples/DynamoDB_Table.py | 2 +- .../DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py | 2 +- examples/DynamoDB_Table_With_GlobalSecondaryIndex.py | 2 +- examples/DynamoDB_Tables_OnDemand.py | 2 +- examples/EC2InstanceSample.py | 2 +- examples/EC2_Remove_Ephemeral_Drive.py | 2 +- examples/ECRSample.py | 2 +- examples/ECSCluster.py | 2 +- examples/ECSFargate.py | 2 +- examples/EFS.py | 2 +- examples/ELBSample.py | 2 +- examples/EMR_Cluster.py | 2 +- examples/ElasticBeanstalk_Nodejs_Sample.py | 2 +- examples/ElasticsearchDomain.py | 2 +- examples/Firehose_with_Redshift.py | 2 +- examples/IAM_Policies_SNS_Publish_To_SQS.py | 2 +- examples/IAM_Roles_and_InstanceProfiles.py | 2 +- examples/IAM_Users_Groups_and_Policies.py | 2 +- examples/IAM_Users_snippet.py | 2 +- examples/IoTAnalytics.py | 2 +- examples/IoTSample.py | 2 +- examples/Kinesis_Stream.py | 2 +- examples/Lambda.py | 2 +- examples/Metadata.py | 2 +- examples/MskCluster.py | 2 +- examples/NatGateway.py | 2 +- examples/NetworkLB.py | 2 +- examples/OpenStack_AutoScaling.py | 2 +- examples/OpenStack_Server.py | 2 +- examples/OpsWorksSnippet.py | 2 +- examples/RDS_Snapshot_On_Delete.py | 2 +- examples/RDS_VPC.py | 2 +- examples/RDS_with_DBParameterGroup.py | 2 +- examples/Redshift.py | 2 +- examples/RedshiftClusterInVpc.py | 2 +- examples/Route53_A.py | 2 +- examples/Route53_CNAME.py | 2 +- examples/Route53_RoundRobin.py | 2 +- examples/S3_Bucket.py | 2 +- examples/S3_Bucket_With_AccelerateConfiguration.py | 2 +- examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py | 2 +- examples/S3_Website_Bucket_With_Retain_On_Delete.py | 2 +- examples/SQSDLQ.py | 2 +- examples/SQSEncrypt.py | 2 +- examples/SQS_With_CloudWatch_Alarms.py | 2 +- examples/SSMExample.py | 2 +- examples/Secretsmanager.py | 2 +- examples/Secretsmanager_Rds.py | 2 +- examples/Serverless_Api_Backend.py | 2 +- examples/Serverless_Deployment_Preference.py | 2 +- examples/Serverless_S3_Processor.py | 2 +- examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py | 2 +- examples/VPC_With_VPN_Connection.py | 2 +- examples/VPC_single_instance_in_subnet.py | 2 +- examples/VpnEndpoint.py | 2 +- examples/WAF_Common_Attacks_Sample.py | 2 +- examples/WAF_Regional_Common_Attacks_Sample.py | 2 +- examples/WaitObject.py | 2 +- troposphere/utils.py | 2 +- 80 files changed, 80 insertions(+), 80 deletions(-) diff --git a/examples/ApiGateway.py b/examples/ApiGateway.py index 30c60bd5e..ddad9163a 100644 --- a/examples/ApiGateway.py +++ b/examples/ApiGateway.py @@ -187,4 +187,4 @@ ), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ApplicationAutoScalingSample.py b/examples/ApplicationAutoScalingSample.py index e6df2336e..afd6db91e 100644 --- a/examples/ApplicationAutoScalingSample.py +++ b/examples/ApplicationAutoScalingSample.py @@ -42,4 +42,4 @@ t.add_resource(scalable_target) t.add_resource(scaling_policy) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ApplicationELB.py b/examples/ApplicationELB.py index b4868ce34..d2a0434dc 100644 --- a/examples/ApplicationELB.py +++ b/examples/ApplicationELB.py @@ -206,7 +206,7 @@ def main(): Value=Join("", ["http://", GetAtt(ApplicationElasticLB, "DNSName")]) )) - print((template.to_json())) + print(template.to_json()) if __name__ == '__main__': diff --git a/examples/ApplicationLB_FixedActions.py b/examples/ApplicationLB_FixedActions.py index 6e43127df..b19078bc8 100644 --- a/examples/ApplicationLB_FixedActions.py +++ b/examples/ApplicationLB_FixedActions.py @@ -158,7 +158,7 @@ def main(): ] ) - print((template.to_json())) + print(template.to_json()) if __name__ == '__main__': diff --git a/examples/AuroraServerlessRDS_SecretsManager.py b/examples/AuroraServerlessRDS_SecretsManager.py index 28553839b..65585d8bd 100644 --- a/examples/AuroraServerlessRDS_SecretsManager.py +++ b/examples/AuroraServerlessRDS_SecretsManager.py @@ -129,4 +129,4 @@ ]) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Autoscaling.py b/examples/Autoscaling.py index b751d935a..b9114d685 100644 --- a/examples/Autoscaling.py +++ b/examples/Autoscaling.py @@ -241,4 +241,4 @@ ) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/AutoscalingHTTPRequests.py b/examples/AutoscalingHTTPRequests.py index 90e8ce1aa..04071f78a 100644 --- a/examples/AutoscalingHTTPRequests.py +++ b/examples/AutoscalingHTTPRequests.py @@ -270,4 +270,4 @@ AlarmActions=[Ref(ScalePolicy)] )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Backup.py b/examples/Backup.py index 6db14b7f5..7a00dbfb9 100644 --- a/examples/Backup.py +++ b/examples/Backup.py @@ -94,4 +94,4 @@ ) ) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/Batch.py b/examples/Batch.py index 7eda0bdc6..49b8b68f5 100644 --- a/examples/Batch.py +++ b/examples/Batch.py @@ -118,4 +118,4 @@ Output('ExampleJobQueue', Value=Ref(ExampleJobQueue)) ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CertificateManagerSample.py b/examples/CertificateManagerSample.py index a9403f397..b91bae335 100644 --- a/examples/CertificateManagerSample.py +++ b/examples/CertificateManagerSample.py @@ -22,4 +22,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ClassExtensions.py b/examples/ClassExtensions.py index 5e9549870..6a12e27fe 100644 --- a/examples/ClassExtensions.py +++ b/examples/ClassExtensions.py @@ -22,4 +22,4 @@ class ProcessingInstance(TrustyInstance): template.add_resource(FrontendInstance('jones1')) template.add_resource(ProcessingInstance('williams1', InstanceType="m2.large")) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/CloudFormation_Init_ConfigSet.py b/examples/CloudFormation_Init_ConfigSet.py index 76b13fe6e..507d9987d 100644 --- a/examples/CloudFormation_Init_ConfigSet.py +++ b/examples/CloudFormation_Init_ConfigSet.py @@ -94,4 +94,4 @@ Value=GetAtt(ec2_instance, 'PublicIp') )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CloudFront_Distribution_S3.py b/examples/CloudFront_Distribution_S3.py index 6cb19d7fb..17b1849f1 100644 --- a/examples/CloudFront_Distribution_S3.py +++ b/examples/CloudFront_Distribution_S3.py @@ -49,4 +49,4 @@ Value=Join("", ["http://", GetAtt(myDistribution, "DomainName")])), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CloudFront_StreamingDistribution_S3.py b/examples/CloudFront_StreamingDistribution_S3.py index c7ac513bc..d00e0dc33 100644 --- a/examples/CloudFront_StreamingDistribution_S3.py +++ b/examples/CloudFront_StreamingDistribution_S3.py @@ -45,4 +45,4 @@ Value=Join("", ["http://", GetAtt(myDistribution, "DomainName")])), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CloudTrail.py b/examples/CloudTrail.py index 2d83a60a1..850e5ce2d 100644 --- a/examples/CloudTrail.py +++ b/examples/CloudTrail.py @@ -93,4 +93,4 @@ DependsOn=["BucketPolicy", "TopicPolicy"], )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CloudWatchEventsSample.py b/examples/CloudWatchEventsSample.py index c05387c06..5ff52f2be 100644 --- a/examples/CloudWatchEventsSample.py +++ b/examples/CloudWatchEventsSample.py @@ -64,4 +64,4 @@ SourceArn=GetAtt(rule, 'Arn') )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CodeBuild.py b/examples/CodeBuild.py index e3114e15d..02a351a12 100644 --- a/examples/CodeBuild.py +++ b/examples/CodeBuild.py @@ -29,4 +29,4 @@ ) template.add_resource(project) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/CodeDeploy.py b/examples/CodeDeploy.py index acb2fdcb3..5c5fd86b4 100644 --- a/examples/CodeDeploy.py +++ b/examples/CodeDeploy.py @@ -93,4 +93,4 @@ ) template.add_resource(deployment_group_on_premises) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/CodePipeline.py b/examples/CodePipeline.py index 7e83d37d5..e13743f03 100644 --- a/examples/CodePipeline.py +++ b/examples/CodePipeline.py @@ -112,4 +112,4 @@ )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/CustomResource.py b/examples/CustomResource.py index 49c82fa2d..c568cdc88 100644 --- a/examples/CustomResource.py +++ b/examples/CustomResource.py @@ -28,4 +28,4 @@ class CustomPlacementGroup(AWSCustomObject): PlacementGroupName="ExampleClusterGroup", )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Dlm.py b/examples/Dlm.py index ab92226d3..b2155d074 100644 --- a/examples/Dlm.py +++ b/examples/Dlm.py @@ -55,4 +55,4 @@ ) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/DynamoDB_Table.py b/examples/DynamoDB_Table.py index 05be42fc4..22be0a4e6 100755 --- a/examples/DynamoDB_Table.py +++ b/examples/DynamoDB_Table.py @@ -78,4 +78,4 @@ Description="Table name of the newly create DynamoDB table", )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py b/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py index 77eff562d..b19f4584e 100644 --- a/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py +++ b/examples/DynamoDB_Table_With_GSI_And_NonKeyAttributes_Projection.py @@ -173,4 +173,4 @@ )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py b/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py index e319aff6f..ec4ee37b4 100644 --- a/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py +++ b/examples/DynamoDB_Table_With_GlobalSecondaryIndex.py @@ -162,4 +162,4 @@ )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/DynamoDB_Tables_OnDemand.py b/examples/DynamoDB_Tables_OnDemand.py index 1ea910c30..291116d63 100644 --- a/examples/DynamoDB_Tables_OnDemand.py +++ b/examples/DynamoDB_Tables_OnDemand.py @@ -226,4 +226,4 @@ )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/EC2InstanceSample.py b/examples/EC2InstanceSample.py index a73f1d857..8c8b9b3e5 100644 --- a/examples/EC2InstanceSample.py +++ b/examples/EC2InstanceSample.py @@ -67,4 +67,4 @@ ), ]) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/EC2_Remove_Ephemeral_Drive.py b/examples/EC2_Remove_Ephemeral_Drive.py index 989cea119..28dba5546 100644 --- a/examples/EC2_Remove_Ephemeral_Drive.py +++ b/examples/EC2_Remove_Ephemeral_Drive.py @@ -79,4 +79,4 @@ ), ]) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/ECRSample.py b/examples/ECRSample.py index fb87b7b3d..53d627417 100644 --- a/examples/ECRSample.py +++ b/examples/ECRSample.py @@ -36,4 +36,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ECSCluster.py b/examples/ECSCluster.py index 874f1b9ca..0dbffdb5e 100644 --- a/examples/ECSCluster.py +++ b/examples/ECSCluster.py @@ -170,4 +170,4 @@ }]} )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ECSFargate.py b/examples/ECSFargate.py index 69f865d48..f416add47 100644 --- a/examples/ECSFargate.py +++ b/examples/ECSFargate.py @@ -46,4 +46,4 @@ ) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/EFS.py b/examples/EFS.py index 0dfbb2403..f8117d9d8 100644 --- a/examples/EFS.py +++ b/examples/EFS.py @@ -128,4 +128,4 @@ # for example: # mount us-west-1a.fs-abcd1234.efs.us-west-1.amazonaws.com: /path -print((template.to_json())) +print(template.to_json()) diff --git a/examples/ELBSample.py b/examples/ELBSample.py index 7ac04256c..5bbfa9894 100644 --- a/examples/ELBSample.py +++ b/examples/ELBSample.py @@ -129,7 +129,7 @@ def main(): Value=Join("", ["http://", GetAtt(elasticLB, "DNSName")]) )) - print((template.to_json())) + print(template.to_json()) if __name__ == '__main__': diff --git a/examples/EMR_Cluster.py b/examples/EMR_Cluster.py index c9ce0e4ea..28684aa1b 100644 --- a/examples/EMR_Cluster.py +++ b/examples/EMR_Cluster.py @@ -274,4 +274,4 @@ def generate_rules(rules_name): JobFlowId=Ref(cluster) )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/ElasticBeanstalk_Nodejs_Sample.py b/examples/ElasticBeanstalk_Nodejs_Sample.py index 14742f775..c38ac086f 100644 --- a/examples/ElasticBeanstalk_Nodejs_Sample.py +++ b/examples/ElasticBeanstalk_Nodejs_Sample.py @@ -159,4 +159,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/ElasticsearchDomain.py b/examples/ElasticsearchDomain.py index a64dc09c1..232688ba3 100644 --- a/examples/ElasticsearchDomain.py +++ b/examples/ElasticsearchDomain.py @@ -43,4 +43,4 @@ ) )) -print((templ.to_json())) +print(templ.to_json()) diff --git a/examples/Firehose_with_Redshift.py b/examples/Firehose_with_Redshift.py index 6ecf6ee71..b75abdb17 100644 --- a/examples/Firehose_with_Redshift.py +++ b/examples/Firehose_with_Redshift.py @@ -56,4 +56,4 @@ ) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IAM_Policies_SNS_Publish_To_SQS.py b/examples/IAM_Policies_SNS_Publish_To_SQS.py index 66749bb8a..5ee789891 100644 --- a/examples/IAM_Policies_SNS_Publish_To_SQS.py +++ b/examples/IAM_Policies_SNS_Publish_To_SQS.py @@ -48,4 +48,4 @@ } )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IAM_Roles_and_InstanceProfiles.py b/examples/IAM_Roles_and_InstanceProfiles.py index c3177d715..0a1ab8cc8 100644 --- a/examples/IAM_Roles_and_InstanceProfiles.py +++ b/examples/IAM_Roles_and_InstanceProfiles.py @@ -29,4 +29,4 @@ Roles=[Ref(cfnrole)] )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IAM_Users_Groups_and_Policies.py b/examples/IAM_Users_Groups_and_Policies.py index 8acf7c7a8..15e7f31d6 100644 --- a/examples/IAM_Users_Groups_and_Policies.py +++ b/examples/IAM_Users_Groups_and_Policies.py @@ -67,4 +67,4 @@ Description="AWSSecretKey of new user", )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IAM_Users_snippet.py b/examples/IAM_Users_snippet.py index d08687788..b994f27d6 100644 --- a/examples/IAM_Users_snippet.py +++ b/examples/IAM_Users_snippet.py @@ -53,4 +53,4 @@ ] )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IoTAnalytics.py b/examples/IoTAnalytics.py index 13916e2f1..c9d46437a 100644 --- a/examples/IoTAnalytics.py +++ b/examples/IoTAnalytics.py @@ -123,4 +123,4 @@ t.add_resource(datastore) t.add_resource(dataset) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/IoTSample.py b/examples/IoTSample.py index b8a8149f0..7bf78e053 100644 --- a/examples/IoTSample.py +++ b/examples/IoTSample.py @@ -79,4 +79,4 @@ t.add_resource(thing_principal) t.add_resource(topic_rule) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Kinesis_Stream.py b/examples/Kinesis_Stream.py index 0fb72cb25..9c13466e4 100644 --- a/examples/Kinesis_Stream.py +++ b/examples/Kinesis_Stream.py @@ -20,4 +20,4 @@ ), ]) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/Lambda.py b/examples/Lambda.py index 36e67f4d9..1d3cae8a5 100644 --- a/examples/Lambda.py +++ b/examples/Lambda.py @@ -156,4 +156,4 @@ Value=Join(", ", GetAtt(AllSecurityGroups, "Value")), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Metadata.py b/examples/Metadata.py index 14bac7858..cf9906da9 100644 --- a/examples/Metadata.py +++ b/examples/Metadata.py @@ -11,4 +11,4 @@ "Version": "V1.0", }) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/MskCluster.py b/examples/MskCluster.py index ba812584a..b6c1609c1 100644 --- a/examples/MskCluster.py +++ b/examples/MskCluster.py @@ -58,4 +58,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/NatGateway.py b/examples/NatGateway.py index 8cbd74649..ddee43f70 100644 --- a/examples/NatGateway.py +++ b/examples/NatGateway.py @@ -120,4 +120,4 @@ Description='Nat Elastic IP', )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/NetworkLB.py b/examples/NetworkLB.py index 3f8777b32..fa819f2d2 100644 --- a/examples/NetworkLB.py +++ b/examples/NetworkLB.py @@ -165,7 +165,7 @@ def main(): Value=Join("", ["http://", GetAtt(NetworkLB, "DNSName")]) )) - print((template.to_json())) + print(template.to_json()) if __name__ == '__main__': diff --git a/examples/OpenStack_AutoScaling.py b/examples/OpenStack_AutoScaling.py index 1b2768fb0..82676a8b8 100644 --- a/examples/OpenStack_AutoScaling.py +++ b/examples/OpenStack_AutoScaling.py @@ -135,4 +135,4 @@ LoadBalancerNames=Ref(loadbalancer), )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/OpenStack_Server.py b/examples/OpenStack_Server.py index aceeb7b03..786485404 100644 --- a/examples/OpenStack_Server.py +++ b/examples/OpenStack_Server.py @@ -60,4 +60,4 @@ ])) )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/OpsWorksSnippet.py b/examples/OpsWorksSnippet.py index 06f33e7b1..a5a83deef 100644 --- a/examples/OpsWorksSnippet.py +++ b/examples/OpsWorksSnippet.py @@ -182,4 +182,4 @@ }, )) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/RDS_Snapshot_On_Delete.py b/examples/RDS_Snapshot_On_Delete.py index dee2f1522..028231fad 100644 --- a/examples/RDS_Snapshot_On_Delete.py +++ b/examples/RDS_Snapshot_On_Delete.py @@ -39,4 +39,4 @@ ]), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/RDS_VPC.py b/examples/RDS_VPC.py index f8daa767b..1a2cbd732 100644 --- a/examples/RDS_VPC.py +++ b/examples/RDS_VPC.py @@ -132,4 +132,4 @@ ]) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/RDS_with_DBParameterGroup.py b/examples/RDS_with_DBParameterGroup.py index 3c5af5821..732f86e3c 100644 --- a/examples/RDS_with_DBParameterGroup.py +++ b/examples/RDS_with_DBParameterGroup.py @@ -60,4 +60,4 @@ DBParameterGroupName=Ref(myrdsparamgroup), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Redshift.py b/examples/Redshift.py index 5833349c4..070970473 100644 --- a/examples/Redshift.py +++ b/examples/Redshift.py @@ -111,4 +111,4 @@ GetAtt(redshiftcluster, "Endpoint.Port")]), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/RedshiftClusterInVpc.py b/examples/RedshiftClusterInVpc.py index f9429ea6e..ba467d910 100644 --- a/examples/RedshiftClusterInVpc.py +++ b/examples/RedshiftClusterInVpc.py @@ -156,4 +156,4 @@ GetAtt(redshiftcluster, "Endpoint.Port")]), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Route53_A.py b/examples/Route53_A.py index 5c3c67b7e..ba5b89b50 100644 --- a/examples/Route53_A.py +++ b/examples/Route53_A.py @@ -53,4 +53,4 @@ t.add_output(Output("DomainName", Value=Ref(myDNSRecord))) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Route53_CNAME.py b/examples/Route53_CNAME.py index b2edcf482..cd1c235f3 100644 --- a/examples/Route53_CNAME.py +++ b/examples/Route53_CNAME.py @@ -36,4 +36,4 @@ t.add_output(Output("DomainName", Value=Ref(myDNSRecord))) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Route53_RoundRobin.py b/examples/Route53_RoundRobin.py index 72b581b56..f6433beb0 100644 --- a/examples/Route53_RoundRobin.py +++ b/examples/Route53_RoundRobin.py @@ -52,4 +52,4 @@ )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/S3_Bucket.py b/examples/S3_Bucket.py index 8efe23c4f..d96121788 100644 --- a/examples/S3_Bucket.py +++ b/examples/S3_Bucket.py @@ -22,4 +22,4 @@ Description="Name of S3 bucket to hold website content" )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/S3_Bucket_With_AccelerateConfiguration.py b/examples/S3_Bucket_With_AccelerateConfiguration.py index 56286e30d..cef81663a 100644 --- a/examples/S3_Bucket_With_AccelerateConfiguration.py +++ b/examples/S3_Bucket_With_AccelerateConfiguration.py @@ -30,4 +30,4 @@ Description="Name of S3 bucket with s3 transfer acceleration enabled", )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py b/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py index af6aebf9d..15593c0c7 100644 --- a/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py +++ b/examples/S3_Bucket_With_Versioning_And_Lifecycle_Rules.py @@ -66,4 +66,4 @@ Description="Name of S3 bucket to hold website content" )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/S3_Website_Bucket_With_Retain_On_Delete.py b/examples/S3_Website_Bucket_With_Retain_On_Delete.py index 2c4a58afa..3b98f8b01 100644 --- a/examples/S3_Website_Bucket_With_Retain_On_Delete.py +++ b/examples/S3_Website_Bucket_With_Retain_On_Delete.py @@ -39,4 +39,4 @@ ), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/SQSDLQ.py b/examples/SQSDLQ.py index 40374f3fd..badc2b5e1 100644 --- a/examples/SQSDLQ.py +++ b/examples/SQSDLQ.py @@ -46,4 +46,4 @@ ), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/SQSEncrypt.py b/examples/SQSEncrypt.py index 8de7898b8..7366d9462 100644 --- a/examples/SQSEncrypt.py +++ b/examples/SQSEncrypt.py @@ -33,4 +33,4 @@ ) ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/SQS_With_CloudWatch_Alarms.py b/examples/SQS_With_CloudWatch_Alarms.py index e97a57f54..4e4b5961b 100644 --- a/examples/SQS_With_CloudWatch_Alarms.py +++ b/examples/SQS_With_CloudWatch_Alarms.py @@ -80,4 +80,4 @@ ), ]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/SSMExample.py b/examples/SSMExample.py index f08a64c40..89507d19e 100644 --- a/examples/SSMExample.py +++ b/examples/SSMExample.py @@ -88,4 +88,4 @@ Value="Redhat TIME_STAMP_VALUE" )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Secretsmanager.py b/examples/Secretsmanager.py index 4c4badd37..b1d8f4741 100644 --- a/examples/Secretsmanager.py +++ b/examples/Secretsmanager.py @@ -18,4 +18,4 @@ ) )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Secretsmanager_Rds.py b/examples/Secretsmanager_Rds.py index 7e417b8b6..f3a1f8c5f 100644 --- a/examples/Secretsmanager_Rds.py +++ b/examples/Secretsmanager_Rds.py @@ -42,4 +42,4 @@ TargetId=Ref(Instance), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Serverless_Api_Backend.py b/examples/Serverless_Api_Backend.py index 51238dec3..0a7bb12b5 100644 --- a/examples/Serverless_Api_Backend.py +++ b/examples/Serverless_Api_Backend.py @@ -84,4 +84,4 @@ ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Serverless_Deployment_Preference.py b/examples/Serverless_Deployment_Preference.py index 5b92a6d81..2cfeae422 100644 --- a/examples/Serverless_Deployment_Preference.py +++ b/examples/Serverless_Deployment_Preference.py @@ -26,4 +26,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/Serverless_S3_Processor.py b/examples/Serverless_S3_Processor.py index ad9cfb29e..65e8abbac 100644 --- a/examples/Serverless_S3_Processor.py +++ b/examples/Serverless_S3_Processor.py @@ -35,4 +35,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py b/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py index 353c2ef49..933156d01 100644 --- a/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py +++ b/examples/VPC_EC2_Instance_With_Multiple_Dynamic_IPAddresses.py @@ -148,4 +148,4 @@ ), ]) -print((template.to_json())) +print(template.to_json()) diff --git a/examples/VPC_With_VPN_Connection.py b/examples/VPC_With_VPN_Connection.py index d2f075b21..0f51fa3cc 100644 --- a/examples/VPC_With_VPN_Connection.py +++ b/examples/VPC_With_VPN_Connection.py @@ -212,4 +212,4 @@ Value=Ref(VPC), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/VPC_single_instance_in_subnet.py b/examples/VPC_single_instance_in_subnet.py index 688cfe495..2639f8a95 100644 --- a/examples/VPC_single_instance_in_subnet.py +++ b/examples/VPC_single_instance_in_subnet.py @@ -415,4 +415,4 @@ GetAtt('WebServerInstance', 'PublicIp')]))]) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/VpnEndpoint.py b/examples/VpnEndpoint.py index e89ede2af..48bf13ad9 100644 --- a/examples/VpnEndpoint.py +++ b/examples/VpnEndpoint.py @@ -33,4 +33,4 @@ ) ) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/WAF_Common_Attacks_Sample.py b/examples/WAF_Common_Attacks_Sample.py index 71afa9f72..71c7f0c6a 100644 --- a/examples/WAF_Common_Attacks_Sample.py +++ b/examples/WAF_Common_Attacks_Sample.py @@ -225,4 +225,4 @@ MetricName=Ref(WebACLName), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/WAF_Regional_Common_Attacks_Sample.py b/examples/WAF_Regional_Common_Attacks_Sample.py index 713d5fcc7..6abf77594 100644 --- a/examples/WAF_Regional_Common_Attacks_Sample.py +++ b/examples/WAF_Regional_Common_Attacks_Sample.py @@ -225,4 +225,4 @@ MetricName=Ref(WebACLName), )) -print((t.to_json())) +print(t.to_json()) diff --git a/examples/WaitObject.py b/examples/WaitObject.py index b4e6b1711..f6563d2f8 100644 --- a/examples/WaitObject.py +++ b/examples/WaitObject.py @@ -39,4 +39,4 @@ ) ]) -print((t.to_json())) +print(t.to_json()) diff --git a/troposphere/utils.py b/troposphere/utils.py index c668e98a9..670a68022 100644 --- a/troposphere/utils.py +++ b/troposphere/utils.py @@ -2,7 +2,7 @@ def _tail_print(e): - print(("%s %s %s" % (e.resource_status, e.resource_type, e.event_id))) + print("%s %s %s" % (e.resource_status, e.resource_type, e.event_id)) def get_events(conn, stackname): From 81356f4c997977b5714a820eb4b630dd491b8fbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sun, 21 Mar 2021 12:52:04 +0100 Subject: [PATCH 04/10] Remove unnecessary conversions of iterables to lists --- examples/EC2Conditions.py | 4 ++-- tests/test_dict.py | 2 +- tests/test_examples.py | 2 +- tests/test_examples_template_generator.py | 2 +- tests/test_int_type.py | 2 +- troposphere/__init__.py | 24 +++++++++++------------ troposphere/cloudformation.py | 2 +- troposphere/elasticloadbalancingv2.py | 2 +- troposphere/rds.py | 2 +- 9 files changed, 21 insertions(+), 21 deletions(-) diff --git a/examples/EC2Conditions.py b/examples/EC2Conditions.py index c36892815..e99133eb8 100644 --- a/examples/EC2Conditions.py +++ b/examples/EC2Conditions.py @@ -88,11 +88,11 @@ t = Template() -for p in list(parameters.values()): +for p in parameters.values(): t.add_parameter(p) for k in conditions: t.add_condition(k, conditions[k]) -for r in list(resources.values()): +for r in resources.values(): t.add_resource(r) print(t.to_json()) diff --git a/tests/test_dict.py b/tests/test_dict.py index 6c0de6c31..efead5756 100644 --- a/tests/test_dict.py +++ b/tests/test_dict.py @@ -76,7 +76,7 @@ def test_invalid_subproperty_definition(self): def test_tags_from_dict(self): d = {"key1": "value1", "key2": "value2"} - expected = [{"Key": k, "Value": v} for k, v in list(d.items())] + expected = [{"Key": k, "Value": v} for k, v in d.items()] tags = Tags.from_dict(**d) self.assertEqual(sorted(expected), sorted(tags.tags)) diff --git a/tests/test_examples.py b/tests/test_examples.py index 781a78d1c..d00b56d27 100644 --- a/tests/test_examples.py +++ b/tests/test_examples.py @@ -46,7 +46,7 @@ def load_tests(loader, tests, pattern): # Filter out all *.py files from the examples directory examples = 'examples' regex = re.compile(r'.py$', re.I) - example_filesnames = list(filter(regex.search, os.listdir(examples))) + example_filesnames = filter(regex.search, os.listdir(examples)) suite = unittest.TestSuite() diff --git a/tests/test_examples_template_generator.py b/tests/test_examples_template_generator.py index 940a92d53..77788e2b2 100644 --- a/tests/test_examples_template_generator.py +++ b/tests/test_examples_template_generator.py @@ -44,7 +44,7 @@ def load_tests(loader, tests, pattern): # Filter out all *.py files from the examples directory examples = 'examples' regex = re.compile(r'.py$', re.I) - example_filesnames = list(filter(regex.search, os.listdir(examples))) + example_filesnames = filter(regex.search, os.listdir(examples)) suite = unittest.TestSuite() diff --git a/tests/test_int_type.py b/tests/test_int_type.py index 3b1c3933e..37bdd351b 100644 --- a/tests/test_int_type.py +++ b/tests/test_int_type.py @@ -32,7 +32,7 @@ def get_aws_objects(self): return result def assertNoIntType(self, obj): - for prop_name, (types, required) in list(obj.props.items()): + for prop_name, (types, required) in obj.props.items(): error_msg = ( "{}.props['{}'] should have `validators.integer` " "rather than `int`".format(obj.__name__, prop_name)) diff --git a/troposphere/__init__.py b/troposphere/__init__.py index 979226b99..7992295af 100644 --- a/troposphere/__init__.py +++ b/troposphere/__init__.py @@ -57,12 +57,12 @@ def encode_to_dict(obj): return encode_to_dict(obj.to_dict()) elif isinstance(obj, (list, tuple)): new_lst = [] - for o in list(obj): + for o in obj: new_lst.append(encode_to_dict(o)) return new_lst elif isinstance(obj, dict): props = {} - for name, prop in list(obj.items()): + for name, prop in obj.items(): props[name] = encode_to_dict(prop) return props @@ -93,7 +93,7 @@ def __init__(self, title, template=None, validation=True, **kwargs): self.template = template self.do_validation = validation # Cache the keys for validity checks - self.propnames = list(self.props.keys()) + self.propnames = self.props.keys() self.attributes = [ 'Condition', 'CreationPolicy', 'DeletionPolicy', 'DependsOn', 'Metadata', 'UpdatePolicy', 'UpdateReplacePolicy', @@ -117,13 +117,13 @@ def __init__(self, title, template=None, validation=True, **kwargs): self.__initialized = True # Check for properties defined in the class - for k, (_, required) in list(self.props.items()): + for k, (_, required) in self.props.items(): v = getattr(type(self), k, None) if v is not None and k not in kwargs: self.__setattr__(k, v) # Now that it is initialized, populate it with the kwargs - for k, v in list(kwargs.items()): + for k, v in kwargs.items(): self.__setattr__(k, v) self.add_to_template() @@ -155,7 +155,7 @@ def __getattr__(self, name): raise AttributeError(name) def __setattr__(self, name, value): - if name in list(self.__dict__.keys()) \ + if name in self.__dict__.keys() \ or '_BaseAWSObject__initialized' not in self.__dict__: return dict.__setattr__(self, name, value) elif name in self.attributes: @@ -257,7 +257,7 @@ def to_dict(self): return encode_to_dict(self.resource) elif hasattr(self, 'resource_type'): d = {} - for k, v in list(self.resource.items()): + for k, v in self.resource.items(): if k != 'Properties': d[k] = v return d @@ -267,7 +267,7 @@ def to_dict(self): @classmethod def _from_dict(cls, title=None, **kwargs): props = {} - for prop_name, value in list(kwargs.items()): + for prop_name, value in kwargs.items(): try: prop_attrs = cls.props[prop_name] except KeyError: @@ -308,7 +308,7 @@ def from_dict(cls, title, d): return cls._from_dict(title, **d) def _validate_props(self): - for k, (_, required) in list(self.props.items()): + for k, (_, required) in self.props.items(): if required and k not in self.properties: rtype = getattr(self, 'resource_type', "") title = getattr(self, 'title') @@ -566,7 +566,7 @@ def add_tag(tag_list, k, v): for k, v in sorted(tag_dict.items()): add_tag(self.tags, k, v) else: - for k, v in list(tag_dict.items()): + for k, v in tag_dict.items(): add_tag(self.tags, k, v) # allow concatenation of the Tags object via '+' operator @@ -886,7 +886,7 @@ def check_type(t, v): allowed = [float, int] # See if the default value can be coerced into one # of the correct types - if not any([check_type(x, default) for x in allowed]): + if not any(check_type(x, default) for x in allowed): raise ValueError(error_str % (param_type, type(default), default)) elif param_type == 'List': @@ -897,7 +897,7 @@ def check_type(t, v): dlist = default.split(",") for d in dlist: # Verify the split array are all numbers - if not any([check_type(x, d) for x in allowed]): + if not any(check_type(x, d) for x in allowed): raise ValueError(error_str % (param_type, type(d), dlist)) diff --git a/troposphere/cloudformation.py b/troposphere/cloudformation.py index 0e32d8c22..c8edf29e9 100644 --- a/troposphere/cloudformation.py +++ b/troposphere/cloudformation.py @@ -149,7 +149,7 @@ class WaitCondition(AWSObject): def validate(self): if 'CreationPolicy' in self.resource: - for k in list(self.props.keys()): + for k in self.props.keys(): if k in self.properties: raise ValueError( "Property %s cannot be specified with CreationPolicy" % diff --git a/troposphere/elasticloadbalancingv2.py b/troposphere/elasticloadbalancingv2.py index d391447a0..e7c58d304 100644 --- a/troposphere/elasticloadbalancingv2.py +++ b/troposphere/elasticloadbalancingv2.py @@ -134,7 +134,7 @@ def validate(self): def requires(action_type, prop): properties = [definition for definition in - list(self.properties.keys())] + self.properties.keys()] if self.properties.get('Type') == action_type and \ not self.any_property(prop, properties): raise ValueError( diff --git a/troposphere/rds.py b/troposphere/rds.py index 8d09cf194..d2ea2d648 100644 --- a/troposphere/rds.py +++ b/troposphere/rds.py @@ -241,7 +241,7 @@ def validate(self): 'DBSnapshotIdentifier', ) - invalid_properties = [s for s in list(self.properties.keys()) if + invalid_properties = [s for s in self.properties.keys() if s in invalid_replica_properties] if invalid_properties: From e581fd1fd1e5714d3b63ab406af3a00df4f1caaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Wed, 21 Oct 2020 09:55:15 +0200 Subject: [PATCH 05/10] Cleanup scripts --- scripts/cfn2py | 16 +++++----------- scripts/gen.py | 4 ++-- 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/scripts/cfn2py b/scripts/cfn2py index 8495d4497..1a3a1c01a 100755 --- a/scripts/cfn2py +++ b/scripts/cfn2py @@ -1,15 +1,9 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import argparse import json import pprint -try: - getattr(__builtins__, 'basestring') -except AttributeError: - basestring = str - class object_registry(object): """Keep track of objects being created as Parameters or Resources @@ -258,7 +252,7 @@ def do_resources(d): tropo_object = top_level_aliases[tropo_object] print('{} = t.add_resource({}('.format(object_name, tropo_object)) print(' "{}",'.format(k)) - for p in filter(lambda x: x in v, ['Metadata', 'Properties']): + for p in (x for x in ['Metadata', 'Properties'] if x in v): for pk, pv in v[p].items(): if pk == "Tags": print(' Tags=Tags(') @@ -270,7 +264,7 @@ def do_resources(d): print(" {}={}({}),".format(pk, pk, output_dict(pv))) elif pk in known_functions: do_resources_content(pk, pv, p) - elif isinstance(pv, basestring): + elif isinstance(pv, str): print(' {}="{}",'.format(pk, pv)) else: print(' {}={},'.format(pk, output_value(pv))) @@ -323,7 +317,7 @@ function_map = { def output_value(v): """Output a value which may be a string or a set of function calls.""" - if isinstance(v, basestring): + if isinstance(v, str): return '"{}"'.format(v.replace('\\', '\\\\') .replace('\n', '\\n') .replace("\"", "\\\"")) @@ -357,7 +351,7 @@ def do_outputs(d): print('{} = t.add_output(Output('.format(k)) print(' "{}",'.format(k)) for pk, pv in v.items(): - if isinstance(pv, basestring): + if isinstance(pv, str): print(' {}="{}",'.format(pk, pv)) else: print(' {}={},'.format(pk, output_value(pv))) diff --git a/scripts/gen.py b/scripts/gen.py index 789d93605..f11728ccb 100644 --- a/scripts/gen.py +++ b/scripts/gen.py @@ -339,8 +339,8 @@ def get_required(value): 'Integer': 'integer', 'Json': 'dict', 'Long': 'integer', - 'String': 'basestring', - 'Timestamp': 'basestring', + 'String': 'str', + 'Timestamp': 'str', } From d786dcf38887bb2c744873ebbc53880f51c46754 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Wed, 21 Oct 2020 09:56:38 +0200 Subject: [PATCH 06/10] Restore TypeError's message --- troposphere/__init__.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/troposphere/__init__.py b/troposphere/__init__.py index 7992295af..b780f709e 100644 --- a/troposphere/__init__.py +++ b/troposphere/__init__.py @@ -556,7 +556,9 @@ def __init__(self, *args, **kwargs): elif isinstance(arg, dict): tag_dict.update(arg) else: - raise TypeError + raise TypeError( + "Tags needs to be either kwargs, dict, or AWSHelperFn" + ) def add_tag(tag_list, k, v): tag_list.append({'Key': k, 'Value': v, }) From 5a6d96403fb9ce6ad0c9a2440f5e43a3f35600b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Wed, 21 Oct 2020 10:01:06 +0200 Subject: [PATCH 07/10] Cleanup ImportErrors and NameErrors --- tests/test_examples.py | 13 ++----------- tests/test_examples_template_generator.py | 5 ----- tests/test_rds.py | 8 +------- tests/test_template_generator.py | 5 ----- 4 files changed, 3 insertions(+), 28 deletions(-) diff --git a/tests/test_examples.py b/tests/test_examples.py index d00b56d27..cafb47925 100644 --- a/tests/test_examples.py +++ b/tests/test_examples.py @@ -1,18 +1,9 @@ +import io import os import re import sys import unittest -try: - import io as io -except ImportError: - import io - -try: - u = str -except NameError: - u = str - class TestExamples(unittest.TestCase): maxDiff = None @@ -34,7 +25,7 @@ def test_example(self): # rewind fake stdout so we can read it stdout.seek(0) actual_output = stdout.read() - self.assertEqual(u(self.expected_output), u(actual_output)) + self.assertEqual(str(self.expected_output), str(actual_output)) def create_test_class(testname, **kwargs): diff --git a/tests/test_examples_template_generator.py b/tests/test_examples_template_generator.py index 77788e2b2..1c7e2fe45 100644 --- a/tests/test_examples_template_generator.py +++ b/tests/test_examples_template_generator.py @@ -5,11 +5,6 @@ from troposphere.template_generator import TemplateGenerator -try: - u = str -except NameError: - u = str - class TestTemplateGenerator(unittest.TestCase): maxDiff = None diff --git a/tests/test_rds.py b/tests/test_rds.py index 2475d5c4f..ed96c53fe 100644 --- a/tests/test_rds.py +++ b/tests/test_rds.py @@ -102,12 +102,6 @@ def test_it_rds_instances_require_encryption_if_kms_key_provided(self): rds_instance.to_dict() def test_it_allows_an_rds_instance_with_iops(self): - # ensure troposphere works with longs and ints - try: - long_number = int(2000) - except NameError: - # Python 3 doesn't have 'long' anymore - long_number = 2000 rds_instance = rds.DBInstance( 'SomeTitle', AllocatedStorage=200, @@ -116,7 +110,7 @@ def test_it_allows_an_rds_instance_with_iops(self): MasterUsername='SomeUsername', MasterUserPassword='SomePassword', StorageType='io1', - Iops=long_number, + Iops=2000, ) rds_instance.to_dict() diff --git a/tests/test_template_generator.py b/tests/test_template_generator.py index 2e5815726..238e5ecbd 100644 --- a/tests/test_template_generator.py +++ b/tests/test_template_generator.py @@ -6,11 +6,6 @@ from troposphere.template_generator import\ TemplateGenerator, ResourceTypeNotDefined, ResourceTypeNotFound -try: - u = str -except NameError: - u = str - class TestTemplateGenerator(unittest.TestCase): def test_resource_type_not_defined(self): From 715540231873f230c8da5f3f9945d28bb8c2ce25 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Wed, 21 Oct 2020 10:08:04 +0200 Subject: [PATCH 08/10] [tests] Make necessary adjustments --- tests/test_awslambda.py | 2 +- tests/test_basic.py | 2 +- tests/test_codebuild.py | 6 +++--- tests/test_dict.py | 5 ++++- tests/test_int_type.py | 2 +- 5 files changed, 10 insertions(+), 7 deletions(-) diff --git a/tests/test_awslambda.py b/tests/test_awslambda.py index e52003abb..24154e776 100644 --- a/tests/test_awslambda.py +++ b/tests/test_awslambda.py @@ -77,7 +77,7 @@ def test_environment_variable_invalid_name(self): Environment(Variables={var: 'value'}) self.assertTrue('Invalid environment variable name: %s' % var - in context.exception) + in context.exception.args) def test_environment_variable_reserved(self): for var in ['AWS_ACCESS_KEY', 'AWS_ACCESS_KEY_ID', diff --git a/tests/test_basic.py b/tests/test_basic.py index 95d835e94..870db6580 100644 --- a/tests/test_basic.py +++ b/tests/test_basic.py @@ -381,7 +381,7 @@ def test_ref_eq(self): def test_ref_hash(self): s = hash("AWS::NoValue") - r = hash(Ref(s)) + r = hash(Ref("AWS::NoValue")) wch = cloudformation.WaitConditionHandle("TestResource") diff --git a/tests/test_codebuild.py b/tests/test_codebuild.py index bb0cf6e64..2303ce166 100644 --- a/tests/test_codebuild.py +++ b/tests/test_codebuild.py @@ -57,13 +57,13 @@ def test_filter_no_filtergroup(self): codebuild.ProjectTriggers().validate() def test_filter_not_list(self): - match = ", expected " + match = ", expected " with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=42).validate() def test_filter_element_not_a_list(self): wh = codebuild.WebhookFilter - match = "is , expected " + match = "is , expected " with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=[ [wh(Type="EVENT", Pattern="PULL_REQUEST_CREATED")], @@ -73,7 +73,7 @@ def test_filter_element_not_a_list(self): def test_filter_fail(self): wh = codebuild.WebhookFilter - match = "" + match = "" with self.assertRaisesRegex(TypeError, match): codebuild.ProjectTriggers(FilterGroups=[ [wh(Type="EVENT", Pattern="PULL_REQUEST_CREATED")], diff --git a/tests/test_dict.py b/tests/test_dict.py index efead5756..21df8eb3c 100644 --- a/tests/test_dict.py +++ b/tests/test_dict.py @@ -75,11 +75,14 @@ def test_invalid_subproperty_definition(self): ecs.ContainerDefinition.from_dict("mycontainer", self.d) def test_tags_from_dict(self): + def key(k): + return (k["Key"], k["Value"]) + d = {"key1": "value1", "key2": "value2"} expected = [{"Key": k, "Value": v} for k, v in d.items()] tags = Tags.from_dict(**d) - self.assertEqual(sorted(expected), sorted(tags.tags)) + self.assertEqual(sorted(expected, key=key), sorted(tags.tags, key=key)) if __name__ == '__main__': diff --git a/tests/test_int_type.py b/tests/test_int_type.py index 37bdd351b..7c5f1dd97 100644 --- a/tests/test_int_type.py +++ b/tests/test_int_type.py @@ -44,7 +44,7 @@ def assertNoIntType(self, obj): def _get_all_troposphere_modules(self, dirname): return [ pkg_name - for importer, pkg_name, is_pkg in pkgutil.walk_packages(dirname) + for importer, pkg_name, is_pkg in pkgutil.walk_packages([dirname]) if not is_pkg and pkg_name.startswith('troposphere') ] From 93a44b3e02319329458911a45ce5f3849faae9d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Wed, 21 Oct 2020 10:32:23 +0200 Subject: [PATCH 09/10] [examples] Fix indentation --- examples/Lambda.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/examples/Lambda.py b/examples/Lambda.py index 1d3cae8a5..a31585030 100644 --- a/examples/Lambda.py +++ b/examples/Lambda.py @@ -55,25 +55,25 @@ t.add_mapping("AWSRegionArch2AMI", {'ap-northeast-1': {'HVM64': 'ami-cbf90ecb', - 'PV64': 'ami-27f90e27'}, + 'PV64': 'ami-27f90e27'}, 'ap-southeast-1': {'HVM64': 'ami-68d8e93a', - 'PV64': 'ami-acd9e8fe'}, + 'PV64': 'ami-acd9e8fe'}, 'ap-southeast-2': {'HVM64': 'ami-fd9cecc7', - 'PV64': 'ami-ff9cecc5'}, + 'PV64': 'ami-ff9cecc5'}, 'cn-north-1': {'HVM64': 'ami-f239abcb', - 'PV64': 'ami-fa39abc3'}, + 'PV64': 'ami-fa39abc3'}, 'eu-central-1': {'HVM64': 'ami-a8221fb5', - 'PV64': 'ami-ac221fb1'}, + 'PV64': 'ami-ac221fb1'}, 'eu-west-1': {'HVM64': 'ami-a10897d6', - 'PV64': 'ami-bf0897c8'}, + 'PV64': 'ami-bf0897c8'}, 'sa-east-1': {'HVM64': 'ami-b52890a8', - 'PV64': 'ami-bb2890a6'}, + 'PV64': 'ami-bb2890a6'}, 'us-east-1': {'HVM64': 'ami-1ecae776', - 'PV64': 'ami-1ccae774'}, + 'PV64': 'ami-1ccae774'}, 'us-west-1': {'HVM64': 'ami-d114f295', - 'PV64': 'ami-d514f291'}, + 'PV64': 'ami-d514f291'}, 'us-west-2': {'HVM64': 'ami-e7527ed7', - 'PV64': 'ami-ff527ecf'}} + 'PV64': 'ami-ff527ecf'}} ) code = [ From 7a5ca1e766f26396d1fff9c7391d797e9736592e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sun, 21 Mar 2021 13:06:08 +0100 Subject: [PATCH 10/10] Make BaseAWSObject.propnames pickleable --- troposphere/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/troposphere/__init__.py b/troposphere/__init__.py index b780f709e..ae2f46882 100644 --- a/troposphere/__init__.py +++ b/troposphere/__init__.py @@ -93,7 +93,7 @@ def __init__(self, title, template=None, validation=True, **kwargs): self.template = template self.do_validation = validation # Cache the keys for validity checks - self.propnames = self.props.keys() + self.propnames = set(self.props.keys()) self.attributes = [ 'Condition', 'CreationPolicy', 'DeletionPolicy', 'DependsOn', 'Metadata', 'UpdatePolicy', 'UpdateReplacePolicy',