# Npm update leads to this....... "bluebird"

**URL:** <https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411>\
**Category:** General\
**Created:** [5 January 2019 06:30 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411 "2019-01-05T06:30:54Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 06:30 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/1 "2019-01-05T06:30:55Z")

</div>

After installing a couple of new nodes, I get told there is a new NPM.

I install it as requested and at the end I see this message:

Saying something about permissions.  
What permissions - they are all the same.  
(See second grab)  
Looking into "node-red bluebird" I believe it is system installed.  
So what is the problem with the permissions?

Just wanting to be sure.

![Screenshot%20from%202019-01-05%2017-26-36](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/3/33a1081c8b822b50f64eee2b577fc7b568745169.png)

![Screenshot%20from%202019-01-05%2017-26-27](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/6/637fe3fe0a09ea0b302d0a7fb444963160124981.png)

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [5 January 2019 08:33 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/2 "2019-01-05T08:33:08Z")

</div>

_Exactly_ what command did you run that gave that problem?

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 21:03 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/3 "2019-01-05T21:03:42Z")

</div>

Exactly....... I don't remember. It was now about 12 hours ago and I have since been asleep.

I was updating the nodes and I was being told there is a new version of **npm** , and to **npm audit fix** to fix problems (not going to try and spell vounrebility at this time of the day).

---

<div class="post-metadata">

