Closed
Description
Issue Description
When using Node 17, webpack will fail.
Reproduction
Use Node 17 with ns run
.
Relevant log output (if applicable)
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 BulkUpdateDecorator.hashFactory (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/util/createHash.js:155:18)
at BulkUpdateDecorator.digest (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/util/createHash.js:80:21)
at /Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/DefinePlugin.js:595:38
at Hook.eval [as call] (eval at create (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:19:10), <anonymous>:104:1)
at Hook.CALL_DELEGATE [as _call] (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/node_modules/tapable/lib/Hook.js:14:14)
at Compiler.newCompilation (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:1053:26)
at /Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:1097:29
at Hook.eval [as callAsync] (eval at create (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/node_modules/tapable/lib/Hook.js:18:14)
at Compiler.compile (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:1092:28)
at /Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:517:12
at Compiler.readRecords (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:929:11)
at /Users/rigor789/Code/_tmp/delete/node_modules/webpack/lib/Compiler.js:514:11
at Hook.eval [as callAsync] (eval at create (/Users/rigor789/Code/_tmp/delete/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1) {
opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
library: 'digital envelope routines',
reason: 'unsupported',
code: 'ERR_OSSL_EVP_UNSUPPORTED'
}
Environment
OS: macOS 11.5.1
CPU: (8) x64 Apple M1
Shell: /bin/zsh
node: 17.0.1
npm: 8.1.0
nativescript: 8.1.4
# android
java: 15.0.2
ndk: Not Found
apis: Not Found
build_tools: Not Found
system_images: Not Found
# ios
xcode: 13.0/13A233
cocoapods: 1.11.2
python: 2.7.16
python3: 3.8.9
ruby: 2.6.3
platforms:
- iOS 15.0
- DriverKit 20.4
- macOS 11.3
- tvOS 15.0
- watchOS 8.0
- I have searched the existing issues as well as StackOverflow and this has not been posted before
- This is a bug report
- I agree to follow this project's Code of Conduct