Skip to content

Commit

Permalink
Default Node.js runtime is now nodejs20.x
Browse files Browse the repository at this point in the history
Default Python runtime is now `python3.12`
Update deps
  • Loading branch information
ryanblock committed Jan 24, 2024
1 parent e8e348d commit ddc2907
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,23 +21,23 @@
},
"license": "Apache-2.0",
"dependencies": {
"@architect/asap": "~6.1.0-RC.0",
"@architect/asap": "~7.0.0-RC.1",
"@architect/parser": "~6.0.3",
"@architect/utils": "~4.0.0-RC.1",
"@aws-lite/client": "~0.13.4",
"@architect/utils": "~4.0.0-RC.3",
"@aws-lite/client": "~0.14.2",
"@aws-lite/ssm": "~0.2.2",
"lambda-runtimes": "~1.1.7"
"lambda-runtimes": "~2.0.0"
},
"devDependencies": {
"@architect/eslint-config": "~2.1.2",
"cross-env": "~7.0.3",
"dotenv": "~16.3.1",
"dotenv": "~16.4.0",
"eslint": "~8.56.0",
"mock-tmp": "~0.0.2",
"nyc": "~15.1.0",
"proxyquire": "~2.1.3",
"tap-arc": "^1.2.2",
"tape": "^5.7.2"
"tape": "^5.7.3"
},
"eslintConfig": {
"extends": "@architect/eslint-config"
Expand Down
2 changes: 1 addition & 1 deletion src/defaults/function-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = function createDefaultFunctionConfig () {
return {
timeout: 5,
memory: 1152,
runtime: 'nodejs16.x',
runtime: 'nodejs20.x',
architecture: 'x86_64', // TODO [BREAKING]: default to 'arm64'
handler: 'index.handler',
state: 'n/a',
Expand Down
4 changes: 2 additions & 2 deletions test/integration/function-config-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ test('[No global runtime] Inventory and compare functions with / without functio
t.ok(get, 'Inventory returned getter')
let def = inv._project.defaultFunctionConfig
let custom = {
runtime: 'nodejs16.x',
runtime: 'nodejs20.x',
runtimeAlias: 'node',
architecture: 'arm64',
timeout: 10,
Expand Down Expand Up @@ -97,7 +97,7 @@ test('[Global runtime alias] Inventory and compare functions with / without func
Object.keys(custom).forEach(p => {
let setting
if (p === 'views') setting = str(true)
else if (p === 'runtime') setting = str('python3.9')
else if (p === 'runtime') setting = str('python3.12')
else if (p === 'runtimeAlias') setting = str('py')
else setting = str(def[p])
t.equal(str(config[p]), setting, `get /default has correct default ${p} setting: ${str(config[p])}`)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ test('Friendly runtime names (aka aliases)', t => {
let config

config = getRuntimes({ config: c('Node.js'), inventory })
t.match(config.runtime, /nodejs1[02468]\.x/, `Alias mapped to valid AWS Node.js string: ${config.runtime}`)
t.match(config.runtime, /nodejs2[02468]\.x/, `Alias mapped to valid AWS Node.js string: ${config.runtime}`)
t.equal(config.runtimeAlias, 'node.js', `Alias returned lowcase as runtimeAlias: ${config.runtimeAlias}`)

config = getRuntimes({ config: c('Python'), inventory })
Expand Down
4 changes: 2 additions & 2 deletions test/unit/src/config/pragmas/populate-lambda/index-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ custom setting
modified = {
timeout: 10,
memory: 128,
runtime: `nodejs16.x`,
runtime: 'nodejs20.x',
handler: 'index.handler',
custom: 'setting',
}
Expand All @@ -325,7 +325,7 @@ custom setting
modified = {
timeout: 10,
memory: 128,
runtime: `nodejs16.x`,
runtime: 'nodejs20.x',
handler: 'lambda.handler',
custom: 'setting',
}
Expand Down

0 comments on commit ddc2907

Please sign in to comment.