From 6f91288798ab8831297de2591fefdf71632e568a Mon Sep 17 00:00:00 2001 From: Jerry Kindall <52084730+Jerry-AWS@users.noreply.github.com> Date: Mon, 8 Mar 2021 14:18:59 -0800 Subject: [PATCH 1/2] fix(init): Stack ID in Python init template doesn't match other languages In all other languages other than Python, creating a new folder `hello-cdk` and doing `cdk init` results in a stack with an ID of `HelloCdkStack`. In Python you get `hello-cdk`. This PR changes the Python init template to match the other languages. --- .../aws-cdk/lib/init-templates/v1/app/python/app.template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/aws-cdk/lib/init-templates/v1/app/python/app.template.py b/packages/aws-cdk/lib/init-templates/v1/app/python/app.template.py index 808bc22af32e4..15c0e0432d6da 100644 --- a/packages/aws-cdk/lib/init-templates/v1/app/python/app.template.py +++ b/packages/aws-cdk/lib/init-templates/v1/app/python/app.template.py @@ -6,6 +6,6 @@ app = core.App() -%name.PascalCased%Stack(app, "%name.StackName%") +%name.PascalCased%Stack(app, "%name.PascalCased%Stack") app.synth() From 4d2ecc85907ba4cd36fdb8381e6a34be2b580c35 Mon Sep 17 00:00:00 2001 From: Jerry Kindall <52084730+Jerry-AWS@users.noreply.github.com> Date: Mon, 8 Mar 2021 14:22:19 -0800 Subject: [PATCH 2/2] Change Python stack ID to match other languages --- .../aws-cdk/lib/init-templates/v2/app/python/app.template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/aws-cdk/lib/init-templates/v2/app/python/app.template.py b/packages/aws-cdk/lib/init-templates/v2/app/python/app.template.py index a1dd331433422..5d1fa551c1c70 100644 --- a/packages/aws-cdk/lib/init-templates/v2/app/python/app.template.py +++ b/packages/aws-cdk/lib/init-templates/v2/app/python/app.template.py @@ -6,6 +6,6 @@ app = core.App() -%name.PascalCased%Stack(app, "%name.StackName%") +%name.PascalCased%Stack(app, "%name.PascalCased%Stack") app.synth()