Upgrade failed

In a migration after an “yarn nocobase upgrade” I get a failure report and the app cant connect to databese showing the error message “cant connect to database mantnimentotmb”

* Environment

  • NocoBase version:
  • Database type and version:
  • OS:
  • Deployment Methods:
  • Docker image version:
  • NodeJS version:

* How To Reproduce

Expected behavior

Screenshots

This was the error during migration

At the begining of upgrade command

(node:8664) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead.
(Use node --trace-deprecation ... to show where the warning was created)
2025-02-04 17:27:22 [error] Migration 20240802141435-collection-tree/@nocobase/plugin-collection-tree (up) failed: Original error: Cannot read properties of undefined (reading ‘collectionSchema’)|MigrationError: Migration 20240802141435-collection-tree/@nocobase/plugin-collection-tree (up) failed: Original error: Cannot read properties of undefined (reading ‘collectionSchema’)
at /home/automatizacion/nocobasetmb/node_modules/umzug/lib/umzug.js:170:27
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async Umzug.runCommand (/home/automatizacion/nocobasetmb/node_modules/umzug/lib/umzug.js:126:20)
at async Object.up (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/plugin-manager/plugin-manager.js:965:11)
at async _AsyncEmitter.upgrade (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/application.js:719:5)
at async _AppCommand. (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/commands/upgrade.js:36:5)
at async _AppCommand.parseAsync (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/node_modules/commander/lib/command.js:935:5)
at async _AsyncEmitter.runAsCLI (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/application.js:526:23) reqId=c23c27ee-bfc1-4fa9-8498-6e4223016a6d
2025-02-04 17:27:22 [debug] create database instance: {“sync”:{“alter”:{“drop”:false},“force”:false},“logging”:false,“dialect”:“postgres”,“username”:“nocobasetmb”,“database”:“nocobasetmb”,“port”:“5432”,“timezone”:“+00:00”,“underscored”:false,“migrator”:{“context”:{“app”:{“appName”:“main”,“name”:“main”}}},“logger”:{},“rawTimezone”:“+00:00”} meta={“databaseInstanceId”:“LPJJKucYsjuCYE9gOFgLN”} module=database app=main reqId=d47611e7-3fd0-416f-b4b6-27a5692339e4 dataSourceKey=main
2025-02-04 17:27:22 [info] add app main into supervisor module=application submodule=supervisor method=addApp app=main reqId=d47611e7-3fd0-416f-b4b6-27a5692339e4 dataSourceKey=main
2025-02-04 17:27:22 [info] connection has been established successfully. module=database method=auth app=main reqId=d47611e7-3fd0-416f-b4b6-27a5692339e4 dataSourceKey=main
2025-02-04 17:27:22 [info] upgrading…


At the end of the upgrade command

{
event: ‘migrating’,
name: ‘20240802141435-collection-tree/@nocobase/plugin-collection-tree’
}
2025-02-04 17:27:28 [error] Migration 20240802141435-collection-tree/@nocobase/plugin-collection-tree (up) failed: Original error: Cannot read properties of undefined (reading ‘collectionSchema’) stack=MigrationError: Migration 20240802141435-collection-tree/@nocobase/plugin-collection-tree (up) failed: Original error: Cannot read properties of undefined (reading ‘collectionSchema’)
at (/home/automatizacion/nocobasetmb/node_modules/umzug/src/umzug.ts:261:17)
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async Umzug.runCommand (/home/automatizacion/nocobasetmb/node_modules/umzug/src/umzug.ts:210:14)
at async Object.up (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/plugin-manager/plugin-manager.js:965:11)
at async _AsyncEmitter.upgrade (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/application.js:719:5)
at async _AppCommand. (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/commands/upgrade.js:36:5)
at async _AppCommand.parseAsync (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/node_modules/commander/lib/command.js:935:5)
at async _AsyncEmitter.runAsCLI (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/application.js:526:23) module=application app=main reqId=d47611e7-3fd0-416f-b4b6-27a5692339e4 dataSourceKey=main
2025-02-04 17:27:28 [error] Cannot read properties of undefined (reading ‘collectionSchema’) stack=TypeError: Cannot read properties of undefined (reading ‘collectionSchema’)
at /home/automatizacion/nocobasetmb/node_modules/@nocobase/plugin-collection-tree/dist/server/migrations/20240802141435-collection-tree.js:79:57
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async (/home/automatizacion/nocobasetmb/node_modules/sequelize/src/sequelize.js:1197:18)
at async collection_tree_default.up (/home/automatizacion/nocobasetmb/node_modules/@nocobase/plugin-collection-tree/dist/server/migrations/20240802141435-collection-tree.js:59:5)
at async (/home/automatizacion/nocobasetmb/node_modules/umzug/src/umzug.ts:259:11)
at async Umzug.runCommand (/home/automatizacion/nocobasetmb/node_modules/umzug/src/umzug.ts:210:14)
at async Object.up (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/plugin-manager/plugin-manager.js:965:11)
at async _AsyncEmitter.upgrade (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/application.js:719:5)
at async _AppCommand. (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/lib/commands/upgrade.js:36:5)
at async _AppCommand.parseAsync (/home/automatizacion/nocobasetmb/node_modules/@nocobase/server/node_modules/commander/lib/command.js:935:5) app=main reqId=d47611e7-3fd0-416f-b4b6-27a5692339e4
Done in 90.28s.

I add some infomation and context.

O.S.: ubuntu 24.
Node: 23.4.0
Nocobase:v1.4.15

I have 3 apps running, but only 2 start, third is in error.

The two running apps can use all tables, adding and modifing data.

When I try to start the main app Iget thsi error

When I try to start to maintenance app, the error app, i guet this message

image