Upgrade from v1.19.x to v2.0.x failed
-
Hi,
we are trying to upgrade our v1.17.2 instance to the latest version.
Going to v1.19.x worked fine, but v2.0.x caused some major issues.We could resolve most of the issues by:
./nodebb reset -p nodebb-plugin-emoji-extended ./nodebb reset -p nodebb-plugin-emoji-one ./nodebb reset -p nodebb-plugin-custom-file-extensions ./nodebb reset -p nodebb-plugin-composer-redactor ./nodebb activate nodebb-plugin-emoji ./nodebb activate nodebb-plugin-composer-default
But the build still fails with 2 errors:
ERROR in ./build/public/src/modules/jquery.form.min.js.map 1:10 Module parse failed: Unexpected token (1:10) You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
and
ERROR in ./build/public/src/modules/pulling-drawer.js.map 1:10 Module parse failed: Unexpected token (1:10) You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
Full build log: https://logpaste.com/cUN6JKJq
These are the plugins we use:
Active plugins: * [email protected] (installed, disabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, disabled) * [email protected] (installed, enabled) * [email protected] (installed, enabled) * [email protected] (installed, disabled) * [email protected] (installed, enabled) * [email protected] (installed, disabled) * [email protected] (installed, disabled) * [email protected] (installed, enabled)
I already tried to reinstall the pulling module, for example, and manually install all its dev dependencies, but it did not help:
npm install rollup rollup-plugin-typescript rollup-plugin-uglify tslint tslint-config-airbnb typescript uglifyjs
The forum itself works, but none of the links in the admin UI work. There are no errors in the web console - simply nothing happens when you click on a link.
Any help would be greatly appreciated.
PS: we are using Ubuntu 22.04 with Node.js v20.11.1 and NPM 10.2.4.
Thanks and best regards,
Tobi -
maybe you can reset your plugins and try
./nodebb upgrade
again? -
Thank you for the reply.
I already did that. I only forgot to mention, sorry.
Coming from v1.19.x I did:
git fetch git checkout v2.0.x git reset --hard origin/v2.0.x ./nodebb reset -a # I even did reset everything ./nodebb activate nodebb-plugin-composer-default ./nodebb activate nodebb-theme-persona ./nodebb build ./nodebb upgrade
Same two errors. Any other ideas?
Best regards,
Tobi -
Might be better to try going to the last stable version of 2.x which is 2.8.17, also you don't need the
./nodebb build
before./nodebb upgrade
../nodebb upgrade
needs to runnpm install
to upgrade all the dependencies first so the build will probably fail if it runs before that. -
I also did that. That was my very first attempt, lazily going from v1.x -> v2.x -> v3.x.
$ git checkout v2.x Already on 'v2.x' Your branch is up to date with 'origin/v2.x'. $ git reset --hard origin/v2.x HEAD is now at dc14d6a8d1 chore: up version $ ./nodebb reset -a 2024-03-25T20:54:58.360Z [5678/38948] - verbose: [minifier] utilizing a maximum of 7 additional threads 2024-03-25T20:54:58.690Z [5678/38948] - verbose: [plugins] Found 1 less file(s) for plugin nodebb-plugin-composer-default 2024-03-25T20:54:58.691Z [5678/38948] - verbose: [plugins] Found 12 AMD-style module(s) for plugin nodebb-plugin-composer-default 2024-03-25T20:54:58.691Z [5678/38948] - verbose: [plugins] Found 2 js file(s) for plugin nodebb-plugin-composer-default 2024-03-25T20:54:58.692Z [5678/38948] - verbose: [plugins] Loaded plugin: nodebb-plugin-composer-default 2024-03-25T20:54:58.694Z [5678/38948] - verbose: [plugins] Found 3 AMD-style module(s) for plugin nodebb-theme-persona 2024-03-25T20:54:58.694Z [5678/38948] - verbose: [plugins] Found 2 js file(s) for plugin nodebb-theme-persona 2024-03-25T20:54:58.695Z [5678/38948] - verbose: [plugins] Loaded plugin: nodebb-theme-persona 2024-03-25T20:54:58.738Z [5678/38948] - info: [reset] All Widgets moved to Draft Zone 2024-03-25T20:54:58.745Z [5678/38948] - info: [reset] Theme reset to nodebb-theme-persona and default skin 2024-03-25T20:54:58.746Z [5678/38948] - warn: [reset] Plugin `undefined` was not active on this forum 2024-03-25T20:54:58.746Z [5678/38948] - info: [reset] No action taken. 2024-03-25T20:54:58.751Z [5678/38948] - info: [reset] registered-users given login privilege 2024-03-25T20:54:58.751Z [5678/38948] - info: [reset] Settings reset to default 2024-03-25T20:54:58.751Z [5678/38948] - info: [reset] Reset complete. Please run `./nodebb build` to rebuild assets. $ ./nodebb upgrade
Same two errors and all links in the admin backend do not work.
Best regards,
Tobi -
Yes, the errors are still there with v3.x.
I even deleted the
build/
andnode_modules/
directories because I thought there might be outdated files in there. But that didn't help.However, since the MongoDB schema upgrades were successful during the
./nodebb upgrade
runs, I was able to complete the upgrade by doing a fresh git install and copying back the old config.json before running the setup routine. I then manually restored all the static files inpublic/uploads
via rsync.