# SQLITE3 on NR 1.0 Beta 3

**URL:** <https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442>\
**Category:** General\
**Created:** [11 September 2019 23:29 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442 "2019-09-11T23:29:37Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![scargill](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/scargill/32/1118_2.png) [@scargill](https://discourse.nodered.org/u/scargill)\
**Post date:** [11 September 2019 23:29 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442/1 "2019-09-11T23:29:37Z")

</div>

SQLITE3 installs have always been a pain but at NR 0.20.8 it was just dine. Now, with 1.0 B3, SQLITE failed to install, along with serial and GPIO, the latter 2 just took an install, no problem, SQLITE3 needed an NPN REBUILD as has been advised in the past, and all looked well until tonight I tried to install the latest 1.0 compatible mifnight theme - and when I tried the npm install for the theme, instead, SQLITE 3 started again with the usual failed install, doing npm rebuild sqlite3 returned far too quickly - but suer enough sqlite3 was working - but no theme - I tried installing the theme again - back to square 1, bust SQLITE3.

I have the complete log file but the failure is at the end

npm ERR! code ELIFECYCLE  
npm ERR! errno 1  
npm ERR! sqlite3@4.0.9 install: `node-pre-gyp install --fallback-to-build`  
npm ERR! Exit status 1  
npm ERR!  
npm ERR! Failed at the sqlite3@4.0.9 install script.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [11 September 2019 23:45 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442/2 "2019-09-11T23:45:16Z")

</div>

And what was the exact command line used ?

---

<div class="post-metadata">

**Author:** ![scargill](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/scargill/32/1118_2.png) [@scargill](https://discourse.nodered.org/u/scargill)\
**Post date:** [12 September 2019 00:38 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442/3 "2019-09-12T00:38:04Z")

</div>

Hi Dave

I've given up after many hours (it is 2.10am here) wasted on that SQLITE issue - and gone back to NR 0.20.8 - with my new improved flows (multiple messages) so I'm ready to try again in a day or so. Is there a particular recommendation for upgrading nodejs and npm etc to upgrade to the beta.... clearly the way I did it didn't work well. When I first had issues with SQLITE tonight, in the .node-red directory (as user pi) I tried npm rebuild sqlite as such

node-red-stop  
npm rebuild sqlite3  
node-red-start

That worked in the past - the rebuilt threw out warnings but worked. This time - no warnings, a minute or less - and all looked well (as you know I discovered all about using multiple messages in a flow to stop msg.payload getting overwritten. All was looking really rosy - until I tried installing a dark theme.. in the .node-red folder - it could most likely have been any addition.

npm install node-red-contrib-theme-midnight-red

At which point SQLITE started another failed install etc... I know at least one other user for whom the theme works perfectly - but he isn't using SQLITE... I could not even get the theme installed because of that SQLITE issue.

Ultimately, Nr 1.0 even refused to remove SQLITE - thats when I gave up.

Pete

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [12 September 2019 07:00 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442/4 "2019-09-12T07:00:45Z")

</div>

Pete,  
we know (and have informed the author) that the dark theme is broken - though mainly due to CSS updates to make it more consistent and complete. So yes I would advise against that until it is fixed. Apart from that - if you didn't update the underlying node.js then there should be no need to rebuild sqlite itself. However if you do do it I would ensure you always use the `--unsafe-perm` flag when doing so - (and don't use sudo). Or to be sure `npm i --unsafe-perm node-red-node sqlite@latest`

---

<div class="post-metadata">

**Author:** ![scargill](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/scargill/32/1118_2.png) [@scargill](https://discourse.nodered.org/u/scargill)\
**Post date:** [12 September 2019 11:04 UTC](https://discourse.nodered.org/t/sqlite3-on-nr-1-0-beta-3/15442/5 "2019-09-12T11:04:20Z")

</div>

Hi Dave

This morning I started over from scratch - using NR 0.20.8 as a base.

Here's what I did - and everything works, I hope this is helpful to others...it's all on my blog... however...

```auto
sudo npm install -g –unsafe-perm node-red@next

```

in the palette manager – I installed node-red-node-pi-gpio

```auto
cd ~/.node-red
npm install node-red-contrib-theme-midnight-red@next

```

Editing settings.js (sorry I forgot how to indent coded in here)

```auto
editorTheme: {
    page: {
        css: /home/pi/.node-red/node_modules/node-red-contrib-theme-midnight-red/midnight.css”
    }
}

```

All working.. including the theme... which I find essential - I hate big white screens...

Granted, debug colours are not ideal but I'm sure in time that will be sorted. If I were better at css I'd fix that myself - as it is I don't know where to start... in debug for example, there's a grey "node ID" that is WAY too dark... then again in debug - under msg.payload.object - response object there's a purple and that grey again both of which need lightening up - if anyone wants to tell me what to adjust in that dark theme css file to brighten the text up, that would be really nice.