**Author:** ![ukmoose](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ukmoose/32/13_2.png) [@ukmoose](https://discourse.nodered.org/u/ukmoose)\
**Post date:** [5 January 2019 21:13 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/4 "2019-01-05T21:13:21Z")

</div>

Perhaps this could jog your memory

> **[17 Bash History Command Examples In Linux](https://www.rootusers.com/17-bash-history-command-examples-in-linux/)**
>
> These simple history command examples will show you 17 different ways that you can work with Bash history in Linux.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [5 January 2019 21:19 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/5 "2019-01-05T21:19:32Z")

</div>

> [@Trying\_to\_learn](#):
>
> **npm audit fix** to fix problem

As has been advised here in the past `npm audit fix` is not actually a good thing to do, and it isn't what you said you had done, you said you had installed a new version of npm.

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 21:32 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/6 "2019-01-05T21:32:26Z")

</div>

Colin,

Yes, granted, it isn't what I said was being done, but........

Installing nodes from the web page is painful at best.

So I ssh into the machine, cd .node-red and install them from the cli/terminal.

While doing this npm "complained" and said I am using an old version and there is a new version to get. \*1  
That took me on a slight tangent as I updated it and got it's warnings about old nodes and vounrebilities with existing nodes.  
"to fix these problems do: npm audit fix, or npm audit to look at the problems"

I shall accept my stupidity and just get the problems fixed. Seeing what npm audit says would be beyond me, so it doesn't seem like a smart thing to do.

I did what was stated.  
Somewhere in doing that I got the message about "permission denied with access to bluebird'.  
I posted seeking information on what is/was going on.

\*1  
So (and I will be told again that this has been talked about before. I don't remember.) if when I use npm to install a node and npm says it should be updated....... why is this not a good thing to do?

ukmoose....

Thanks.

from the history command this is about the time when I got the error.  
You can see that I went off to find this "bluebird" and read the readme file.

Though you don't see the replies (obviously) I hope this is enough information to help someone help me understand where the confusion is.

```auto
cd .node-red
npm install node-red-contrib-queue-gate
npm install node-red-contrib-simple-gate
npm install -g npm
exit
cd /usr/lib/node_modules/npm/node_modules/
ld
ll blue*
ls -l blue*
cd bluebird/
lf
cat README.md 
cd ..
ll
exit

```

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [5 January 2019 21:42 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/7 "2019-01-05T21:42:12Z")

</div>

> [@Trying\_to\_learn](#):
>
> Installing nodes from the web page is painful at best.

Why? I've found it a breeze, and less likely for me to get into a mess (ahem!)

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 21:48 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/8 "2019-01-05T21:48:40Z")

</div>

Paul,

Honestly, I don't know.

Maybe it is the recent "Node-red must be restarted" plague which seems to be true for any node updated.  
Though I may be able to do multiple ones on the web page/gui thing, at the end of the day I have to reboot the machine. (Restart NR)  
So if I do it from the CLI, I know which ones have done, they are done one at a time, not all at once, and when done I just reboot the machine.

Scrolling through the list, remembering which one/s are updated, blah blah..... Not fun.  
I open a terminal/CLI, see the ones I want to update, update them and when done reboot/restart.

To me that is a lot easier.

I know I may cop a bit for rebooting rather than simple .....  
(what is the command again?)

```auto
sudo systemctl restart node-red

```

or something?  
A reboot makes sure it is all done. Though have to admit that is painful too. 3 minutes before NR is backup and working.

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [5 January 2019 21:51 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/9 "2019-01-05T21:51:23Z")

</div>

> [@Trying\_to\_learn](#):
>
> Though I may be able to do multiple ones on the web page/gui thing, at the end of the day I have to reboot the machine. (Restart NR)

...which you should do if you update nodes the via the CLI as well...

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 21:55 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/10 "2019-01-05T21:55:26Z")

</div>

Yes, but I am saying from the CLI, I have a "list" of nodes I want to update.  
I do them one at a time, "top to bottom" and they are done.

Via the web page, the list is reset after they are updated and as NR is not restarted I don't see the last one done.

So, I sometimes end up updating the same node many times. (yeah, silly me.)  
To stop that, I do it from the CLI.  
Then when the list is complete, I reboot the machine.

Doing multiple nodes via the web may be ok, but it doesn't really save any time.  
The poor processor is "busting its balls" updating one node, and I go and tell it to update another one too.  
That just doesn't make things smooth.  
I'd rather wait for one to update, then do the other.  
The CLI is a clear indicator of what is going on and where things are.

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [5 January 2019 22:02 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/11 "2019-01-05T22:02:01Z")

</div>

> [@Trying\_to\_learn](#):
>
> The CLI is a clear indicator of what is going on and where things are.

Agreed, it's personal choice, but for you it's opened up a big problem, which wouldn't otherwise have occurred if you'd used the palette manager.  
I hope you get it sorted.

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [5 January 2019 22:09 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/12 "2019-01-05T22:09:54Z")

</div>

Thanks.

I also agree..... Had I not done it this way, I would never have known. But is that a good thing or not?

I'm not saying this is the case, but I have often read that it is when you do unexpected things that you find problems.  
Always going what you are told (with programs in this case) it all works nicely. It is only when you push the limits do you find new things.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [5 January 2019 23:11 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/13 "2019-01-05T23:11:20Z")

</div>

> [@Trying\_to\_learn](#):
>
> So, I sometimes end up updating the same node many times. (yeah, silly me.)

I would expect the `update` button to not be there if you've already updated it but not yet restarted... is that not the case? If so, then that's a bug for us to fix.

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [5 January 2019 23:36 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/14 "2019-01-05T23:36:30Z")

</div>

I can see @Trying_to_learn 's point...

Firstly, you see that a node needs updating, so you click 'update';

![1](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/5/5995131f0a3e25aa85a1162662781098b0e9ec33.png)

Then the node updates;

![2](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/d/d2e59b859a69574fb3c5765b832264f6bd4475dc.png)

...which results in...

![3](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/0/075987a303911ef7e221aa379369b8935bc82730.png)

..which is where we started....

BUT, restarting node-RED, of course clears the update flag.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [5 January 2019 23:43 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/15 "2019-01-05T23:43:21Z")

</div>

Yup, as I said, that's a bug that needs fixing.

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [6 January 2019 02:28 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/16 "2019-01-06T02:28:11Z")

</div>

You are probably right. Just the "tracking" of "who is updated" is not good with the web side of things. MY PROBLEM.

So I decided to reduce the problems I would do it via the CLI.

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [7 January 2019 08:19 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/17 "2019-01-07T08:19:17Z")

</div>

Not to complicate the problem, but more a suggestion:

Ok, so when the node is updated (and NR is not restarted) it is still showing as needing to be updated.

Nick agrees that "it" needs to changed.

As a suggestion to middle ground:

In the list it shows it has an update available. Even after the node is updated.  
When it is updated, rather than saying it **is** updated, mark it as updated **but a restart is needed** in there.  
That way the use is better informed on the state of things.

Just a suggestion.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [7 January 2019 09:27 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/18 "2019-01-07T09:27:16Z")

</div>

> [@Trying\_to\_learn](#):
>
> When it is updated, rather than saying it **is** updated, mark it as updated **but a restart is needed** in there.

Yes, that's exactly the sort of thing I had in mind.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [7 January 2019 15:02 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/19 "2019-01-07T15:02:53Z")

</div>

And sure enough, I found the small typo that was preventing the code I thought I had already written from working properly.

After an update, the entry in the list will refresh to look like this:

 ![Local_Node-RED](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/c/c9e0d409bc19e320f1f65822a040cce69f7aaec7.png)

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [7 January 2019 21:58 UTC](https://discourse.nodered.org/t/npm-update-leads-to-this-bluebird/6411/20 "2019-01-07T21:58:29Z")

</div>

Good to hear!

Thanks.
