mirror of
https://github.com/go-gitea/gitea.git
synced 2025-08-27 11:02:48 +09:00
Change some columns from text to longtext and fix column wrong type caused by xorm (#35141)
Some checks failed
Some checks failed
This PR upgrade xorm to v1.3.10 which fixed a bug when both `longtext json` tags in the struct field. The `longtext` will be ignored and `json` will be considered as `text`. A migration has been introduced to modify the column directly to longtext. And another two columns should also be migrated from text to longtext. All these changes only affect mysql database because for other databases Gitea supported, text is the same as longtext. Fix #27244 Fix #34764 Fix #35042
This commit is contained in:
@ -24,6 +24,7 @@ import (
|
||||
"code.gitea.io/gitea/models/migrations/v1_22"
|
||||
"code.gitea.io/gitea/models/migrations/v1_23"
|
||||
"code.gitea.io/gitea/models/migrations/v1_24"
|
||||
"code.gitea.io/gitea/models/migrations/v1_25"
|
||||
"code.gitea.io/gitea/models/migrations/v1_6"
|
||||
"code.gitea.io/gitea/models/migrations/v1_7"
|
||||
"code.gitea.io/gitea/models/migrations/v1_8"
|
||||
@ -382,6 +383,9 @@ func prepareMigrationTasks() []*migration {
|
||||
newMigration(318, "Add anonymous_access_mode for repo_unit", v1_24.AddRepoUnitAnonymousAccessMode),
|
||||
newMigration(319, "Add ExclusiveOrder to Label table", v1_24.AddExclusiveOrderColumnToLabelTable),
|
||||
newMigration(320, "Migrate two_factor_policy to login_source table", v1_24.MigrateSkipTwoFactor),
|
||||
|
||||
// Gitea 1.24.0 ends at database version 321
|
||||
newMigration(321, "Use LONGTEXT for some columns and fix review_state.updated_files column", v1_25.UseLongTextInSomeColumnsAndFixBugs),
|
||||
}
|
||||
return preparedMigrations
|
||||
}
|
||||
|
Reference in New Issue
Block a user