Skip to content

Commit 7603ebe

Browse files
mumblepinskddejong
authored andcommitted
feat: add support for python 3.8 and 3.9, switched docker image to mlupin/docker-lambda
1 parent eee3b43 commit 7603ebe

File tree

3 files changed

+25
-1
lines changed

3 files changed

+25
-1
lines changed

python/rpdk/python/codegen.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ def generate(self, project):
171171

172172
if project.configuration_schema:
173173
configuration_schema_path = (
174-
project.root / project.configuration_schema_filename
174+
project.root / project.configuration_schema_filename
175175
)
176176
project.write_configuration_schema(configuration_schema_path)
177177
configuration_models = resolve_models(
@@ -348,3 +348,15 @@ class Python37LanguagePlugin(Python36LanguagePlugin):
348348
NAME = "python37"
349349
RUNTIME = "python3.7"
350350
DOCKER_TAG = 3.7
351+
352+
353+
class Python38LanguagePlugin(Python36LanguagePlugin):
354+
NAME = "python38"
355+
RUNTIME = "python3.8"
356+
DOCKER_TAG = 3.8
357+
358+
359+
class Python39LanguagePlugin(Python36LanguagePlugin):
360+
NAME = "python39"
361+
RUNTIME = "python3.9"
362+
DOCKER_TAG = 3.9

python/rpdk/python/parser.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,11 @@ def setup_subparser_python36(subparsers, parents):
2727

2828
def setup_subparser_python37(subparsers, parents):
2929
return setup_subparser(subparsers, parents, "python37")
30+
31+
32+
def setup_subparser_python38(subparsers, parents):
33+
return setup_subparser(subparsers, parents, "python38")
34+
35+
36+
def setup_subparser_python39(subparsers, parents):
37+
return setup_subparser(subparsers, parents, "python39")

setup.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,14 @@ def find_version(*file_paths):
4040
install_requires=["cloudformation-cli>=0.2.23", "types-dataclasses>=0.1.5"],
4141
entry_points={
4242
"rpdk.v1.languages": [
43+
"python39 = rpdk.python.codegen:Python39LanguagePlugin",
44+
"python38 = rpdk.python.codegen:Python38LanguagePlugin",
4345
"python37 = rpdk.python.codegen:Python37LanguagePlugin",
4446
"python36 = rpdk.python.codegen:Python36LanguagePlugin",
4547
],
4648
"rpdk.v1.parsers": [
49+
"python39 = rpdk.python.parser:setup_subparser_python39",
50+
"python38 = rpdk.python.parser:setup_subparser_python38",
4751
"python37 = rpdk.python.parser:setup_subparser_python37",
4852
"python36 = rpdk.python.parser:setup_subparser_python36",
4953
],

0 commit comments

Comments
 (0)