neo4j / neo4j-browser

Neo4j Browser is the general purpose user interface for working with Neo4j. Query, visualize, administrate and monitor the database.
https://neo4j.com
GNU General Public License v3.0
693 stars 347 forks source link

Error: error:0308010C:digital envelope routines::unsupported #1833

Open notdodo opened 2 years ago

notdodo commented 2 years ago

Description

Following the README building instructions the following error is triggered:

yarn run v1.22.19
$ cross-env NODE_ENV=production webpack-dev-server --colors --config ./build_scripts/webpack.config.js
Error: error:0308010C:digital envelope routines::unsupported
at new Hash (node:internal/crypto/hash:71:19)
at Object.createHash (node:crypto:133:10)
at getHashDigest (/home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/node_modules/loader-utils/lib/getHashDigest.js:46:34)
at /home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/node_modules/loader-utils/lib/interpolateName.js:113:11
at String.replace (<anonymous>)
at Object.interpolateName (/home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/node_modules/loader-utils/lib/interpolateName.js:110:8)
at getWorkerFilename (/home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/out/index.js:41:24)
at /home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/out/index.js:127:77
at Array.map (<anonymous>)
at createLoaderRules (/home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/out/index.js:127:43)
at MonacoEditorWebpackPlugin.apply (/home/edoardo/Desktop/neo4j-browser/node_modules/monaco-editor-webpack-plugin/out/index.js:91:23)
at webpack (/home/edoardo/Desktop/neo4j-browser/node_modules/webpack/lib/webpack.js:51:13)
at startDevServer (/home/edoardo/Desktop/neo4j-browser/node_modules/webpack-dev-server/bin/webpack-dev-server.js:94:16)
at /home/edoardo/Desktop/neo4j-browser/node_modules/webpack-dev-server/bin/webpack-dev-server.js:166:3
at /home/edoardo/Desktop/neo4j-browser/node_modules/webpack-dev-server/lib/utils/processOptions.js:33:9
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Reproduce Steps

to fix the issue export NODE_OPTIONS=--openssl-legacy-provider but this is not mentioned in the instructions nor is a good practice

Expected Behavior

Build is successful

Your Environment

software name version
OS Ubuntu 22.04
node.js v18.10.0
npm 8.19.2
yarn 1.22.19
Neo4j Browser 5.0.0
OskarDamkjaer commented 2 years ago

We're currently use node 16.10.0 and haven't updated to 18 yet. Perhaps we should note that in the readme until we update node :+1:

jdreo commented 1 year ago

I just got the same error from a fresh install of e61b186ca0 on MacOS.

jdreo commented 1 year ago

In case someone would need an easy workaround:

pip install nodeenv
nodeenv --node=16.10.0 env
. env/bin/activate
yarn install
yarn run