strapi / strapi

🚀 Strapi is the leading open-source headless CMS. It’s 100% JavaScript/TypeScript, fully customizable, and developer-first.
https://strapi.io
Other
63.48k stars 8.05k forks source link

v4.15.4 Error: Cannot find module 'aws-s3' #18778

Closed franckadil closed 10 months ago

franckadil commented 11 months ago

Bug report

Required System information

Describe the bug

Can't start Strapi with yarn develop

Expected behavior

A clear and concise description of what you expected to happen.

Screenshots

If applicable, add screenshots to help explain your problem.

Code snippets

2023-11-13 18:23:29 Starting your app (with develop)...
2023-11-13 18:23:30 
2023-11-13 18:23:30 [INFO] Including the following ENV variables as part of the JS bundle:
2023-11-13 18:23:30     - ADMIN_PATH
2023-11-13 18:23:30     - STRAPI_ADMIN_BACKEND_URL
2023-11-13 18:23:30     - STRAPI_TELEMETRY_DISABLED
2023-11-13 18:23:43 
││   Error: Cannot find module 'aws-s3'
││   Require stack:                                                            
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-upload/server/register.js 
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-upload/server/index.js 
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-upload/strapi-server.js  
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/utils/dist/index.js   
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/commands/actions/admin/create-user/action.js
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/commands/actions/admin/create-
user/command.js
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/commands/index.js
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/cli.js 
││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/bin/strapi.js
││   at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)
││   at Module._load (node:internal/modules/cjs/loader:922:27)
││   at Module.require (node:internal/modules/cjs/loader:1143:19)
││   at require (node:internal/modules/cjs/helpers:119:18)
││   at createProvider (/usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-upload/server/register.js:53:16)  
││   at module.exports [as register] (/usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-upload/server/register.js:16:38)
││   at Object.register (/usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/core/domain/module/index.js:46:46)
││   at Object.register (/usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/core/registries/modules.js:28:19) 
││   at async Strapi.runLifecyclesFunctions (/usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/Strapi.js:433:5)
││   at async Strapi.register (/usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/Strapi.js:354:5)
││   

Additional context

Since I received a lot of conflicting thoughts about the probability of having a network issue of some sort, I wanted to perform a test in order to share the steps to reproduce this error.

I will use on this test a fresh WSL2 using Ubuntu 22.04 with the same System information indicated above, on a 7th computer based at a friend's home.

I am building a docker image based on node:18.18.2-alpine and installing successful Strapi 4.15.5 without any plugin in order to rule out any system configuration issue or caching conflicts. This will allow the test to run on a containerized environment that have been used with other containers to share a bridged network with Internet access using Google Public DNS.

Docker Build Log:

