-
Notifications
You must be signed in to change notification settings - Fork 633
Open
Labels
p3This is a minor priority issueThis is a minor priority issuethird-partyThis issue is related to third-party libraries or applications.This issue is related to third-party libraries or applications.
Description
Checkboxes for prior research
- I've gone through Developer Guide and API reference
- I've checked AWS Forums and StackOverflow.
- I've searched for previous similar issues and didn't find any solution.
Describe the bug
When using the latest @aws-sdk/client-s3
with jest, the following error occurs.
TypeError: A dynamic import callback was invoked without --experimental-vm-modules
> 97 | const s3Response = await s3.send(getObjectCommand);
| ^
at node_modules/@aws-sdk/credential-provider-node/dist-cjs/index.js:63:25
at node_modules/@smithy/property-provider/dist-cjs/index.js:50:39
at coalesceProvider (node_modules/@smithy/property-provider/dist-cjs/index.js:76:24)
at node_modules/@smithy/property-provider/dist-cjs/index.js:95:24
at node_modules/@smithy/core/dist-cjs/index.js:62:23
at node_modules/@aws-sdk/middleware-sdk-s3/dist-cjs/index.js:90:20
at node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:33:22
Regression Issue
- Select this option if this issue appears to be a regression.
SDK version number
@aws-sdk/[email protected]
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
Node.js 22
Reproduction Steps
const s3 = tracer.captureAWSv3Client(new S3({}));
const putObjectCommand = new PutObjectCommand({
Bucket: url.hostname,
Key: url.pathname.substring(1),
Body: await fs.readFile(tmpFilePath),
});
const s3Response = await s3.send(putObjectCommand);
Observed Behavior
TypeError
occurs...
Expected Behavior
No errors should occur.
Possible Solution
No response
Additional Information/Context
No response
rbnayax, adijesori, eau-de-la-seine, andrmoel, Angaev and 4 more
Metadata
Metadata
Assignees
Labels
p3This is a minor priority issueThis is a minor priority issuethird-partyThis issue is related to third-party libraries or applications.This issue is related to third-party libraries or applications.