New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AutoMigrate with Many2Many fails when using UUID for ID #5320
Comments
The issue has been automatically marked as stale as it missing playground pull request link, which is important to help others understand your issue effectively and make sure the issue hasn't been fixed on latest master, checkout https://github.com/go-gorm/playground for details. it will be closed in 30 days if no further activity occurs. if you are asking question, please use the |
|
The issue has been automatically marked as stale as it missing playground pull request link, which is important to help others understand your issue effectively and make sure the issue hasn't been fixed on latest master, checkout https://github.com/go-gorm/playground for details. it will be closed in 30 days if no further activity occurs. if you are asking question, please use the |
|
The issue has been automatically marked as stale as it missing playground pull request link, which is important to help others understand your issue effectively and make sure the issue hasn't been fixed on latest master, checkout https://github.com/go-gorm/playground for details. it will be closed in 30 days if no further activity occurs. if you are asking question, please use the |
I was able to narrow down the problem a bit, UUID can be used if you exclude the tag |
Add
|
@a631807682 @jinzhu I investigated the PR #5322 and tried to do the exact same thing on my side I still get an error like below:
are we sure the issue has been fixed from what I understood primaryKey should be enough to overcome this issue. |
There have been many changes in the latest version, but the tests for this PR did not fail, and the problems you encountered are not necessarily due to it. |
GORM Playground Link
https://github.com/shi-rudo/playground-1
go-gorm/playground#474
for the sake of simplicity I have created a reproduction sample
https://github.com/shi-rudo/gorm-automigrate-many2many-uuid-fail
Description
When I use UUID as type for the gorm ID the automigrator failed at every app start except the first one. With Integer, for example, the restart is without errors.
WITH POSTGRES:
console from reproduction sample:
console from playground:
The text was updated successfully, but these errors were encountered: