v0.22 upgrade warnings
Hey! We have just released v0.22.0 🎉
If you self-host you will need to run the below commands to transition to v0.22.0:
GitHub
Release Enhanced Kanban Board and Navigation bars, bulk deletion · ...
What's Changed
Refactor calendar to use new sync statuses and stages by @bosiraphael in #6141
Navigate to field settings page on Go to Settings by @ijreilly in #6128
Fix wrong email direction ...
26 Replies
Congratulations on the release!!
While running sync-metadata I got the following errors (full log in attachment.
and then on the upgrade-0.22 command i get the error
[Nest] 267 - 07/17/2024, 12:51:09 AM LOG [AddNewAddressFieldToViewsWithDeprecatedAddressFieldCommand] Error - missing new Address standard field of type Address, please run workspace-sync-metadata on your workspace (6e278d07-a88a-45d3-86c9-daea30a9b0e5) before running this command
Is this a critical issue and do you suggest I try and fix it? If so, do you have any advice on how i might tackle this?
Thanks!!!!
Hi @Rob thank you!!
About your issue, the issue from the upgrade-0.22 command is not critical at all, but the one in sync-metadata is more annoying.
In our latest version we transitioned the standard field on company "address" to a new "address" composite field that contains subfields such as street, city, state etc. The sync-metadata script is supposed to deprecate the previous version of this field (by renaming it address_old and updating its fieldmetadata value isCustom to true) and introduce the new one (by creating a new address field). Your error indicates that the field with the name "address" already exists; maybe the deprecation of the old address field failed for some reason.
Could you please show me
- what are your pending migrations (metadata > workspace migration > sort by "applied at" desc to get the most recent ones)
- which address field you have in your fieldMetadata (metadata > fieldMetadata > filter by name "address"): the whole row
Thank you for your patience !
Thanks @marie I have attached both info as csv files. Thanks for your assistance!
Thanks @Rob !
Can you confirm you are trying to migrate from to v0.22 from 0.21 and not from an older version ? If not, that could cause issues.
Also, would it be possible for you to dm me a dump of your db so I can try to reproduce locally ?
Thanks @marie . I am upgrading from 0.21 to 0.22 (0.21 seemed to work perfectly for the last few weeks). Sending you the db dump now
Hi @Rob , I started investigating but could not reproduce on my end - I will further investigate tomorrow and keep you posted, thanks for your patience
Thanks @marie please let me know if there is anything I can do/share to make it easier for you. I can also jump on a call if that’s easier for you. Thanks again
Hi @marie! I also got some other errors while following the upgrade commands from 0.21.2 to 0.22.0. Anything known?
Hello @marie and @charles, same for me after updating from 0.21 to 0.22. When I enter:
I get those errors
@greg [iero] @thilles @Rob we are taking a look this morning 🙂
Thanks @charles
@Rob we cannot reproduce the issue with your dump, it's running smoothly on our side, would it be possible to schedule a call to have a look directly on your setup?
Just to make sure, what postgres version are you running? 15.5?
@thilles there is an extra S in your default value FULL_MESSAGES_LIST_FETCH_PENDING. Could you check that:
- on your workspaceSchema, messageChannels table, that the default of the syncStage enum is FULL_MESSAGE_LIST_FETCH_PENDING
- in metadata schema, fieldMetadata where name = syncStage of objectMetadata messageChannels that defaultValue is also FULL_MESSAGE_LIST_FETCH_PENDING
it should be easy to fix, sorry about that we thought that this was not impacting self-hosting
@greg [iero] you seem to have the same problem than @Rob, would be great to schedule a call to troubleshoot
@charles I can jump on a call. Can you do in 20 min from now?
And I am using the docker image " image: twentycrm/twenty-postgres:v0.20.0" for the database. Should I upgrade to v0.22?
@Rob yes we can hop in a call with @marie at 12:00 (in 13 min) it that works for you
we will be in the voice channel
that works!
thanks
@thilles could you also try to run
yarn command:prod migrate-0.22:update-message-channel-sync-stage-enum
@Rob and @greg [iero] issues fixed 🙂Thanks @charles and @marie . Appreciate the help. I am now trying to fix the number of fields issue. I have removed 10 fields and the people page is still not loading. I will continue to try and remove additional fields.
Will try that tonight, thanks!
That's an annoying limitation indeed @Rob. I'll take a look this sprint to see if we can be smarter in the fields we query
Thanks. I have now removed enough fields and it is working. I think it was 12+ fields to deactivate.
Thanks again for the great software
Thanks a lot @marie @charles , I pushed the same correction to my production server and everything is working well
yarn command:prod migrate-0.22:update-message-channel-sync-stage-enum
seemed to sort of work. At least after running sync-metadata
and upgrade-0.22
afterwards, I got the new address field.
Although the FULL_MESSAGES_LIST_FETCH_PENDING naming errors are still present.
Would going from 0.21.2 -> 0.22.1 (instead of 0.22.0) fix this from the start? Currently only playing around in dev env
syncStage enum seems to be default FULL_MESSAGE_LIST_FETCH_PENDING
but in metadata."fieldMetadata" the default is still "'FULL_MESSAGES_LIST_FETCH_PENDING'"
@thilles I think that if you just update the fieldMetadata you should be good to go! (make sure to check the "options" also)
@charles @marie thank you, again, for helping with my upgrade issues. And then helping to identify that I needed to delete fields to reduce below the 100 limit because of the new standard fields added in v0.22.
Just an FYI, I ran in to another problem. All my rest calls started failing even on depth =1. I’ve removed additional fields and changed depth to 0 for now. I will probably move to graphql next to optimise the queries and stay below the 100 limit. I suspect that rest queries might ignore that fields are deactivated.
I just noticed that there is a PR to add further standard fields (created by). Which will mean I need to delete more of my custom fields to ensure the webui works.
I understand that the product is in constant development and you will be adding new features and fields etc. I’m pleased to be an early user and understand that means potential bugs or that I may need to change our workflow over time. Can you provide any rough guidance as to how many custom fields you recommend I use and don’t go above for the next few months (until you switch out the underlying library)?