Closed
Description
Description
When running the drone pipeline either with drone exec
or with a full Drone setup from a repo I reliably experience the following timeout during the migration unit tests.
The closest I've come to identifying something similar is the third issue reported in #19134, but that issue went unreproduced and unresolved (@ArchangeGabriel did you happen to find a fix for this by any chance please?).
Any guidance on how I might go about addressing this would be much appreciated 💙
P.S. Should there be an "n/a" option on being able to repro an issue on try?
2022/11/09 03:25:39 ...s/storage/storage.go:176:initAttachments() [I] Initialising Attachment storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/attachments
2022/11/09 03:25:39 ...s/storage/storage.go:170:initAvatars() [I] Initialising Avatar storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/avatars
2022/11/09 03:25:39 ...s/storage/storage.go:188:initRepoAvatars() [I] Initialising Repository Avatar storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/repo-avatars
2022/11/09 03:25:39 ...s/storage/storage.go:182:initLFS() [I] Initialising LFS storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/lfs
2022/11/09 03:25:39 ...s/storage/storage.go:194:initRepoArchives() [I] Initialising Repository Archive storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/repo-archive
2022/11/09 03:25:39 ...s/storage/storage.go:200:initPackages() [I] Initialising Packages storage with type:
2022/11/09 03:25:39 ...les/storage/local.go:46:NewLocalStorage() [I] Creating new Local Storage at /tmp/appdata260046972/packages
2022/11/09 03:25:41 ...ns/gitea_uploader.go:631:updateGitForPullRequest() [E] Fetch branch from /tmp/repos4255303509/user10/repo8.git failed: exit status 128 - fatal: couldn't find remote ref INVALID
- fatal: couldn't find remote ref INVALID
2022/11/09 03:25:41 ...tea_uploader_test.go:513:func6() [E] >>>>>>>>>>>>>FENCE fork, invalid Head.Ref<<<<<<<<<<<<<<<
2022/11/09 03:25:41 ...ns/gitea_uploader.go:593:updateGitForPullRequest() [E] PR #1 in user2/migrated AddRemote[WRONG] failed: exit status 1 - fatal: 'UNLIKELY' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
error: Could not fetch WRONG
- fatal: 'UNLIKELY' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
error: Could not fetch WRONG
2022/11/09 03:25:41 ...tea_uploader_test.go:513:func6() [E] >>>>>>>>>>>>>FENCE invalid fork CloneURL<<<<<<<<<<<<<<<
2022/11/09 03:25:41 ...ns/gitea_uploader.go:663:updateGitForPullRequest() [W] Empty reference, no pull head for PR #1 in user2/migrated
2022/11/09 03:25:41 ...tea_uploader_test.go:513:func6() [E] >>>>>>>>>>>>>FENCE no fork, empty Head.SHA<<<<<<<<<<<<<<<
2022/11/09 03:25:41 ...ns/gitea_uploader.go:668:updateGitForPullRequest() [W] Deprecated local head brokenSHA for PR #1 in user2/migrated, removing refs/pull/1/head
2022/11/09 03:25:41 ...tea_uploader_test.go:513:func6() [E] >>>>>>>>>>>>>FENCE no fork, invalid Head.SHA<<<<<<<<<<<<<<<
2022/11/09 03:25:41 ...ns/gitea_uploader.go:668:updateGitForPullRequest() [W] Deprecated local head 2697b352310fcd01cbd1f3dbd43b894080027f68 for PR #1 in user2/migrated, removing refs/pull/1/head
2022/11/09 03:25:41 ...tea_uploader_test.go:513:func6() [E] >>>>>>>>>>>>>FENCE no fork, not found Head.SHA<<<<<<<<<<<<<<<
coverage: 12.3% of statements
panic: test timed out after 20m0s
goroutine 295 [running]:
testing.(*M).startAlarm.func1()
/usr/local/go/src/testing/testing.go:2036 +0xbb
created by time.goFunc
/usr/local/go/src/time/sleep.go:176 +0x48
goroutine 1 [chan receive, 19 minutes]:
testing.(*T).Run(0xc00032c000, {0x2a48db9, 0x16}, 0x2c6ae58)
/usr/local/go/src/testing/testing.go:1494 +0x789
testing.runTests.func1(0x0?)
/usr/local/go/src/testing/testing.go:1846 +0x9a
testing.tRunner(0xc00032c000, 0xc002e2f500)
/usr/local/go/src/testing/testing.go:1446 +0x217
testing.runTests(0xc001de60a0?, {0x63fda00, 0xd, 0xd}, {0xc002e2f598?, 0x45b6d1?, 0x65c1960?})
/usr/local/go/src/testing/testing.go:1844 +0x7ed
testing.(*M).Run(0xc001de60a0)
/usr/local/go/src/testing/testing.go:1726 +0xa85
code.gitea.io/gitea/models/unittest.MainTest(0xc001635de8?, 0xc002dede08)
/drone/src/models/unittest/testdb.go:153 +0x1385
code.gitea.io/gitea/services/migrations.TestMain(0x6497d00?)
/drone/src/services/migrations/main_test.go:20 +0x9c
main.main()
_testmain.go:151 +0x405
goroutine 6 [select, 19 minutes]:
code.gitea.io/gitea/modules/log.(*ChannelledLog).Start(0xc0003b2230)
/drone/src/modules/log/event.go:80 +0x1c5
created by code.gitea.io/gitea/modules/log.NewChannelledLog
/drone/src/modules/log/event.go:69 +0x64a
goroutine 7 [select, 19 minutes]:
code.gitea.io/gitea/modules/log.(*MultiChannelledLog).Start(0xc00038f950)
/drone/src/modules/log/event.go:341 +0x489
created by code.gitea.io/gitea/modules/log.(*MultiChannelledLog).AddLogger
/drone/src/modules/log/event.go:222 +0x2a7
goroutine 20 [select, 20 minutes]:
github.com/blevesearch/bleve_index_api.AnalysisWorker({0xc001d8db00?, 0xc001d8db60?})
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:46 +0xc6
created by github.com/blevesearch/bleve_index_api.NewAnalysisQueue
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:38 +0xba
goroutine 21 [select, 20 minutes]:
github.com/blevesearch/bleve_index_api.AnalysisWorker({0xc001d8db00?, 0xc001d8db60?})
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:46 +0xc6
created by github.com/blevesearch/bleve_index_api.NewAnalysisQueue
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:38 +0xba
goroutine 22 [select, 20 minutes]:
github.com/blevesearch/bleve_index_api.AnalysisWorker({0xc001d8db00?, 0xc001d8db60?})
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:46 +0xc6
created by github.com/blevesearch/bleve_index_api.NewAnalysisQueue
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:38 +0xba
goroutine 23 [select, 20 minutes]:
github.com/blevesearch/bleve_index_api.AnalysisWorker({0xc001d8db00?, 0xc001d8db60?})
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:46 +0xc6
created by github.com/blevesearch/bleve_index_api.NewAnalysisQueue
/go/pkg/mod/github.com/blevesearch/[email protected]/analysis.go:38 +0xba
goroutine 24 [select, 20 minutes]:
database/sql.(*DB).connectionOpener(0xc001d9eb60, {0x51eddf8, 0xc001dfa040})
/usr/local/go/src/database/sql/sql.go:1224 +0xf3
created by database/sql.OpenDB
/usr/local/go/src/database/sql/sql.go:792 +0x30d
goroutine 240 [select, 19 minutes]:
code.gitea.io/gitea/services/migrations.(*GithubDownloaderV3).waitAndPickClient(0xc0000d2840)
/drone/src/services/migrations/github.go:165 +0x590
code.gitea.io/gitea/services/migrations.(*GithubDownloaderV3).GetReviews(0xc0000d2840, {0x51e6b70, 0xc00174f600})
/drone/src/services/migrations/github.go:818 +0x1fb
code.gitea.io/gitea/services/migrations.TestGitHubDownloadRepo(0xc0000fbd40?)
/drone/src/services/migrations/github_test.go:370 +0x3e5b
testing.tRunner(0xc0000fbd40, 0x2c6ae58)
/usr/local/go/src/testing/testing.go:1446 +0x217
created by testing.(*T).Run
/usr/local/go/src/testing/testing.go:1493 +0x75e
goroutine 228 [chan receive, 15 minutes]:
os/exec.(*Cmd).Wait(0xc0010c6000)
/usr/local/go/src/os/exec/exec.go:608 +0x3a5
code.gitea.io/gitea/modules/git.(*Command).Run(0xc0004d4000, 0xc001e10f60)
/drone/src/modules/git/command.go:271 +0xe6a
code.gitea.io/gitea/modules/git.CatFileBatchCheck.func3()
/drone/src/modules/git/batch_reader.go:73 +0x6ff
created by code.gitea.io/gitea/modules/git.CatFileBatchCheck
/drone/src/modules/git/batch_reader.go:69 +0x966
goroutine 227 [chan receive, 19 minutes]:
code.gitea.io/gitea/modules/git.CatFileBatchCheck.func2()
/drone/src/modules/git/batch_reader.go:62 +0x50
created by code.gitea.io/gitea/modules/git.CatFileBatchCheck
/drone/src/modules/git/batch_reader.go:61 +0x6a6
goroutine 125 [chan send, 15 minutes]:
os/exec.(*Cmd).watchCtx.func1()
/usr/local/go/src/os/exec/exec.go:665 +0x277
created by os/exec.(*Cmd).watchCtx
/usr/local/go/src/os/exec/exec.go:647 +0x10f
goroutine 122 [select, 19 minutes]:
io.(*pipe).read(0xc001a12240, {0xc002d38000, 0x8000, 0x8000?})
/usr/local/go/src/io/pipe.go:57 +0x151
io.(*PipeReader).Read(0xc000014d28, {0xc002d38000, 0x8000, 0x8000})
/usr/local/go/src/io/pipe.go:136 +0x65
io.copyBuffer({0x51e5fa0, 0xc001b341d0}, {0x51e3cc0, 0xc000014d28}, {0x0, 0x0, 0x0})
/usr/local/go/src/io/io.go:427 +0x28e
io.Copy(...)
/usr/local/go/src/io/io.go:386
os.genericReadFrom(0xc0010c4018?, {0x51e3cc0?, 0xc000014d28?})
/usr/local/go/src/os/file.go:161 +0x89
os.(*File).ReadFrom(0xc0010c4018, {0x51e3cc0, 0xc000014d28})
/usr/local/go/src/os/file.go:155 +0x325
io.copyBuffer({0x51e42e0, 0xc0010c4018}, {0x51e3cc0, 0xc000014d28}, {0x0, 0x0, 0x0})
/usr/local/go/src/io/io.go:413 +0x1c6
io.Copy(...)
/usr/local/go/src/io/io.go:386
os/exec.(*Cmd).stdin.func1()
/usr/local/go/src/os/exec/exec.go:362 +0x85
os/exec.(*Cmd).Start.func1(0xc001a66018)
/usr/local/go/src/os/exec/exec.go:544 +0x36
created by os/exec.(*Cmd).Start
/usr/local/go/src/os/exec/exec.go:543 +0xd75
goroutine 225 [chan receive, 19 minutes]:
code.gitea.io/gitea/modules/git.CatFileBatch.func2()
/drone/src/modules/git/batch_reader.go:112 +0x50
created by code.gitea.io/gitea/modules/git.CatFileBatch
/drone/src/modules/git/batch_reader.go:111 +0x786
goroutine 226 [chan receive, 15 minutes]:
os/exec.(*Cmd).Wait(0xc001f5db80)
/usr/local/go/src/os/exec/exec.go:608 +0x3a5
code.gitea.io/gitea/modules/git.(*Command).Run(0xc00056c540, 0xc002beaf60)
/drone/src/modules/git/command.go:271 +0xe6a
code.gitea.io/gitea/modules/git.CatFileBatch.func3()
/drone/src/modules/git/batch_reader.go:123 +0x6fa
created by code.gitea.io/gitea/modules/git.CatFileBatch
/drone/src/modules/git/batch_reader.go:119 +0xa46
goroutine 230 [select, 19 minutes]:
io.(*pipe).read(0xc001a12120, {0xc002d28000, 0x8000, 0x46a452?})
/usr/local/go/src/io/pipe.go:57 +0x151
io.(*PipeReader).Read(0xc000014cb0, {0xc002d28000, 0x8000, 0x8000})
/usr/local/go/src/io/pipe.go:136 +0x65
io.copyBuffer({0x51e5fa0, 0xc0002e42b0}, {0x51e3cc0, 0xc000014cb0}, {0x0, 0x0, 0x0})
/usr/local/go/src/io/io.go:427 +0x28e
io.Copy(...)
/usr/local/go/src/io/io.go:386
os.genericReadFrom(0xc000014dd0?, {0x51e3cc0?, 0xc000014cb0?})
/usr/local/go/src/os/file.go:161 +0x89
os.(*File).ReadFrom(0xc000014dd0, {0x51e3cc0, 0xc000014cb0})
/usr/local/go/src/os/file.go:155 +0x325
io.copyBuffer({0x51e42e0, 0xc000014dd0}, {0x51e3cc0, 0xc000014cb0}, {0x0, 0x0, 0x0})
/usr/local/go/src/io/io.go:413 +0x1c6
io.Copy(...)
/usr/local/go/src/io/io.go:386
os/exec.(*Cmd).stdin.func1()
/usr/local/go/src/os/exec/exec.go:362 +0x85
os/exec.(*Cmd).Start.func1(0xc001d88a50)
/usr/local/go/src/os/exec/exec.go:544 +0x36
created by os/exec.(*Cmd).Start
/usr/local/go/src/os/exec/exec.go:543 +0xd75
goroutine 233 [chan send, 15 minutes]:
os/exec.(*Cmd).watchCtx.func1()
/usr/local/go/src/os/exec/exec.go:665 +0x277
created by os/exec.(*Cmd).watchCtx
/usr/local/go/src/os/exec/exec.go:647 +0x10f
FAIL code.gitea.io/gitea/services/migrations 1201.605s
? code.gitea.io/gitea/services/mirror [no test files]
ok code.gitea.io/gitea/services/org 3.661s coverage: 65.7% of statements
? code.gitea.io/gitea/services/packages [no test files]
? code.gitea.io/gitea/services/packages/container [no test files]
ok code.gitea.io/gitea/services/pull 1.904s coverage: 1.1% of statements
ok code.gitea.io/gitea/services/release 14.195s coverage: 53.7% of statements
ok code.gitea.io/gitea/services/repository 2.501s coverage: 14.6% of statements
ok code.gitea.io/gitea/services/repository/archiver 3.789s coverage: 43.0% of statements
ok code.gitea.io/gitea/services/repository/files 4.168s coverage: 22.0% of statements
? code.gitea.io/gitea/services/task [no test files]
ok code.gitea.io/gitea/services/user 3.010s coverage: 43.9% of statements
ok code.gitea.io/gitea/services/webhook 1.154s coverage: 70.7% of statements
ok code.gitea.io/gitea/services/wiki 3.400s coverage: 65.5% of statements
FAIL
make: *** [Makefile:402: unit-test-coverage] Error 1
Gitea Version
cb83288 (main HEAD as of yesterday)
Git Version
git version 2.34.1
Operating System
Ubuntu 22.04
How are you running Gitea?
Via Drone.