Failure to setup and build IFC.js project with npm - npm-install

I'm triyng to get acquainted with IFC.js API. Starting from the start, I first tried to setup and build step by step the "hello world" tutorial. Installing the last dependancy failed with the following error message :
npm install #open-wc/building-rollup --save-dev
npm ERR! node_modules/rollup
npm ERR! dev rollup#"^3.10.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer rollup#"^2.11.0" from #open-wc/building-rollup#2.2.1
npm ERR! node_modules/#open-wc/building-rollup
npm ERR! dev #open-wc/building-rollup#"*" 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.
I tried the command again with "--legacy-peer-deps" as suggested, without success. I finally by-passed this step by forcing this installation (--force). Unfortunately, after completing the setup, and as I could have expected, the app doesn't build at the end.
Any help would be warmly welcome !

Related

Fix the upstream dependency conflict tfjs-react-native

I'm trying to install tfjs-react-native for a project that it's also using expo-camera but I get an error.
I followed the instructions on https://www.npmjs.com/package/#tensorflow/tfjs-react-native and installed every dependency, but I fail at the last step which is:
npm install #tensorflow/tfjs-react-native
I'm not able to understand what it's asking me. It seems that tfjs-react-native tries to use expo-camera#7 and I have installed the last one which is 12.3.0. Is that the problem? If so how can I fix this?
Hopefully somebody can help me out. Thanks
While resolving: alpr#1.0.0 npm ERR! Found: expo-camera#12.3.0 npm
ERR! node_modules/expo-camera npm ERR! expo-camera#"~12.3.0" from
the root project npm ERR! npm ERR! Could not resolve dependency: npm
ERR! peer expo-camera#"^7.0.0" from
#tensorflow/tfjs-react-native#0.8.0 npm ERR!
node_modules/#tensorflow/tfjs-react-native npm ERR!
#tensorflow/tfjs-react-native#"^0.8.0" 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.
I solved it using --legacy-peer-deps. Now I was able to install it, my project still don't work but I will post the problem in another question.

Eslint somehow got messed up, Shopware build fails

