Skip to content
This repository was archived by the owner on Aug 3, 2023. It is now read-only.
This repository was archived by the owner on Aug 3, 2023. It is now read-only.

Wrangler is not compatible with Node.js 17 / OpenSSL 3.0 #2108

@EatonZ

Description

@EatonZ

🐛 Bug report

Describe the bug

Node.js 17 was released today and brings OpenSSL 3.0 support. The Node.js 17 release notes mention potential cases where ERR_OSSL_EVP_UNSUPPORTED errors may occur, and that is what is happening here.

Reproduce the bug

  1. Install Node.js 17
  2. Run wrangler publish
  3. See error
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\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\webpack\lib\util\createHash.js:135:53)
    at NormalModule._initBuildHash (C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\webpack\lib\NormalModule.js:417:16)
    at handleParseError (C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\webpack\lib\NormalModule.js:471:10)
    at C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\webpack\lib\NormalModule.js:503:5
    at C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\webpack\lib\NormalModule.js:358:12
    at C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\loader-runner\lib\LoaderRunner.js:373:3
    at iterateNormalLoaders (C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\loader-runner\lib\LoaderRunner.js:214:10)
    at Array.<anonymous> (C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\loader-runner\lib\LoaderRunner.js:205:4)
    at Storage.finished (C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:55:16)
    at C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:91:9
    at C:\Users\Eaton\AppData\Local\.wrangler\wranglerjs-1.19.4\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'
}

Expected behavior

No error should occur, and the publish command should succeed.

Environment and versions

Fill out the following information about your environment.

  • operating system: Windows 10 x64
  • output of wrangler -V: wrangler 1.19.4
  • output of node -v: v17.0.0
  • content of wrangler.toml: (should not be needed in this case)

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions