Version 0.34 migration causing issues on production deployment due to subdomain

Hi, please see https://github.com/twentyhq/twenty/issues/9041 where I have posted a description of an issue I am getting on an operational deployment of Twenty after updating to 0.34. My desired behaviour is that since I have multi workspace disabled, that when I use the base deployment URL, it uses the default workspace. I only need one workspace. Instead it won't let me login claiming user is not a member of the workspace. Help would be appreciated. Thanks.
GitHub
Updated to 0.34 and now cannot login - "You're not member of this w...
Bug Description I updated my instance of twenty 0.33.0 to 0.34.0 and then i cannot login... i used to Example: When trying to login, it say this error "You're not member of this workspace....
2 Replies
thomast
thomast2mo ago
@Weiko
Raph
Raph2mo ago
Hey @ParallelPlatypus I had a similar issue. It stemmed from having multiple workspaces in your DB (probably by accident or through experimentation). You'll need to delete the other workspaces that you're not using. In the comment section in the above github issue you'll see that there are a few queries that are used to remove those workspaces. I also ran into this issue, but also with a foreign key constraint on a user that was used to create the user workspace. In that case I wasn’t able to delete the workspace. If the workspace has a user associated with the workspace you will not be able to delete the workspace. So, obviously you should back up your db before performing any manual queries. After you’ve backed up you can run a pg query like:
DELETE FROM core.user WHERE id IN ('20202020-1c25-4d02-bf25-6aeccf7ea419’)
DELETE FROM core.user WHERE id IN ('20202020-1c25-4d02-bf25-6aeccf7ea419’)
You would need to do this BEFORE running @AMoreaux ’s query to delete the workspace only if a user is associated with it:
DELETE FROM core.workspace WHERE id IN ('20202020-1c25-4d02-bf25-6aeccf7ea419', '3b8e6458-5fc1-4e63-8563-008ccddaa6db')
DELETE FROM core.workspace WHERE id IN ('20202020-1c25-4d02-bf25-6aeccf7ea419', '3b8e6458-5fc1-4e63-8563-008ccddaa6db')

Did you find this page helpful?