nuxt / create-nuxt-app

Create Nuxt.js App in seconds.
MIT License
3.49k stars 429 forks source link

Error debugging after init with yarn create nuxt-app #925

Open kklocker opened 2 years ago

kklocker commented 2 years ago

Environment

Nuxt CLI v3.0.0-27379487.e0cf2d7 23:41:01 RootDir: C:\Users\karll\projects\test\test-nuxt 23:41:02 Nuxt project info: 23:41:02


Reproduction

yarn create nuxt-app test-nuxt yarn create v1.22.17 warning ..\package.json: No license field [1/4] Resolving packages... [2/4] Fetching packages... [3/4] Linking dependencies... [4/4] Building fresh packages... success Installed "create-nuxt-app@4.0.0" with binaries:

create-nuxt-app v4.0.0 ✨ Generating Nuxt.js project in test-nuxt

Describe the bug

yarn dev fails with error message: Error: error:0308010C:digital envelope routines::unsupported

Additional context

No response

Logs

yarn dev
yarn run v1.22.17
warning ..\..\..\package.json: No license field
$ nuxt

   ╭───────────────────────────────────────╮
   │                                       │
   │   Nuxt @ v2.15.8                      │
   │                                       │
   │   ▸ Environment: development          │
   │   ▸ Rendering:   client-side          │
   │   ▸ Target:      server               │
   │                                       │
   │   Listening: http://localhost:3000/   │
   │                                       │
   ╰───────────────────────────────────────╯

i Preparing project for development                                                                           23:35:05
i Initial build may take a while                                                                              23:35:05
i Discovered Components: .nuxt/components/readme.md                                                           23:35:05
√ Builder initialized                                                                                         23:35:05
√ Nuxt files generated                                                                                        23:35:05

* Client █████████████████████████ compiling (0%)

node:internal/crypto/hash:67
  this[kHandle] = new _Hash(algorithm, xofLen);
                  ^

Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:130:10)
    at module.exports (C:\Users\karll\projects\test\test-nuxt\node_modules\webpack\lib\util\createHash.js:135:53)
    at NormalModule._initBuildHash (C:\Users\karll\projects\test\test-nuxt\node_modules\webpack\lib\NormalModule.js:417:16)
    at handleParseError (C:\Users\karll\projects\test\test-nuxt\node_modules\webpack\lib\NormalModule.js:471:10)
    at C:\Users\karll\projects\test\test-nuxt\node_modules\webpack\lib\NormalModule.js:503:5
    at C:\Users\karll\projects\test\test-nuxt\node_modules\webpack\lib\NormalModule.js:358:12
    at C:\Users\karll\projects\test\test-nuxt\node_modules\loader-runner\lib\LoaderRunner.js:373:3
    at iterateNormalLoaders (C:\Users\karll\projects\test\test-nuxt\node_modules\loader-runner\lib\LoaderRunner.js:214:10)
    at Array.<anonymous> (C:\Users\karll\projects\test\test-nuxt\node_modules\loader-runner\lib\LoaderRunner.js:205:4)
    at Storage.finished (C:\Users\karll\projects\test\test-nuxt\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:55:16)
    at C:\Users\karll\projects\test\test-nuxt\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:91:9
    at C:\Users\karll\projects\test\test-nuxt\node_modules\graceful-fs\graceful-fs.js:123:16
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
  opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
  library: 'digital envelope routines',
  reason: 'unsupported',
  code: 'ERR_OSSL_EVP_UNSUPPORTED'
}

Node.js v17.3.0
error Command failed with exit code 1.
gildas commented 2 years ago

This still happens with node 18.12.0 (alas expected)