I have a big problem with the Node.js module eslint within Shopware 6. Out of nowhere I get an error message about a conflicting dependency while building Showpware's storefront and administration:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: eslint-config-airbnb-base#13.2.0
npm ERR! Found: eslint#7.10.0
npm ERR! node_modules/eslint
npm ERR! dev eslint#"7.10.0" from the root project
npm ERR! peer eslint#"^6.0.0 || ^7.0.0 || ^8.0.0" from #typescript-eslint/eslint-plugin#5.1.0
npm ERR! node_modules/#typescript-eslint/eslint-plugin
npm ERR! #typescript-eslint/eslint-plugin#"5.1.0" from the root project
npm ERR! 14 more (#typescript-eslint/experimental-utils, eslint-utils, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint#"^4.19.1 || ^5.3.0" from eslint-config-airbnb-base#13.2.0
npm ERR! node_modules/eslint-config-airbnb-base
npm ERR! dev eslint-config-airbnb-base#"13.2.0" from the root project
npm ERR! eslint-config-airbnb-base#"^13.2.0" from #shopware-ag/eslint-config-base#1.0.0
npm ERR! node_modules/#shopware-ag/eslint-config-base
npm ERR! #shopware-ag/eslint-config-base#"1.0.0" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: eslint#5.16.0
npm ERR! node_modules/eslint
npm ERR! peer eslint#"^4.19.1 || ^5.3.0" from eslint-config-airbnb-base#13.2.0
npm ERR! node_modules/eslint-config-airbnb-base
npm ERR! dev eslint-config-airbnb-base#"13.2.0" from the root project
npm ERR! eslint-config-airbnb-base#"^13.2.0" from #shopware-ag/eslint-config-base#1.0.0
npm ERR! node_modules/#shopware-ag/eslint-config-base
npm ERR! #shopware-ag/eslint-config-base#"1.0.0" 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.
Neither did I manually modify any parts of the Shopware core nor did I install any updates. This error message shows up when I run build.sh. At some point it executes build-js.sh which crashes immediately. This also happened to other Shopware installations we maintain. I also tried to reinstall a broken installation from scratch but after some time it shows the same error message when I start the building process.
All affected installations run with Shopware 6.4.x.x.
Node.js is 16.15.1 LTS, npm is 8.11.0
Any help with this is greatly appreciated!
I remember that this problem existed a while ago. The problem is that Node 16.15.1 bumped the NPM version from 8.5.5 to 8.11.0. This causes the peer dependency problem. However, we fixed this issue in mid-May. So with trunk and the latest 6.4 release, the problem should vanish. If that's not the case, try to fix this by changing npm to a version <8.11.0.

Difficulties install React Native Elements

Attempting to add React Native Elements to my project, but it's not going through.
I used react-native init <ProjectName> to initialize my project, and I attempting to follow up with npm install #rneui/themed #rneui/base, as per the instructions here, but I am given the following sequence of errors:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: undefined#undefined
npm ERR! Found: react-native-safe-area-context#4.3.1
npm ERR! node_modules/react-native-safe-area-context
npm ERR! react-native-safe-area-context#"^4.3.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react-native-safe-area-context#"^3.1.9" from #rneui/base#4.0.0-rc.4
npm ERR! node_modules/#rneui/base
npm ERR! #rneui/base#"^4.0.0-rc.4" 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 C:\Users\Kookeh\AppData\Local\npm-cache\eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Kookeh\AppData\Local\npm-cache\_logs\2022-06-13T20_21_44_602Z-debug-0.log
I am unsure what am I doing wrong, or what steps I can take to remedy the issue. I've been trying to get my project up and running for a few days now, but I keep running into issues like this that have few solutions when I look them up.
That's because NPM installed the latest version of the package and some libraries uses an older version.
You should edit the package.json file of your project.
Go to the file on your react native project and find the line that has the definition of react-native -safe-area-context.
The line should look like this:
"react-native-safe-area-context": "^4.3.1"
And replace the version like this:
"react-native-safe-area-context": "3.1.9"
That worked for me.

I am not able to install npm packages on my vaadin project

happy new year!
Any package that I am trying to install I am getting this:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: #rollup/pluginutils#3.1.0
npm ERR! Found: dev #rollup/plugin-typescript#"^3.0.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! dev #rollup/plugin-typescript#"^3.0.0" 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 ~/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! ~/.npm/_logs/2022-01-02T16_54_42_026Z-debug.log
I am trying to use this npm install --save #fortawesome/fontawesome-free
I don't understand what could be wrong.
as it said in the error, you are handling an old package dependency and therefore you can use --force, or --legacy-peer-deps
Another solution that worked for me, and I think is better, try to install it through pnpm, as it seems to handle it.
I will guess you have decided to update npm itself recently on your local env.
if you run the following (as per your error message), it should install dependencies without trouble.
npm i --legacy-peer-deps
Running npm v8+ to update your dependencies will upgrade the version of your package-lock.json. The issue is that your repo libraries have many old dependencies which might not be compatible with this update. When you run npm with --legacy-peer-deps it uses the old ways...
I have encountered similar problems. After checking, I found that the primary group permission of the node program home directory is 500.500, which needs to be set to root root
Did you try this :
sudo npm install --save #fortawesome/fontawesome-free

npm install package.js - can I revert to earlier package?

I am following this tutorial on vue.js on YouTube. One of the packages I installed was eslint 5.5 (which is the current version). I saw this error message:
npm ERR! Failed at the server#1.0.0 lint script 'eslint **/*.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the server package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! eslint **/*.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs server
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls server
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/jason/Documents/vue-movie/server/npm-debug.log
I tried updating Node and NPM, but that did not change this failure. The tutorial is using "^4.6" and I was wondering if there is a way to revert the package I have to an earlier version? And how would I do that?