2023-12-02T18:04:09Z Building in Docker Cloud's infrastructure...
2023-12-02T18:04:09Z Cloning into '.'...
2023-12-02T18:04:10Z Warning: Permanently added the RSA host key for IP address '140.82.114.3' to the list of known hosts.
2023-12-02T18:04:11Z Reset branch 'main'
2023-12-02T18:04:11Z Your branch is up to date with 'origin/main'.
2023-12-02T18:04:11Z Pulling cache layers for index.docker.io/junglewpltd/strapi:latest...
2023-12-02T18:05:54Z Done!
2023-12-02T18:05:54Z KernelVersion: 5.4.0-1068-aws
2023-12-02T18:05:54Z Components: [{u'Version': u'20.10.15', u'Name': u'Engine', u'Details': {u'KernelVersion': u'5.4.0-1068-aws', u'Os': u'linux', u'BuildTime': u'2022-05-05T13:17:24.000000000+00:00', u'ApiVersion': u'1.41', u'MinAPIVersion': u'1.12', u'GitCommit': u'4433bf6', u'Arch': u'amd64', u'Experimental': u'false', u'GoVersion': u'go1.17.9'}}, {u'Version': u'1.6.21', u'Name': u'containerd', u'Details': {u'GitCommit': u'3dce8eb055cbb6872793272b4f20ed16117344f8'}}, {u'Version': u'1.1.7', u'Name': u'runc', u'Details': {u'GitCommit': u'v1.1.7-0-g860f061'}}, {u'Version': u'0.19.0', u'Name': u'docker-init', u'Details': {u'GitCommit': u'de40ad0'}}]
2023-12-02T18:05:54Z Arch: amd64
2023-12-02T18:05:54Z BuildTime: 2022-05-05T13:17:24.000000000+00:00
2023-12-02T18:05:54Z ApiVersion: 1.41
2023-12-02T18:05:54Z Platform: {u'Name': u'Docker Engine - Community'}
2023-12-02T18:05:54Z Version: 20.10.15
2023-12-02T18:05:54Z MinAPIVersion: 1.12
2023-12-02T18:05:54Z GitCommit: 4433bf6
2023-12-02T18:05:54Z Os: linux
2023-12-02T18:05:54Z GoVersion: go1.17.9
2023-12-02T18:05:54Z Buildkit: Starting build for index.docker.io/junglewpltd/strapi:latest...
2023-12-02T18:06:01Z #1 [internal] load build definition from Dockerfile
2023-12-02T18:06:01Z #1 transferring dockerfile: 512B done
2023-12-02T18:06:01Z #1 DONE 0.0s
2023-12-02T18:06:01Z
2023-12-02T18:06:01Z #2 [internal] load .dockerignore
2023-12-02T18:06:01Z #2 transferring context: 2B done
2023-12-02T18:06:01Z #2 DONE 0.0s
2023-12-02T18:06:01Z
2023-12-02T18:06:01Z #3 [auth] library/node:pull token for registry-1.docker.io
2023-12-02T18:06:01Z #3 DONE 0.0s
2023-12-02T18:06:01Z
2023-12-02T18:06:01Z #4 [internal] load metadata for docker.io/library/node:18.18.2-alpine
2023-12-02T18:06:02Z #4 DONE 0.6s
2023-12-02T18:06:02Z
2023-12-02T18:06:02Z #5 importing cache manifest from index.docker.io/junglewpltd/strapi:latest
2023-12-02T18:06:02Z #5 DONE 0.0s
2023-12-02T18:06:02Z
2023-12-02T18:06:02Z #6 [internal] load build context
2023-12-02T18:06:02Z #6 transferring context: 1.30kB done
2023-12-02T18:06:02Z #6 DONE 0.0s
2023-12-02T18:06:02Z
2023-12-02T18:06:02Z #7 [base-alpine 1/1] FROM docker.io/library/node:18.18.2-alpine@sha256:16b46e5ea9fb5c2d13dda36f0feb670fa89de6a412725007555f2eee9a126b60
2023-12-02T18:06:02Z #7 resolve docker.io/library/node:18.18.2-alpine@sha256:16b46e5ea9fb5c2d13dda36f0feb670fa89de6a412725007555f2eee9a126b60 0.0s done
2023-12-02T18:06:02Z #7 sha256:1646380c31566e4d7f020d812298baab2b1b67272ba0281b4f37141393b73f65 7.14kB / 7.14kB done
2023-12-02T18:06:02Z #7 sha256:16b46e5ea9fb5c2d13dda36f0feb670fa89de6a412725007555f2eee9a126b60 1.43kB / 1.43kB done
2023-12-02T18:06:02Z #7 sha256:a2c1bfbc28ede8a10b48fd6889446e04c5c362219fa785633a452d77a1fdd5f1 1.16kB / 1.16kB done
2023-12-02T18:06:02Z #7 DONE 0.2s
2023-12-02T18:06:02Z
2023-12-02T18:06:02Z #8 [stage-1 1/5] RUN yarn global add @strapi/strapi@latest
2023-12-02T18:06:03Z #8 0.788 yarn global v1.22.19
2023-12-02T18:06:03Z #8 0.889 [1/4] Resolving packages...
2023-12-02T18:06:04Z #8 1.999 warning @strapi/strapi > @koa/router@10.1.1: **IMPORTANT 10x+ PERFORMANCE UPGRADE**: Please upgrade to v12.0.1+ as we have fixed an issue with debuglog causing 10x slower router benchmark performance, see https://github.com/koajs/router/pull/173
2023-12-02T18:06:05Z #8 2.755 warning @strapi/strapi > @strapi/types > @koa/router@10.1.1: **IMPORTANT 10x+ PERFORMANCE UPGRADE**: Please upgrade to v12.0.1+ as we have fixed an issue with debuglog causing 10x slower router benchmark performance, see https://github.com/koajs/router/pull/173
2023-12-02T18:06:08Z #8 6.228 warning @strapi/strapi > koa-body > formidable@1.2.6: Please upgrade to latest, formidable@v2 or formidable@v3! Check these notes: https://bit.ly/2ZEqIau
2023-12-02T18:06:11Z #8 8.545 warning @strapi/strapi > @strapi/admin > fork-ts-checker-webpack-plugin > memfs@3.6.0: this will be v4
2023-12-02T18:06:11Z #8 8.546 warning @strapi/strapi > @strapi/admin > webpack-dev-middleware > memfs@3.6.0: this will be v4
2023-12-02T18:06:15Z #8 12.39 warning @strapi/strapi > @strapi/plugin-email > @strapi/provider-email-sendmail > sendmail > mailcomposer@3.12.0: This project is unmaintained
2023-12-02T18:06:15Z #8 13.10 warning @strapi/strapi > @strapi/generators > plop > liftoff > findup-sync > micromatch > snapdragon > source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
2023-12-02T18:06:15Z #8 13.23 warning @strapi/strapi > @strapi/generators > plop > liftoff > findup-sync > micromatch > snapdragon > source-map-resolve > urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
2023-12-02T18:06:15Z #8 13.23 warning @strapi/strapi > @strapi/generators > plop > liftoff > findup-sync > micromatch > snapdragon > source-map-resolve > resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
2023-12-02T18:06:15Z #8 13.23 warning @strapi/strapi > @strapi/generators > plop > liftoff > findup-sync > micromatch > snapdragon > source-map-resolve > source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
2023-12-02T18:06:15Z #8 13.25 warning @strapi/strapi > @strapi/plugin-email > @strapi/provider-email-sendmail > sendmail > mailcomposer > buildmail@3.10.0: This project is unmaintained
2023-12-02T18:06:16Z #8 13.85 [2/4] Fetching packages...
2023-12-02T18:07:30Z #8 87.36 [3/4] Linking dependencies...
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/admin@4.15.5" has incorrect peer dependency "@strapi/data-transfer@4.15.2".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/admin@4.15.5" has unmet peer dependency "react@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/admin@4.15.5" has unmet peer dependency "react-dom@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/admin@4.15.5" has unmet peer dependency "react-router-dom@^5.2.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/admin@4.15.5" has unmet peer dependency "styled-components@^5.2.1".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/plugin-upload@4.15.5" has unmet peer dependency "react@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/plugin-upload@4.15.5" has unmet peer dependency "react-dom@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/plugin-upload@4.15.5" has unmet peer dependency "react-router-dom@^5.2.0".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/plugin-upload@4.15.5" has unmet peer dependency "styled-components@^5.2.1".
2023-12-02T18:07:30Z #8 87.37 warning "@strapi/strapi > @strapi/plugin-email@4.15.5" has unmet peer dependency "react@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-email@4.15.5" has unmet peer dependency "react-dom@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-email@4.15.5" has unmet peer dependency "react-router-dom@^5.2.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-email@4.15.5" has unmet peer dependency "styled-components@^5.2.1".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-content-type-builder@4.15.5" has unmet peer dependency "react@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-content-type-builder@4.15.5" has unmet peer dependency "react-dom@^17.0.0 || ^18.0.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-content-type-builder@4.15.5" has unmet peer dependency "react-router-dom@^5.2.0".
2023-12-02T18:07:30Z #8 87.38 warning "@strapi/strapi > @strapi/plugin-content-type-builder@4.15.5" has unmet peer dependency "styled-components@^5.2.1".
2023-12-02T18:07:30Z #8 87.39 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror@4.21.21" has unmet peer dependency "@babel/runtime@>=7.11.0".
2023-12-02T18:07:30Z #8 87.39 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror@4.21.21" has unmet peer dependency "@codemirror/state@>=6.0.0".
2023-12-02T18:07:30Z #8 87.39 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror@4.21.21" has unmet peer dependency "@codemirror/theme-one-dark@>=6.0.0".
2023-12-02T18:07:30Z #8 87.39 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror@4.21.21" has unmet peer dependency "@codemirror/view@>=6.0.0".
2023-12-02T18:07:30Z #8 87.39 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror@4.21.21" has unmet peer dependency "codemirror@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > @uiw/codemirror-extensions-basic-setup@4.21.21" has unmet peer dependency "@codemirror/autocomplete@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > @uiw/codemirror-extensions-basic-setup@4.21.21" has unmet peer dependency "@codemirror/language@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > @uiw/codemirror-extensions-basic-setup@4.21.21" has unmet peer dependency "@codemirror/lint@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > @uiw/codemirror-extensions-basic-setup@4.21.21" has unmet peer dependency "@codemirror/search@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > @uiw/codemirror-extensions-basic-setup@4.21.21" has unmet peer dependency "@codemirror/view@>=6.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > @strapi/design-system > @uiw/react-codemirror > codemirror > @codemirror/autocomplete@6.11.1" has unmet peer dependency "@lezer/common@^1.0.0".
2023-12-02T18:07:30Z #8 87.40 warning "@strapi/strapi > @strapi/admin > styled-components > babel-plugin-styled-components > @babel/plugin-syntax-jsx@7.23.3" has unmet peer dependency "@babel/core@^7.0.0-0".
2023-12-02T18:08:20Z #8 137.9 [4/4] Building fresh packages...
2023-12-02T18:08:26Z #8 144.0 success Installed "@strapi/strapi@4.15.5" with binaries:
2023-12-02T18:08:26Z #8 144.0 - strapi
2023-12-02T18:08:26Z #8 144.0 Done in 143.27s.
2023-12-02T18:08:27Z #8 DONE 145.2s
2023-12-02T18:08:27Z
2023-12-02T18:08:27Z #9 [stage-1 2/5] RUN mkdir -p /srv/app && chown 1000:1000 -R /srv/app
2023-12-02T18:08:28Z #9 DONE 0.5s
2023-12-02T18:08:28Z
2023-12-02T18:08:28Z #10 [stage-1 3/5] WORKDIR /srv/app
2023-12-02T18:08:28Z #10 DONE 0.1s
2023-12-02T18:08:28Z
2023-12-02T18:08:28Z #11 [stage-1 4/5] COPY docker-entrypoint.sh /usr/local/bin/
2023-12-02T18:08:28Z #11 DONE 0.1s
2023-12-02T18:08:28Z
2023-12-02T18:08:28Z #12 [stage-1 5/5] RUN chmod 777 /usr/local/bin/docker-entrypoint.sh && ln -s /usr/local/bin/docker-entrypoint.sh
2023-12-02T18:08:28Z #12 DONE 0.5s
2023-12-02T18:09:08Z
2023-12-02T18:09:08Z #13 exporting to image
2023-12-02T18:09:08Z #13 exporting layers done
2023-12-02T18:09:08Z #13 writing image sha256:d31099f904c7cf7721aaf0acb96ea64ef147b66b23a041d9ce843d8300c911e7 done
2023-12-02T18:09:08Z #13 naming to docker.io/junglewpltd/strapi:latest done
2023-12-02T18:09:08Z #13 DONE 0.0s
2023-12-02T18:09:08Z
2023-12-02T18:09:08Z #14 exporting cache
2023-12-02T18:09:08Z #14 preparing build cache for export done
2023-12-02T18:09:08Z #14 DONE 0.0s
2023-12-02T18:09:08Z Pushing index.docker.io/junglewpltd/strapi:latest...
2023-12-02T18:11:50Z Done!
2023-12-02T18:11:50Z Build finished

