zwave-js / node-red-contrib-zwave-js

The most powerful, high performing and highly polished Z-Wave node for Node-RED based on Z-Wave JS. If you want a fully featured Z-Wave framework in your Node-RED instance, you have found it.
MIT License
47 stars 6 forks source link

Fix : node red log crash #19

Closed marcus-j-davies closed 3 years ago

marcus-j-davies commented 3 years ago

Re : https://github.com/zwave-js/node-red-contrib-zwave-js/pull/18

hufftheweevil commented 3 years ago

Yeah, I guess the underlying error is probably more important to fix. I didn't really dig into why it wasn't able to get the serial ports. Have you already found something?

marcus-j-davies commented 3 years ago

one area is permissions (especially with *nix) I think the user running the red process, needs to be apart of the dialout group, but I'm clutching at straws here.

hufftheweevil commented 3 years ago

I just realized that when I first started using this node, that parameter was just a textbox, wasn't it? I wonder if a better approach is to kind of merge those two things together. Use a text box, but also have an option to list serial ports (if it can) and select one to fill in the text box. Or various other UI technics to do the same thing.

marcus-j-davies commented 3 years ago

You can already specify your own, In the drop down choose 'Custom' it will list serial ports - but does allow you to type your own

EDIT The custom option should already act as back up where, the process does not have access to serial ports. so god knows what will happen if the process tries to use it later,

Though - I catch z-wave js error are this point anyway,

Your fix should stop it from dying all together, leaving only the friendlier zwave-js error in the debug window of Red

Also @hufftheweevil you can now push to the dev branch. just add the changes to read me each time - any pushes to the dev branch, that are a result of a bug/enhancement requests, add the Fixed - Not Merged label to said report.

this will allow us to close them after merging into master.

hufftheweevil commented 3 years ago

Yea - the problem was that the whole system would crash immediately upon opening the node's properties.

And will do! thanks!