iot-schema-collab / iotschema-node-red

iotschema for Node-RED
8 stars 8 forks source link

i cant install iotschema-node-red/nodes/adaptors/* #6

Open mesh2356 opened 5 years ago

mesh2356 commented 5 years ago

i got kind of error

npm ERR! code ENOLOCAL
npm ERR! Could not install from "iotschema-node-red\nodes\adaptors\*" as it does not contain a package.json file.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\User\AppData\Roaming\npm-cache\_logs\2019-03-16T12_20_36_015Z-debug.log
aparnathuluva commented 5 years ago

This problem occurs when the nodes are installed on Node-RED running on Windows OS. Could you please install the nodes one at a time and check. E.g., cd .node-red npm install \nodes\adaptors\TemperatureUnitConvertor

jdacoello commented 5 years ago

I am using Mac OS, and I have the same problem.

The folder iotschema-node-red/nodes/adaptors/ has not a package.json file with the corresponding specification and dependencies. Any other work-around?

aparnathuluva commented 5 years ago

If installing all adapter nodes using the following command fails: npm install iotschema-node-red/nodes/adaptors/* then could you please install each node individually. For example: npm install iotschema-node-red/nodes/adaptors/DataTypeConvertor npm install iotschema-node-red/nodes/adaptors/Encoder npm install iotschema-node-red/nodes/adaptors/TemperatureUnitConvertor

Installing all the adaptor nodes using * works in Linux (please see below).

image

OpenSourceDevelop commented 4 years ago

Hello, I just tried to install it on a pi3 with the actual rasberian and node-red

npm install iotschema-node-red/nodes/adaptors/* is not working

npm install iotschema-node-red/nodes/adaptors/DataTypeConvertor npm install iotschema-node-red/nodes/adaptors/Encoder npm install iotschema-node-red/nodes/adaptors/TemperatureUnitConvertor also not working

I would love to use my https://iot.mozilla.org/framework/ WebThings as far as I understand I should be useable with you "iotschema-node-red" ?

Do you have some tip?

gokul commented 4 years ago

Hi @OpenSourceDevelop, in order for us to understand the situation better and help you install the nodes, could you please post the errors that you're seeing when you try to install? Thanks!

OpenSourceDevelop commented 4 years ago

sure, also i do not find it in the red-note palette

pi@raspberrypi:~ $ cd ~/.node-red pi@raspberrypi:~/.node-red $ sudo npm install iotschema-node-red/nodes/adaptors/ npm ERR! code ENOLOCAL npm ERR! Could not install from "iotschema-node-red/nodes/adaptors/" as it does not contain a package. json file.

npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2019-11-15T14_15_47_793Z-debug.log

debug: 0 info it worked if it ends with ok 1 verbose cli [ '/usr/bin/node', 1 verbose cli '/usr/bin/npm', 1 verbose cli 'install', 1 verbose cli 'iotschema-node-red/nodes/adaptors/' ] 2 info using npm@6.13.0 3 info using node@v10.17.0 4 verbose npm-session 1f53691fb1a8447f 5 silly install loadCurrentTree 6 silly install readLocalPackageData 7 silly fetchPackageMetaData error for file:iotschema-node-red/nodes/adaptors/ Could not install from "iotschema-node-red/nodes/adaptors/" as it does not contain a package.json file. 8 timing stage:rollbackFailedOptional Completed in 2ms 9 timing stage:runTopLevelLifecycles Completed in 8166ms 10 verbose stack Error: ENOENT: no such file or directory, open '/home/pi/.node-red/iotschema-node-red/nodes/adaptors//package.json' 11 verbose cwd /home/pi/.node-red 12 verbose Linux 4.19.75-v7+ 13 verbose argv "/usr/bin/node" "/usr/bin/npm" "install" "iotschema-node-red/nodes/adaptors/" 14 verbose node v10.17.0 15 verbose npm v6.13.0 16 error code ENOLOCAL 17 error Could not install from "iotschema-node-red/nodes/adaptors/" as it does not contain a package.json file. 18 verbose exit [ 1, true ]

OpenSourceDevelop commented 4 years ago

same problem with:

npm install https://github.com/iot-schema-collab/iotschema-node-red.git

gokul commented 4 years ago

Hi @OpenSourceDevelop, thanks very much for the logs. I think that you're seeing this error because of some confusion with path, could you please follow the below steps and see if it works out?

In the second step, please remember to replace the path with your path.

OpenSourceDevelop commented 4 years ago

could you show how to install with the npm manager? why is it not in the node red palette manager?

or something like this would be good (but the package.json is missing):

sudo git clone https://github.com/iot-schema-collab/iotschema-node-red.git cd iotschema-node-red npm link cd %Node-RED% npm link iotschema-node-red

gokul commented 4 years ago

It cannot be installed yet using the npm package manager directly yet, because these packages have not been pushed to npm registry yet. We're working on converting them to work in that manner.

For your second question, the iotschema-node-red directory itself has no package.json since it's an umbrella project. Please install the nodes under /nodes/adaptors first (there are 3 and they all have a package.json) as per my previous comment. Do let me know if you run into issues.

OpenSourceDevelop commented 4 years ago

It cannot be installed yet using the npm package manager directly yet, because these packages have not been pushed to npm registry yet. We're working on converting them to work in that manner.

great i will try it then. Thank you

gokul commented 4 years ago

No problem. We'll let you know once we've completed this. Meanwhile, I'll close this issue; please reopen if you have concerns.