T
Twenty6mo ago
thilles

upgrade from 0.11.2 to 0.12.1

Are there any breaking changes stopping from upgrading 0.11.2 -> 0.12.x When I try the usual routine in dev, i.e. 1. update containers using TAG=0.12.1 2. upgrading core and metadata schemas yarn database:migrate:prod 3. check workspace health yarn command:prod workspace:health -w <workspaceid> the healthcheck finds 5 issues. [Nest] 50 - 05/28/2024, 7:52:38 PM LOG [WorkspaceHealthCommand] Workspace is not healthy, found 5 issues Trying step 4 migrating to the latest version yarn command:prod workspace:sync-metadata -w <workspaceid> -f then failes with some type errors, and finishes with this ` [Nest] 384 - 05/28/2024, 7:51:39 PM ERROR [TransactionNotStartedError] Transaction is not started yet, start transaction before committing or rolling it back. Exception Captured undefined [ TransactionNotStartedError: Transaction is not started yet, start transaction before committing or rolling it back. at PostgresQueryRunner.rollbackTransaction (/app/node_modules/typeorm/driver/postgres/PostgresQueryRunner.js:159:19) at WorkspaceSyncMetadataService.synchronize (/app/packages/twenty-server/dist/src/engine/workspace-manager/workspace-sync-metadata/workspace-sync-metadata.service.js:86:31) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async SyncWorkspaceMetadataCommand.run (/app/packages/twenty-server/dist/src/engine/workspace-manager/workspace-sync-metadata/commands/sync-workspace-metadata.command.js:52:54) at async Command.<anonymous> (/app/node_modules/nest-commander/src/command-runner.service.js:156:24) at async Command.parseAsync (/app/node_modules/commander/lib/command.js:936:5) at async CommandRunnerService.run (/app/node_modules/nest-commander/src/command-runner.service.js:196:9) at async CommandFactory.runApplication (/app/node_modules/nest-commander/src/command.factory.js:37:9) at async bootstrap (/app/packages/twenty-server/dist/src/command/command.js:29:5) ]
No description
2 Replies
charles
charles6mo ago
You have a leftover from an outdated version (previous to 0.11). Could you connect to your database and rename your messageChannel_syncstatus enum to messageChannel_syncStatus (the case is different), then retry to sync-metadata, it should work!
thilles
thillesOP6mo ago
Thanks for the input. From what I can tell it´s already named syncStatus..?
default=# SELECT column_name, data_type
FROM information_schema.columns
WHERE table_schema = 'workspace_29p7xdle6v00po764fzkgp6i3'
AND table_name = 'messageChannel';

column_name | data_type
------------------------------+--------------------------
id | uuid
createdAt | timestamp with time zone
updatedAt | timestamp with time zone
deletedAt | timestamp with time zone
ongoingSyncStartedAt | timestamp with time zone
syncStatus | USER-DEFINED
syncedAt | timestamp with time zone
syncCursor | text
isContactAutoCreationEnabled | boolean
type | USER-DEFINED
connectedAccountId | uuid
handle | text
visibility | USER-DEFINED
isSyncEnabled | boolean
(14 rows)
default=# SELECT column_name, data_type
FROM information_schema.columns
WHERE table_schema = 'workspace_29p7xdle6v00po764fzkgp6i3'
AND table_name = 'messageChannel';

column_name | data_type
------------------------------+--------------------------
id | uuid
createdAt | timestamp with time zone
updatedAt | timestamp with time zone
deletedAt | timestamp with time zone
ongoingSyncStartedAt | timestamp with time zone
syncStatus | USER-DEFINED
syncedAt | timestamp with time zone
syncCursor | text
isContactAutoCreationEnabled | boolean
type | USER-DEFINED
connectedAccountId | uuid
handle | text
visibility | USER-DEFINED
isSyncEnabled | boolean
(14 rows)
nvm, found this https://discord.com/channels/1130383047699738754/1239905691880132719/1239935568758964336 sync-metadata worked! still get some health warnings, but nothing too bad I suppose [Nest] 2971 - 05/30/2024, 8:52:00 PM WARN [SyncWorkspaceMetadataCommand] Workspace contains 4 issues, sync has been forced.
Want results from more Discord servers?
Add your server