invalid-score Error occurred during upgrade from 1.13.2 to 1.14.2



  • Hello,

    I am upgrading my nodebb from 1.13.1 to 1.14.2 on a windows PC with the following tools installed:

    • Node: v10.15.3
    • NPM: 6.9.0
    • Mongo: 4.2

    The following is the procedure I am following to upgrade:

    >git fetch
    >git checkout v1.14.x
    >git merge origin/v1.14.x
    
    rem delete my custom plugin links before upgrade
    >rmdir /S /Q   ./node_modules/charter
    >rmdir /S /Q   ./node_modules/customFields
    ...
    
    >nodebb upgrade
    
    rem link back the custom plugins
    >linker.bat
    
    >nodebb build
    >nodebb dev
    

    Unfortunately nodebb upgrade fails after hitting the following error during the upgrade:

    >nodebb upgrade
    
    Updating NodeBB...
    
    1. Updating package.json file with defaults...  OK
    
    2. Bringing base dependencies up to date...  started
    npm WARN nodebb-plugin-emoji-android@2.0.0 requires a peer of nodebb-plugin-emoji@^2.0.0 but none is installed. You must install peer dependencies yourself.
    npm WARN textcomplete.contenteditable@0.1.1 requires a peer of textcomplete@^0.14.2 but none is installed. You must install peer dependencies yourself.
    npm WARN ws@7.2.1 requires a peer of bufferutil@^4.0.1 but none is installed. You must install peer dependencies yourself.
    npm WARN ws@7.2.1 requires a peer of utf-8-validate@^5.0.2 but none is installed. You must install peer dependencies yourself.
    
    audited 1341 packages in 8.521s
    found 34 vulnerabilities (32 low, 2 high)
      run `npm audit fix` to fix them, or `npm audit` for details
    
    3. Checking installed plugins for updates...  OK
    
    4. Updating NodeBB data store schema...
    Parsing upgrade scripts...
    2020-07-31T21:26:46.543Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `semantix`. Skipping.
    2020-07-31T21:26:46.551Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `charter`. Skipping.
    2020-07-31T21:26:46.552Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `customFields`. Skipping.
    2020-07-31T21:26:46.554Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `people`. Skipping.
    2020-07-31T21:26:46.557Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `ratings`. Skipping.
    2020-07-31T21:26:46.558Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `nodebb-plugin-desktop-notifications`. Skipping.
    2020-07-31T21:26:46.559Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `stores`. Skipping.
    2020-07-31T21:26:46.561Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `topics`. Skipping.
    2020-07-31T21:26:46.562Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `cash`. Skipping.
    2020-07-31T21:26:46.563Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `composter`. Skipping.
    2020-07-31T21:26:46.564Z [4567/25544] - warn: [upgrade/appendPluginScripts] Unable to read plugin.json for plugin `nodebb-widget-search-bar`. Skipping.
    OK | 1 script(s) found, 88 skipped 
    
    [              ] (2700/134100) 2% Error occurredent...
    Error occurred during upgrade: Error: [[error:invalid-score, null]]
        at sortedSetAddBulk (d:\nb114\src\database\mongo\sorted\add.js:38:11)
        at module.sortedSetAdd (d:\nb114\src\database\mongo\sorted\add.js:12:17)
        at Object.wrapperCallback [as sortedSetAdd] (d:\nb114\src\promisify.js:50:18)
        at batch.processSortedSet.progress (d:\nb114\src\upgrades\1.14.1\readd_deleted_recent_topics.js:25:13)
        at process._tickCallback (internal/process/next_tick.js:68:7)
    2020-07-31T21:26:48.818Z [4567/25544] - error: uncaughtException: [[error:invalid-score, null]]
    Error: [[error:invalid-score, null]]
        at sortedSetAddBulk (d:\nb114\src\database\mongo\sorted\add.js:38:11)
        at module.sortedSetAdd (d:\nb114\src\database\mongo\sorted\add.js:12:17)
        at Object.wrapperCallback [as sortedSetAdd] (d:\nb114\src\promisify.js:50:18)
        at batch.processSortedSet.progress
    (d:\nb114\src\upgrades\1.14.1\readd_deleted_recent_topics.js:25:13)
        at process._tickCallback (internal/process/next_tick.js:68:7) {"error":{},"stack":"Error: [[error:invalid-score, null]]\n    at sortedSetAddBulk (d:\\nb114\\src\\database\\mongo\\sorted\\add.js:38:11)\n    at module.sortedSetAdd (d:\\nb114\\src\\database\\mongo\\sorted\\add.js:12:17)\n    at Object.wrapperCallback [as sortedSetAdd] (d:\\nb114\\src\\promisify.js:50:18)\n    at batch.processSortedSet.progress (d:\\nb114\\src\\upgrades\\1.14.1\\readd_deleted_recent_topics.js:25:13)\n    at process._tickCallback (internal/process/next_tick.js:68:7)","exception":true,"date":"Fri Jul 31 2020 17:26:48 GMT-0400 (Eastern Daylight Time)","process":{"pid":25544,"uid":null,"gid":null,"cwd":"d:\\nb114","execPath":"C:\\Program Files\\nodejs\\node.exe","version":"v10.15.3","argv":["C:\\Program Files\\nodejs\\node.exe","d:\\nb114\\nodebb","upgrade"],"memoryUsage":{"rss":140382208,"heapTotal":117174272,"heapUsed":88787944,"external":19743471}},"os":{"loadavg":[0,0,0],"uptime":2309923},"trace":[{"column":11,"file":"d:\\nb114\\src\\database\\mongo\\sorted\\add.js","function":"sortedSetAddBulk","line":38,"method":null,"native":false},{"column":17,"file":"d:\\nb114\\src\\database\\mongo\\sorted\\add.js","function":"module.sortedSetAdd","line":12,"method":"sortedSetAdd","native":false},{"column":18,"file":"d:\\nb114\\src\\promisify.js","function":"Object.wrapperCallback [as sortedSetAdd]","line":50,"method":"wrapperCallback [as sortedSetAdd]","native":false},{"column":13,"file":"d:\\nb114\\src\\upgrades\\1.14.1\\readd_deleted_recent_topics.js","function":"batch.processSortedSet.progress","line":25,"method":"progress","native":false},{"column":7,"file":"internal/process/next_tick.js","function":"process._tickCallback","line":68,"method":"_tickCallback","native":false}]}
    

    Let me add that I have successfully upgraded my Ubuntu production server to the latest nodebb running 1.14.2. I still get the same invalid-score message during the startup but is not fatal.

    Please let me know if any other information is needed and as always thank you all for your great work and support. .


  • Admin Staff



  • @baris , it worked. Much appreciated and thanks for helping out. How about the other server that 1.14.2 is installed but the message appears at start up? Should I reinstall?

    Thanks again.


  • Admin Staff

    Is there a stack trace for the startup error?



  • @baris Out of 8 child processes that I start, only the first one shows this error:

    2020-08-01T12:55:32.629Z [4567/12206] - verbose: [plugins] Loaded plugin: ratings
        [              ] (2700/153439) 1% Error occurred
    2020-08-01T12:55:32.676Z [4567/12206] - verbose: [plugins] Loaded plugin: nodebb-plugin-spam-be-gone
    2020-08-01T12:55:32.676Z [4562/12179] - error: Error: [[error:invalid-score, null]]
        at sortedSetAddBulk (/home/nodebb/dt1140/src/database/mongo/sorted/add.js:38:11)
        at module.sortedSetAdd (/home/nodebb/dt1140/src/database/mongo/sorted/add.js:12:17)
        at Object.wrapperCallback [as sortedSetAdd] (/home/nodebb/dt1140/src/promisify.js:50:18)
        at batch.processSortedSet.progress (/home/nodebb/dt1140/src/upgrades/1.14.1/readd_deleted_recent_topics.js:25:13)
        at process._tickCallback (internal/process/next_tick.js:68:7)
    2020-08-01T12:55:32.678Z [4567/12206] - verbose: [plugins] Loaded plugin: ezbase
    2020-08-01T12:55:32.688Z [4567/12206] - verbose: [plugins] Loaded plugin: cash
    2020-08-01T12:55:32.691Z [4567/12206] - verbose: [plugins] Loaded plugin: ezcomposer
    [cluster] Child Process (12179) has exited (code: 0, signal: null)
    
    

    That server was upgraded from 1.14.1 to 1.14.2 and it comes up and it appears that operates normal.

    Thanks again for your time.


  • Admin Staff

    Did you apply the above fix to this server as well? It's sipposed to fix that error.



  • @baris I applied and It also worked on the production server. Thanks again.


Log in to reply
 

Suggested Topics

  • 2
  • 9
  • 3
  • 13
  • 6
| |