Error : type "workspace_name.text" does not exist
Not able to add new fields and objects. Can you look into this please? Has anyone else faced this issue?
18 Replies
Hello @nikhil, please provide more information
- Are you selfhosting ?
- If yes what Twenty version ?
- Could you please describe what lead to this error ?
Are you selfhosting ? - Yes
If yes what Twenty version ? - 1.0.1
Could you please describe what lead to this error ? This came after we resolved an error. We made some changes in the metadata table. Not sure though.
@Prastoin
Really struggling with this issue. Please help us out
Hello, please share more information so we can help you
Errors logs from twenty-server etc
Also after what operation is this occurring
Browser console logs and so on
@Prastoin
Need context
@nikhil
We were adding new fields, editing or deleting fields in a custom object. While doing so, we started getting this error randomly after adding few fields. No code change was done.
Now it's not letting us add new fields or objects to the workspace. I have shared the logs as well. Please check and guide on how to proceed.
@Prastoin
Hello @nikhil, were you hitting the API directly or through UI manipulation ?
Could you please share any workspaceMigration with appliedAt set to null in core schema ?
I would highly recommend upgrading to latest twenty version
We've introduced object model transaction to avoid the issue you're I think facing, in 1.1
Hi @prastoin ,
Thank you. We are trying to upgrade it to the latest version now.
However, is there a way where we don't have to delete our objects and fields that we have created every time we do this? Maybe we are not aware of a way. This has a manual effort for us every time.
If you upgrade your twenty instance incrementally you should not face any data loss
Hi,
We are trying to move from 1.0.1 to 1.2.0 now and we have only done one upgrade till now. That was 1.0 to 1.0.1. This resulted in data loss.
Can you please guide us as to what steps to take so that it doesn't result in any loss?
@prastoin
Upgrade between patch isn't required and cannot implies data loss
Are you sure you recovered a backup a 1.0.1 before corrupting your workspace by migration to latest ?
You need to 1.0. -> 1.1 -> 1.2 -> 1.3
Hi @prastoin We recovered a backup while migrating.
Let me illustrate you the issues once: -
1 - We are now not able to create a new field corresponding to any object it gives us this error - type "workspace_1wgvd1injqtife6y4rvfbu3h5.text" does not exist.
2 - We added a new custom object and deactivated it, now we are not able to delete it as well as activate it.
No manual code changes were made
Could you please share your workspace version located within db at core.workspace.version ?
You might have faced a metadata schéma désynchronisation which should not be possible since 1.0.0
But before checking that I want to scope if it's an upgrade issue or not
Thank you for the clarification. I checked the value at core.workspace.version, and it is currently returning null.
Let me know if this might indicate a metadata schema desynchronization or if it's related to a potential upgrade issue.
Are you guys building your own twenty image ?
Workspace version should never be null
Yes, we are building some customizations on top of Twenty Image to better suit our specific use cases. We did notice that the workspace version is coming through as null — could you please suggest a possible solution or guidance on this? We’d appreciate your input.
Please find related topic about how to set APP_VERSION server env variable for your custom twenty image build https://discord.com/channels/1130383047699738754/1372831640920789032
In a nutshell your workspace has never been migrated since its creation
I would recommend downgrading to the very first twenty you started on and re-upgrade between each custom build with a correctly defined and concording APP_VERSION env var value