Upon building and starting the Admin interface the containers exit with the following error Error: Cannot find module 'aws-s3' :

Node modules not installed. Installing using yarn ...
2023-12-02 19:42:32 yarn install v1.22.19
2023-12-02 19:42:33 [1/5] Validating package.json...
2023-12-02 19:42:33 [2/5] Resolving packages...
2023-12-02 19:42:33 [3/5] Fetching packages...
2023-12-02 19:42:38 info If you think this is a bug, please open a bug report with the information provided in "/srv/app/yarn-error.log".
2023-12-02 19:42:38 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
2023-12-02 19:43:08 Node modules not installed. Installing using yarn ...
2023-12-02 19:43:08 yarn install v1.22.19
2023-12-02 19:43:08 [1/5] Validating package.json...
2023-12-02 19:43:08 [2/5] Resolving packages...
2023-12-02 19:43:08 [3/5] Fetching packages...
2023-12-02 19:43:10 [4/5] Linking dependencies...
2023-12-02 19:43:24 [5/5] Building fresh packages...
2023-12-02 19:43:25 Done in 17.46s.
2023-12-02 19:43:25 Starting your app (with develop)...
2023-12-02 19:43:27 
2023-12-02 19:43:27 [INFO] Including the following ENV variables as part of the JS bundle:
2023-12-02 19:43:27     - ADMIN_PATH
2023-12-02 19:43:27     - STRAPI_ADMIN_BACKEND_URL
2023-12-02 19:43:27     - STRAPI_TELEMETRY_DISABLED
2023-12-02 19:43:40 ┌──────────────────────────────────────────────────────────────────────────────┐│                                                                              ││   Error: Cannot find module 'aws-s3'                                         ││   Require stack:                                                             ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-uploa   ││   d/server/register.js                                                       ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-uploa   ││   d/server/index.js                                                          ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/plugin-uploa   ││   d/strapi-server.js                                                         ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/utils/dist/i   ││   ndex.js                                                                    ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/   ││   commands/actions/admin/create-user/action.js                               ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/   ││   commands/actions/admin/create-user/command.js                              ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/   ││   commands/index.js                                                          ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/dist/   ││   cli.js                                                                     ││   - /usr/local/share/.config/yarn/global/node_modules/@strapi/strapi/bin/s   ││   trapi.js                                                                   ││   at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)      ││   at Module._load (node:internal/modules/cjs/loader:922:27)                  ││   at Module.require (node:internal/modules/cjs/loader:1143:19)               ││   at require (node:internal/modules/cjs/helpers:119:18)                      ││   at createProvider (/usr/local/share/.config/yarn/global/node_modules/@st   ││   rapi/plugin-upload/server/register.js:53:16)                               ││   at module.exports [as register] (/usr/local/share/.config/yarn/global/no   ││   de_modules/@strapi/plugin-upload/server/register.js:16:38)                 ││   at Object.register (/usr/local/share/.config/yarn/global/node_modules/@s   ││   trapi/strapi/dist/core/domain/module/index.js:46:46)                       ││   at Object.register (/usr/local/share/.config/yarn/global/node_modules/@s   ││   trapi/strapi/dist/core/registries/modules.js:28:19)                        ││   at async Strapi.runLifecyclesFunctions (/usr/local/share/.config/yarn/gl   ││   obal/node_modules/@strapi/strapi/dist/Strapi.js:433:5)                     ││   at async Strapi.register (/usr/local/share/.config/yarn/global/node_modu   ││   les/@strapi/strapi/dist/Strapi.js:354:5)                                   ││                                                                              │└──────────────────────────────────────────────────────────────────────────────┘

