Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/core/src/eventSchemas/models/schemaCodeLangs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ export function supportsEventBridgeTemplates(runtime: Runtime): boolean {
'python3.11',
'python3.12',
'python3.13',
'python3.14',
'go1.x',
].includes(runtime)
}
Expand Down
11 changes: 7 additions & 4 deletions packages/core/src/lambda/models/samLambdaRuntime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export type RuntimePackageType = 'Image' | 'Zip'
// TODO: Consolidate all of the runtime constructs into a single <Runtime, Set<Runtime>> map
// We should be able to eliminate a fair amount of redundancy with that.
export const nodeJsRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>([
'nodejs24.x' as Runtime,
'nodejs22.x' as Runtime,
'nodejs20.x',
'nodejs18.x',
Expand All @@ -51,6 +52,7 @@ export function getNodeMajorVersion(version?: string): number | undefined {
}

export const pythonRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>([
'python3.14' as Runtime,
'python3.13' as Runtime,
'python3.12',
'python3.11',
Expand All @@ -66,6 +68,7 @@ export const javaRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>([
'java8',
'java8.al2',
'java21',
'java25' as Runtime,
])
export const dotNetRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>(['dotnet6', 'dotnet8'])
export const rubyRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>(['ruby3.2', 'ruby3.3', 'ruby3.4' as Runtime])
Expand Down Expand Up @@ -94,12 +97,12 @@ export const deprecatedRuntimes: ImmutableSet<Runtime> = ImmutableSet<Runtime>([
'ruby2.7',
])
const defaultRuntimes = ImmutableMap<RuntimeFamily, Runtime>([
[RuntimeFamily.NodeJS, 'nodejs22.x' as Runtime],
[RuntimeFamily.Python, 'python3.13' as Runtime],
[RuntimeFamily.NodeJS, 'nodejs24.x' as Runtime],
[RuntimeFamily.Python, 'python3.14' as Runtime],
[RuntimeFamily.DotNet, 'dotnet8'],
[RuntimeFamily.Go, 'go1.x'],
[RuntimeFamily.Java, 'java21'],
[RuntimeFamily.Ruby, 'ruby3.3'],
[RuntimeFamily.Java, 'java25' as Runtime],
[RuntimeFamily.Ruby, 'ruby3.4' as Runtime],
])

export const mapFamilyToDebugType = ImmutableMap<RuntimeFamily, string>([
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/lambda/remoteDebugging/ldkLayers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const regionToAccount: RegionAccountMapping = {
}

// Global layer version
const globalLayerVersion = 2
const globalLayerVersion = 3

export function getRemoteDebugLayerForArch(region: string, arch: string): string | undefined {
const account = regionToAccount[region]
Expand Down
8 changes: 6 additions & 2 deletions packages/core/src/lambda/vue/remoteInvoke/remoteInvoke.vue
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@
:disabled="
!initialData.runtimeSupportsRemoteDebug ||
!initialData.remoteDebugLayer ||
!initialData.LambdaFunctionNode?.configuration.SnapStart
(!initialData.LambdaFunctionNode?.configuration.SnapStart &&
initialData.LambdaFunctionNode?.configuration.State !== 'Active')
"
class="remote-debug-checkbox"
/>
Expand Down Expand Up @@ -94,7 +95,10 @@
Region {{ initialData.FunctionRegion }} doesn't support remote debugging yet
</info>
<info
v-else-if="!initialData.LambdaFunctionNode?.configuration.SnapStart"
v-else-if="
!initialData.LambdaFunctionNode?.configuration.SnapStart &&
initialData.LambdaFunctionNode?.configuration.State !== 'Active'
"
style="color: var(--vscode-errorForeground)"
>
Doesn't support remote debugging yet
Expand Down
4 changes: 2 additions & 2 deletions packages/core/src/shared/sam/debugger/javaSamDebug.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import { Runtime } from '@aws-sdk/client-lambda'
import { getCodeRoot, isImageLambdaConfig } from '../../../lambda/local/debugConfiguration'
import { RuntimeFamily } from '../../../lambda/models/samLambdaRuntime'
import { ExtContext } from '../../extensions'
Expand Down Expand Up @@ -55,9 +56,8 @@ function getJavaOptionsEnvVar(config: SamLaunchRequestArgs): string {
// https://github.com/aws/aws-sam-cli/blob/86f88cbd7df365960f7015c5d086b0db7aedd9d5/samcli/local/docker/lambda_debug_settings.py#L53
return `-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,quiet=y,address=*:${config.debugPort} -XX:MaxHeapSize=2834432k -XX:MaxMetaspaceSize=163840k -XX:ReservedCodeCacheSize=81920k -XX:+UseSerialGC -XX:-TieredCompilation -Djava.net.preferIPv4Stack=true`
case 'java17':
// https://github.com/aws/aws-sam-cli/blob/90aa5cf11e1c5cbfbe66aea2e2de10d478d48231/samcli/local/docker/lambda_debug_settings.py#L86
return `-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,quiet=y,address=*:${config.debugPort} -XX:MaxHeapSize=2834432k -XX:+UseSerialGC -XX:+TieredCompilation -XX:TieredStopAtLevel=1 -Djava.net.preferIPv4Stack=true`
case 'java21':
case 'java25' as Runtime:
// https://github.com/aws/aws-sam-cli/blob/90aa5cf11e1c5cbfbe66aea2e2de10d478d48231/samcli/local/docker/lambda_debug_settings.py#L96
return `-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,quiet=y,address=*:${config.debugPort} -XX:MaxHeapSize=2834432k -XX:+UseSerialGC -XX:+TieredCompilation -XX:TieredStopAtLevel=1 -Djava.net.preferIPv4Stack=true`
default:
Expand Down
11 changes: 2 additions & 9 deletions packages/core/src/shared/sam/debugger/pythonSamDebug.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,20 +154,13 @@ function getPythonExeAndBootstrap(runtime: Runtime) {
// unfortunately new 'Image'-base images did not standardize the paths
// https://github.com/aws/aws-sam-cli/blob/7d5101a8edeb575b6925f9adecf28f47793c403c/samcli/local/docker/lambda_debug_settings.py
switch (runtime) {
case 'python3.7':
return { python: '/var/lang/bin/python3.7', bootstrap: '/var/runtime/bootstrap' }
case 'python3.8':
return { python: '/var/lang/bin/python3.8', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.9':
return { python: '/var/lang/bin/python3.9', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.10':
return { python: '/var/lang/bin/python3.10', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.11':
return { python: '/var/lang/bin/python3.11', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.12':
return { python: '/var/lang/bin/python3.12', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.13' as Runtime:
return { python: '/var/lang/bin/python3.13', bootstrap: '/var/runtime/bootstrap.py' }
case 'python3.14' as Runtime:
return { python: `/var/lang/bin/${runtime}`, bootstrap: '/var/runtime/bootstrap.py' }
default:
throw new Error(`Python SAM debug logic ran for invalid Python runtime: ${runtime}`)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ describe('getApiValueForSchemasDownload', function () {
case 'python3.11':
case 'python3.12':
case 'python3.13' as Runtime:
case 'python3.14' as Runtime:
case 'python3.10': {
const result = getApiValueForSchemasDownload(runtime)
assert.strictEqual(result, 'Python36', 'Api value used by schemas api')
Expand Down
10 changes: 10 additions & 0 deletions packages/core/src/test/lambda/models/samLambdaRuntime.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,12 @@ describe('runtimes', function () {
'nodejs18.x',
'nodejs20.x',
'nodejs22.x',
'nodejs24.x',
'python3.10',
'python3.11',
'python3.12',
'python3.13',
'python3.14',
'python3.7',
'python3.8',
'python3.9',
Expand All @@ -88,10 +90,12 @@ describe('runtimes', function () {
'nodejs18.x',
'nodejs20.x',
'nodejs22.x',
'nodejs24.x',
'python3.10',
'python3.11',
'python3.12',
'python3.13',
'python3.14',
'python3.7',
'python3.8',
'python3.9',
Expand All @@ -105,17 +109,20 @@ describe('runtimes', function () {
'java11',
'java17',
'java21',
'java25',
'java8',
'java8.al2',
'nodejs14.x',
'nodejs16.x',
'nodejs18.x',
'nodejs20.x',
'nodejs22.x',
'nodejs24.x',
'python3.10',
'python3.11',
'python3.12',
'python3.13',
'python3.14',
'python3.7',
'python3.8',
'python3.9',
Expand All @@ -128,17 +135,20 @@ describe('runtimes', function () {
'java11',
'java17',
'java21',
'java25',
'java8',
'java8.al2',
'nodejs14.x',
'nodejs16.x',
'nodejs18.x',
'nodejs20.x',
'nodejs22.x',
'nodejs24.x',
'python3.10',
'python3.11',
'python3.12',
'python3.13',
'python3.14',
'python3.7',
'python3.8',
'python3.9',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ describe('getSamTemplateWizardOption', function () {
case 'python3.11':
case 'python3.12':
case 'python3.13' as Runtime:
case 'python3.14' as Runtime:
assert.deepStrictEqual(
result,
validPythonTemplateOptions,
Expand Down
Loading
Loading