aws / aws/aws-cdk

aws-lambda-python-alpha: there should be a python version type

Open
#35,429 2 comments 0 reactions 0 assignees View on GitHub
@aws-cdk/aws-lambda-python effort/small feature-request p3
Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
83

Description

### Describe the feature

Currently, the `Runtime` type is used to set runtime properties, and it is expected to only pass in Python runtimes. This experience could be improved by adding a specific Python runtime property that only has python versions.

### Use Case

Cleanly set the version of the python lambda

### Proposed Solution

Create a new PythonRuntime type - not sure with the specific language syntax of TypeScript, but maybe Runtime can be associated to PythonRuntime in some way? Or maybe instead of `Runtime.PYTHON_3_12`, we can instead do `Runtime.Python.3_12`?

### Other Information

_No response_

### Acknowledgements

- [x] I may be able to implement this feature request
- [ ] This feature might incur a breaking change

### AWS CDK Library version (aws-cdk-lib)

aws-cdk-lib@2.179.0

### AWS CDK CLI version

2.1000.2 (build bc82193)

### Environment details (OS name and version, etc.)

MacOS 15.3.1

Contributor guide

Open the contributing guide

Research direction

The entry point is the aws-lambda-python-alpha Runtime type and its current Python runtime usages. Read those definitions first, then verify that the public TypeScript API can select Python versions without accepting unrelated runtimes and that existing Lambda runtime selection remains supported.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, python, typescript
Domain
cloud, tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.