Reverting to Strapi 4.14.5 seems to be the only workaround for now.

christiancp100 commented 11 months ago

@franckadil have you executed yarn install before yarn develop? Another possibility is that you've updated only @strapi/strapi and forgot to update @strapi/provider-upload-aws-s3? Because the aws-s3 dependency has been removed.

franckadil commented 11 months ago

@franckadil have you executed yarn install before yarn develop? Another possibility is that you've updated only @strapi/strapi and forgot to update @strapi/provider-upload-aws-s3? Because the aws-s3 dependency has been removed.

Yes I did the usual,yarn install, thenyarn build before yarn develop.

For the record I ran a separate test on my second laptop (Ubuntu 22.04 LTS, Node 18 Latest LTS) I tried the Quick Start Guide and got a similar error the start guide crashed it was complaining about styled-components , unfortunately I wasn't able to take a screen capture or the time to get the logs (I am traveling).

franckadil commented 10 months ago

@christiancp100 Hi Christian, I am back at the office and I tried to give it an other try.

I was able to spot this error: 2023-12-01 15:16:59 error An unexpected error occurred: "https://registry.yarnpkg.com/@strapi/plugin-i18n/-/plugin-i18n-4.15.5.tgz: getaddrinfo EAI_AGAIN registry.yarnpkg.com". It seems like I am unable to get the 'aws-s3' plugin.

