Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Project wont start at all. #24

Open
MrCaira opened this issue Jul 6, 2022 · 10 comments
Open

Project wont start at all. #24

MrCaira opened this issue Jul 6, 2022 · 10 comments

Comments

@MrCaira
Copy link

MrCaira commented Jul 6, 2022

The project wont work at all for me, using npm start prompts following error on Windows 11.

I freshly installed nodejs less than 1 hour ago, on a clean Windows 11 system. Running node v18.4.0.
Just cloned and did npm install, and have not touched files in between or after at all.

Regular expression denial of service in glob-parent - https://github.com/advisories/GHSA-ww39-953v-wcq6
PS D:\Development\Web Games\canvas-boilerplate> npm start

> [email protected] start
> webpack --config webpack.config.js


webpack is watching the files…

Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:133:10)
    at module.exports (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\util\createHash.js:135:53)
    at NormalModule._initBuildHash (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:417:16)
    at handleParseError (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:471:10)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:503:5
    at D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:358:12
    at D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:373:3
    at iterateNormalLoaders (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:214:10)
    at iterateNormalLoaders (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:221:10)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:236:3
    at runSyncOrAsync (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:130:11)
    at iterateNormalLoaders (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:232:2)
    at Array.<anonymous> (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:205:4)
    at Storage.finished (D:\Development\Web Games\canvas-boilerplate\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:55:16)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:91:9
    at D:\Development\Web Games\canvas-boilerplate\node_modules\graceful-fs\graceful-fs.js:115:16
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3)
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db

Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating
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:133:10)
    at module.exports (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\util\createHash.js:135:53)
    at NormalModule._initBuildHash (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:417:16)
    at handleParseError (D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:471:10)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:503:5
    at D:\Development\Web Games\canvas-boilerplate\node_modules\webpack\lib\NormalModule.js:358:12
    at D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:373:3
    at iterateNormalLoaders (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:214:10)
    at iterateNormalLoaders (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:221:10)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:236:3
    at context.callback (D:\Development\Web Games\canvas-boilerplate\node_modules\loader-runner\lib\LoaderRunner.js:111:13)
    at D:\Development\Web Games\canvas-boilerplate\node_modules\babel-loader\lib\index.js:59:71
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
  library: 'digital envelope routines',
  reason: 'unsupported',
  code: 'ERR_OSSL_EVP_UNSUPPORTED'
}

Node.js v18.4.0
PS D:\Development\Web Games\canvas-boilerplate>
@thomasjvu
Copy link

Use Git Bash
Navigate to the boilerplate directory
Use this command: export NODE_OPTIONS=--openssl-legacy-provider
Then it should work

@yibinjia
Copy link

yibinjia commented Apr 7, 2023

Use Git Bash Navigate to the boilerplate directory Use this command: export NODE_OPTIONS=--openssl-legacy-provider Then it should work

This command is for Linux/mac os, however $env:NODE_OPTIONS = "--openssl-legacy-provider works in windows.

@wasiuddinmansoori1
Copy link

after applying your code its coming like that

image

@thomasjvu
Copy link

after applying your code its coming like that

image

You have to end the quote for "--openssl-legacy-provider"

@wasiuddinmansoori1
Copy link

$env:NODE_OPTIONS = "--openssl-legacy-provider

You Are Great! Thankyou Very Much Brother
Thanks A Lot @thomasjvu

@DivinPrince
Copy link

thanks @thomasjvu

@Z-Hp
Copy link

Z-Hp commented Sep 30, 2023

It's not working for me. I used npm install and then I got this error:

25 packages are looking for funding run npm fund` for details

38 vulnerabilities (8 moderate, 24 high, 6 critical)

To address all issues, run:
npm audit fix

Run npm audit for details.`

@vfa-linhnm
Copy link

@Z-Hp just ignore and start it when i use yarn it alert
info This module is OPTIONAL, you can safely ignore this error

@TheKid7878
Copy link

Strange. It opens up a tab for me saying "localhost:3000", yet the tab refuses to connect. When I inspect, it says
"non-JS module files deprecated". Does this suggest its a network problem?? Then that's weird, because I have totally normal network.

@aravind-virtualTE
Copy link

people should upgrade the packages
"@babel/core": "^7.24.5",
"@babel/preset-env": "^7.24.5",
"babel-loader": "^9.1.3",
"browser-sync": "^2.29.3",
"browser-sync-webpack-plugin": "^2.3.0",
"file-loader": "^6.2.0",
"html-webpack-plugin": "^5.6.0",
"prettier": "^3.2.5",
"webpack": "^5.91.0",
"webpack-cli": "^5.1.4"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants