versatica / tryit-jssip

New tryit-jssip application
https://tryit.jssip.net
Other
88 stars 102 forks source link

npm install failed after upgrade to Debian 11 #27

Open juha-h opened 2 years ago

juha-h commented 2 years ago

I upgraded my host OS from Debian 10 to 11 and noticed that npm install does not anymore succeed. I got

$ npm install
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: tryit-jssip@1.0.3
npm ERR! Found: react@16.14.0
npm ERR! node_modules/react
npm ERR!   react@"^16.13.1" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^15.4.2" from react-addons-css-transition-group@15.6.2
npm ERR! node_modules/react-addons-css-transition-group
npm ERR!   react-addons-css-transition-group@"^15.6.2" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! 
npm ERR! See /home/user/.npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/user/.npm/_logs/2021-11-14T09_29_06_100Z-debug.log

From page https://www.npmjs.com/package/react-addons-css-transition-group I learned that now react-transition-group is recommended as react-addons-css-transition-group replacement. So I went and in package.json replaced line

"react-addons-css-transition-group": "^15.6.2"

with line

"react-transition-group": "^4.4.2"

and in lib/components/TransitionAppear.jsx line

import ReactCSSTransitionGroup from 'react-addons-css-transition-group';

with line

import ReactCSSTransitionGroup from 'react-transition-group';

After that npm install worked (with lots of depreceted warnings):

npm WARN deprecated querystring@0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated core-js@1.2.7: core-js@<3.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Please, upgrade your dependencies to the actual version of core-js.
npm WARN deprecated core-js@2.6.12: core-js@<3.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Please, upgrade your dependencies to the actual version of core-js.
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated browserslist@2.11.3: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated gulp-util@3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
npm WARN deprecated material-ui@0.20.2: You can now upgrade to @material-ui/core

added 1281 packages, and audited 1282 packages in 57s

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

22 vulnerabilities (5 low, 7 moderate, 7 high, 3 critical)

To address issues that do not require attention, run:
  npm audit fix

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.

Then I run gulp prod and got two errors about json file extensions:

/usr/src/orig/tryit-jssip$ gulp prod
[11:45:55] Using gulpfile /usr/src/orig/tryit-jssip/gulpfile.js
[11:45:55] Starting 'prod'...
[11:45:55] Starting 'env:prod'...
[11:45:55] setting "prod" environment
[11:45:55] Finished 'env:prod' after 1.47 ms
[11:45:55] Starting 'clean'...
[11:45:55] Finished 'clean' after 3.54 ms
[11:45:55] Starting 'lint'...
[11:45:56] 
/usr/src/orig/tryit-jssip/gulpfile.js
  45:21  error  Unexpected use of file extension "json" for "./package.json"  import/extensions

/usr/src/orig/tryit-jssip/lib/audioPlayer.js
  3:23  error  Unexpected use of file extension "json" for "./sounds.json"  import/extensions

✖ 2 problems (2 errors, 0 warnings)

[11:45:56] Finished 'lint' after 1.15 s
[11:45:56] Starting 'bundle'...
[11:46:08] Finished 'bundle' after 12 s
[11:46:08] Starting 'html'...
[11:46:08] Finished 'html' after 3.8 ms
[11:46:08] Starting 'css'...
[11:46:08] Finished 'css' after 159 ms
[11:46:08] Starting 'resources'...
[11:46:08] Finished 'resources' after 7.38 ms
[11:46:08] Finished 'prod' after 13 s

I haven't tried to figure out how those errors could be fixed.

juha-h commented 2 years ago

The json errors are produced by lint, so I guess they are not important.

cervajs commented 2 years ago

same problem on centos 9 stream + node.js 16.17

[11:49:02] Starting 'lint'... [11:49:08] /home/noc/tryit-jssip/gulpfile.js 45:21 error Unexpected use of file extension "json" for "./package.json" import/extensions

/home/noc/tryit-jssip/lib/audioPlayer.js 3:23 error Unexpected use of file extension "json" for "./sounds.json" import/extensions

✖ 2 problems (2 errors, 0 warnings)