derrickmehaffy commented 10 months ago

@christiancp100 Hi Christian, I am back at the office and I tried to give it an other try.

I was able to spot this error: 2023-12-01 15:16:59 error An unexpected error occurred: "https://registry.yarnpkg.com/@strapi/plugin-i18n/-/plugin-i18n-4.15.5.tgz: getaddrinfo EAI_AGAIN registry.yarnpkg.com". It seems like I am unable to get the 'aws-s3' plugin.

That's not a bug with us that's a DNS resolution failure of the yarn registry and I'm guessing an issue with your network.

franckadil commented 10 months ago

@christiancp100 Hi Christian, I am back at the office and I tried to give it an other try. I was able to spot this error: 2023-12-01 15:16:59 error An unexpected error occurred: "https://registry.yarnpkg.com/@strapi/plugin-i18n/-/plugin-i18n-4.15.5.tgz: getaddrinfo EAI_AGAIN registry.yarnpkg.com". It seems like I am unable to get the 'aws-s3' plugin.

That's not a bug with us that's a DNS resolution failure of the yarn registry and I'm guessing an issue with your network.

Tested with YARN and NPM, over Debian and Alpine over 2 different networks, outside our building as well as on AWS and and Google Cloud Compute. And I am still having this issue.

christiancp100 commented 10 months ago

