99x / 99x/serverless-dynamodb-client
Not compatible with Node 18 on Lambda due to aws-sdk3
- Dominant language
- JavaScript
- Stars
- 74
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
Using this library doesn't seem to play nicely in the Lambda Node 18 runtime.
`{
"errorType": "Runtime.ImportModuleError",
"errorMessage": "Error: Cannot find module 'aws-sdk'\nRequire stack:\n- /var/task/node_modules/serverless-dynamodb-client/index.js\n- /var/task/handlers/profile.js\n- /var/runtime/index.mjs",
"stack": [
"Runtime.ImportModuleError: Error: Cannot find module 'aws-sdk'",
"Require stack:",
"- /var/task/node_modules/serverless-dynamodb-client/index.js",
"- /var/task/handlers/profile.js",
"- /var/runtime/index.mjs",
" at _loadUserApp (file:///var/runtime/index.mjs:1087:17)",
" at async UserFunction.js.module.exports.load (file:///var/runtime/index.mjs:1119:21)",
" at async start (file:///var/runtime/index.mjs:1282:23)",
" at async file:///var/runtime/index.mjs:1288:1"
]
}`
This may need to be adjusted to import DynamoDB in a way that's compatible with aws-sdk v3
https://github.com/aws/aws-sdk-js-v3
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing the aws-sdk import in node_modules/serverless-dynamodb-client/index.js and compare it with the AWS SDK v3 compatibility requirements linked in the issue. Reproduce the Runtime.ImportModuleError in the Lambda Node 18 runtime, then verify that the library loads and accesses DynamoDB without the missing aws-sdk module.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, javascript, node.js
- Domain
- cloud, database
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100