-
-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Closed
Description
Description
When migrating one of my projects using two GH tokens (comma-separated), it panics at run time after some minutes. Here are the relevant lines.
2023/12/03 02:57:48 ...ers/web/user/home.go:506:buildIssueOverview() [E] CountIssuesByRepo: context canceled
2023/12/03 03:32:59 ...rvices/pull/check.go:361:testPR() [E] testPatch[<PullRequest [480]static-web-server/static-web-server#46[master...richbayliss/support-try-files]>]: branch does not exist [repo_id: 0 name: richbayliss/support-try-files]
2023/12/03 03:34:16 ...rvices/pull/check.go:361:testPR() [E] testPatch[<PullRequest [536]static-web-server/static-web-server#198[master...wasix-fixes]>]: branch does not exist [repo_id: 0 name: wasix-fixes]
2023/12/03 03:34:16 ...rvices/pull/check.go:361:testPR() [E] testPatch[<PullRequest [522]static-web-server/static-web-server#168[master...dependabot/cargo/tokio-1.23.1]>]: branch does not exist [repo_id: 0 name: dependabot/cargo/tokio-1.23.1]
2023/12/03 03:34:16 ...rvices/pull/check.go:361:testPR() [E] testPatch[<PullRequest [523]static-web-server/static-web-server#170[master...dependabot/cargo/tokio-1.24.2]>]: branch does not exist [repo_id: 0 name: dependabot/cargo/tokio-1.24.2]
2023/12/03 03:34:16 ...rvices/pull/check.go:361:testPR() [E] testPatch[<PullRequest [555]static-web-server/static-web-server#247[master...async-io]>]: branch does not exist [repo_id: 0 name: async-io]
2023/12/03 03:34:59 ...ices/task/migrate.go:48:func1() [E] PANIC during runMigrateTask[125] by DoerID[1] to RepoID[273] for OwnerID[35]: runtime error: index out of range [1] with length 1
Stacktrace: /usr/local/go/src/runtime/panic.go:114 (0x43cc5b)
/go/src/code.gitea.io/gitea/modules/git/diff.go:99 (0xd9328a)
/go/src/code.gitea.io/gitea/services/migrations/gitea_uploader.go:866 (0x2245add)
/go/src/code.gitea.io/gitea/services/migrations/migrate.go:445 (0x225a3e6)
/go/src/code.gitea.io/gitea/services/migrations/migrate.go:130 (0x22585ca)
/go/src/code.gitea.io/gitea/services/task/migrate.go:125 (0x24ee548)
/go/src/code.gitea.io/gitea/services/task/task.go:34 (0x24ef4a4)
/go/src/code.gitea.io/gitea/services/task/task.go:52 (0x24ef73a)
/go/src/code.gitea.io/gitea/modules/queue/workerqueue.go:246 (0x1e35991)
/go/src/code.gitea.io/gitea/modules/queue/workergroup.go:98 (0x1a61d22)
/go/src/code.gitea.io/gitea/modules/queue/workergroup.go:162 (0x1e34269)
/usr/local/go/src/runtime/asm_amd64.s:1650 (0x475860)
2023/12/03 03:34:59 ...ices/task/migrate.go:61:func1() [E] runMigrateTask[125] by DoerID[1] to RepoID[273] for OwnerID[35] failed: PANIC whilst trying to do migrate task: runtime error: index out of range [1] with length 1
2023/12/03 03:34:59 ...ervices/task/task.go:53:handler() [E] Run task failed: PANIC whilst trying to do migrate task: runtime error: index out of range [1] with length 1
See the complete log gists.
It can be related to #25245 but it is not the same problem.
Gitea Version
1.21.1
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
https://gist.github.com/joseluisq/8af3222f4a879acf732adcf6a6f36b81
Screenshots

Git Version
2.40.1
Operating System
Debian Linux 11 x86_64
How are you running Gitea?
On Docker 24.0.7 with Postgres 13
Database
PostgreSQL 13