@franckadil I'm sorry we can't help you on our side, but the aws-s3 dependency doesn't exist anymore on 4.15.x. If you have problems with the dependency might be because some caching or node_modules stuff

franckadil commented 10 months ago

@franckadil I'm sorry we can't help you on our side, but the aws-s3 dependency doesn't exist anymore on 4.15.x. If you have problems with the dependency might be because some caching or node_modules stuff

Thank you @christiancp100 for the information, now I am sure I am not crazy. Please can you update the site or communicate to the larger audience that the aws-s3 dependency have been deprecated?

I am using "@strapi/provider-upload-aws-s3": "^4.15.5", I have tested on 5 different machines now just to rule out a local cache or system configuration issue.

derrickmehaffy commented 10 months ago

Your original error wasn't dealing with the aws-s3 package it was with i18n. The error of the address not found is not from us it's your networks inability to resolve an IP address of the yarn registry. We test these regularly (at least 4 or 5 times a week) and I have not seen this issue come up. It's almost certainly a network issue either your on VPN, behind a strict firewall, or your corporate DNS won't resolve the yarn registry address.

If you Google the string: getaddrinfo eai_again from your error you will see the several references to that being a network problem, generally a forward corporate proxy problem.

https://stackoverflow.com/questions/40182121/whats-the-cause-of-the-error-getaddrinfo-eai-again

Specifically the eai_again stems from a DNS lookup timeout.

github-actions[bot] commented 10 months ago

This is a templated message

Hello @franckadil,

Thank you for reporting this bug, however we are unable to reproduce the issue you described given the information we have on hand. Can you please create a fresh project that you are able to reproduce the issue in, provide clear steps to reproduce this issue, and either upload this fresh project to a new GitHub repo or compress it into a .zip and upload it on this issue?

We would greatly appreciate your assistance with this, by working in a fresh project it will cut out any possible variables that might be unrelated. Please note that issues labeled with status: can not reproduce will be closed in 14 days if there is no activity.

Thank you!

franckadil commented 10 months ago

Your original error wasn't dealing with the aws-s3 package it was with i18n. The error of the address not found is not from us it's your networks inability to resolve an IP address of the yarn registry. We test these regularly (at least 4 or 5 times a week) and I have not seen this issue come up. It's almost certainly a network issue either your on VPN, behind a strict firewall, or your corporate DNS won't resolve the yarn registry address.

If you Google the string: getaddrinfo eai_again from your error you will see the several references to that being a network problem, generally a forward corporate proxy problem.

https://stackoverflow.com/questions/40182121/whats-the-cause-of-the-error-getaddrinfo-eai-again

Specifically the eai_again stems from a DNS lookup timeout.

Thank you for your input on the issue. But I am not using a corporate Firewall, private network, and all my tests appart from the ones I ran on Public cloud infrastructure use Google and Cloudflare Global DNS. I have stumbled on the same article since my first step was to check if my containers had access to Internet .

Team members have diligently tested 4.15.5 and they have had the same issue.

I had to revert to 4.14.5 to continue working.

derrickmehaffy commented 10 months ago

I would suggest you try testing in a fresh clean project as it could be a customized yarn config or global config.

derrickmehaffy commented 10 months ago

Here is my attempted reproduction on a fresh v4.15.5 project: https://www.loom.com/share/a93cc4153fad414cbec160b537f5221a?sid=718427cc-a5bd-47a4-bec9-534c77c78584

github-actions[bot] commented 10 months ago

Hello!

As we have not received any new or updated information to reproduce this issue in the last 14 days we are marking this issue as closed. Should you have new information please feel free to respond and we will consider reopening it.

If anyone else have updated information for this issue, please open up a new bug report and simply reference this closed bug report so that we can get any new information you may have. If you have questions please refer to the contributor's guide on opening issues.

Thank you and have a great day!