aws-sdk-js-v3: 3.192.0 introduces breaking change: Cannot find module '@aws-sdk/util-endpoints'

Checkboxes for prior research

Describe the bug

This commit https://github.com/aws/aws-sdk-js-v3/commit/6e4371eade7c2da3e3a930e1a14a52c88af8ad54#diff-2c9b50a7c5201e808afb3f485a693f85389fbeef01b9282a5a31dcd325fffb2aR40 has introduced a breaking change by removing @aws-sdk/util-endpoints. However, the module is still in use in this file https://github.com/aws/aws-sdk-js-v3/commit/6e4371eade7c2da3e3a930e1a14a52c88af8ad54#diff-6ba586ec001f1ef54aa2387edbec307279cb4e6e815c4af3433dc3eb3fa9a095R3

SDK version number

@aws-sdk/client-s3@3.192.0

Which JavaScript Runtime is this issue in?

Node.js

Details of the browser/Node.js/ReactNative version

16.18.0

Reproduction Steps

Just install @aws-sdk/client-s3@3.192.0 and you will be able to reproduce this

Observed Behavior

Breaks

Expected Behavior

Should not break.

Possible Solution

No response

Additional Information/Context

No response

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 59
  • Comments: 31 (3 by maintainers)

Most upvoted comments

Temporary workaround is to install @aws-sdk/util-endpoints manually using npm install @aws-sdk/util-endpoints

Facing same issue as well, +1 on getting fixed soon.

A bit more context:

Error: Cannot find module '@aws-sdk/util-endpoints'
Require stack:
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/endpoint/endpointResolver.js
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.shared.js
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.js
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/S3Client.js
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/S3.js
- /Users/.../node_modules/@aws-sdk/client-s3/dist-cjs/index.js
- /Users/.../project-folder/dist/s3-file/s3-connector.service.js

@thetutlage maybe you want to update the title to something like: “3.192.0 introduces breaking change: Cannot find module ‘@aws-sdk/util-endpoints’”

Already fixed, and will be released with v3.193.0 today. Marking as duplicate.

Check out details in https://github.com/aws/aws-sdk-js-v3/issues/4053

Having the same issue as well.

@trivikr I am having the same error as above . any idea how to fix it?

Attempted import error: 'partitions'.'find' is not exported from './partitions.json' (imported as 'partitions').

#4058 seems to be the fix for it… waiting for the next release to be fixed, I guess. I would encourage a release ASAP if the team is reading this.

This easily fixable when going back to 3.190.0.

For those that never heard this before: posting “same” doesn’t really help contributors. Please provide additional debugging information if possible (although not really needed here). You can also subscribe to the issue and use emoji reactions on the top post to show maintainers the importance of the issue.

In case you have “latest” in your package.json: consider using something like Renovate to update your packages. It will create branches with the updated versions, so you will be notified that something broke before having it on your main branches.

Hi @trivikr thanks for fixing it , but we are still getting these warnings in our builds

image image

I am having the same issue… any update for bellow error

Attempted import error: 'partitions'.'find' is not exported from './partitions.json' (imported as 'partitions').

Hi @trivikr thanks for fixing it , but we are still getting these warnings in our builds

image image

Having the same issue from morning. Hopefully it will be fixed soon.

@trivikr I know pretty much everyone ran into this problem with @aws-sdk/client-s3 — and I too had this come up for me last night on a project, but I had remedied it by installing @aws-sdk/utils-endpoints separately. I just wanted to bring attention to this also being an issue with amazon-chime-sdk-js 3.8.0. Again, I have solved it by just installing utils-endpoints separately. As the merged solution above only mentions client-s3, I thought I’d let you know.

I experienced the same issue in 734 but the above solutions aren’t working for me

“resolutions”: { “@aws-sdk/client-s3”: “3.190.0”, “@aws-sdk/util-endpoints”: “3.190.0” },

Tried this, it did not work for me

Same issue

Same issue

Alternatively, just including the utils module separately works with the latest version of the sdk for example:

"@aws-sdk/client-s3": "^3.192.0",
"@aws-sdk/util-endpoints": "^3.192.0"

Same here!

Same issue

Same issues

Getting the same issue with version 3.192.0

Same issue