tsnobip / resume

résumé generated by react-pdf
4 stars 3 forks source link

Compilation error seems linked to dependencies issues Error: error:0308010C:digital envelope routines::unsupported #2

Open PierreAttard opened 2 years ago

PierreAttard commented 2 years ago

Hi,

On fedora 36, when I'm doing yarn, I got this:

$ yarn
yarn install v1.22.19
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning " > @react-pdf/renderer@2.1.0" has incorrect peer dependency "react@^16.8.6 || ^17.0.0".
warning "@react-pdf/renderer > react-reconciler@0.23.0" has incorrect peer dependency "react@^16.0.0".
warning "webpack-dev-server > http-proxy-middleware@2.0.2" has unmet peer dependency "@types/express@^4.17.13".
[4/4] Building fresh packages...

And when I run yarn dev, I got 10 errors.

Bellow the issue list (I let only the first issue in complete):

ERROR in ./fonts/Libre_Baskerville/LibreBaskerville-Bold.ttf
Module build failed (from ./node_modules/file-loader/dist/cjs.js):
Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:130:10)
    at getHashDigest (/home/pierreattard/Documents/cv/clo/resume/node_modules/file-loader/node_modules/loader-utils/lib/getHashDigest.js:46:34)
    at /home/pierreattard/Documents/cv/clo/resume/node_modules/file-loader/node_modules/loader-utils/lib/interpolateName.js:113:11
    at String.replace (<anonymous>)
    at interpolateName (/home/pierreattard/Documents/cv/clo/resume/node_modules/file-loader/node_modules/loader-utils/lib/interpolateName.js:110:8)
    at Object.loader (/home/pierreattard/Documents/cv/clo/resume/node_modules/file-loader/dist/index.js:29:48)
 @ ./src/Styles.js 10:0-88 42:9-29
 @ ./src/versions/Fr.js 3:0-55 17:11-15 19:11-18 67:11-22
 @ ./src/versions/index.js 2:0-22 3:0-19
 @ ./src/Render.js 3:0-53 6:50-56 9:50-52

ERROR in ./fonts/Libre_Baskerville/LibreBaskerville-Italic.ttf
Module build failed (from ./node_modules/file-loader/dist/cjs.js):
Error: error:0308010C:digital envelope routines::unsupported
    ...

ERROR in ./fonts/Libre_Baskerville/LibreBaskerville-Regular.ttf
Module build failed (from ./node_modules/file-loader/dist/cjs.js):
Error: error:0308010C:digital envelope routines::unsupported
   ...

ERROR in ./fonts/Montserrat/Montserrat-ExtraLight.ttf

ERROR in ./fonts/Montserrat/Montserrat-Regular.ttf

ERROR in ./fonts/Roboto/Roboto-Black.ttf

ERROR in ./fonts/Roboto/Roboto-Bold.ttf

ERROR in ./fonts/Roboto/Roboto-Light.ttf

ERROR in ./fonts/Roboto/Roboto-Regular.ttf

ERROR in ./images/profile_pic_paul.jpg

It seems to be linked with webpack. #14532

webpack 5.67.0 compiled with 10 errors in 5109 ms
webpack://resume/./node_modules/@react-pdf/yoga/src/build/Release/nbind.js?:54
        throw ex;
        ^
(node:89600) [DEP_WEBPACK_COMPILATION_ASSETS] DeprecationWarning: Compilation.assets will be frozen in future, all modifications are deprecated.
BREAKING CHANGE: No more changes should happen to Compilation.assets after sealing the Compilation.
    Do changes to assets earlier, e. g. in Compilation.hooks.processAssets.
    Make sure to select an appropriate stage from Compilation.PROCESS_ASSETS_STAGE_*.
(Use `node --trace-deprecation ...` to show where the warning was created)

My version

FEDORA 36 node -v: v16.15.0 yarn -v: 1.22.19

PierreAttard commented 2 years ago
$ node -v
v14.19.0

With nodejs version 14.19.0, it is working but there is still warnings.

Warning with yarn:

warning " > @react-pdf/renderer@2.1.0" has incorrect peer dependency "react@^16.8.6 || ^17.0.0".
warning "@react-pdf/renderer > react-reconciler@0.23.0" has incorrect peer dependency "react@^16.0.0".
warning "webpack-dev-server > http-proxy-middleware@2.0.2" has unmet peer dependency "@types/express@^4.17.13".

Warning with yarn dev:

(node:100176) [DEP_WEBPACK_COMPILATION_ASSETS] DeprecationWarning: Compilation.assets will be frozen in future, all modifications are deprecated.
BREAKING CHANGE: No more changes should happen to Compilation.assets after sealing the Compilation.
    Do changes to assets earlier, e. g. in Compilation.hooks.processAssets.
    Make sure to select an appropriate stage from Compilation.PROCESS_ASSETS_STAGE_*.
(Use `node --trace-deprecation ...` to show where the warning was created)