Skip to content

Instantly share code, notes, and snippets.

@wchargin
Created May 29, 2025 22:04
Show Gist options
  • Save wchargin/330800fee39443dbf340c7b41377ba50 to your computer and use it in GitHub Desktop.
Save wchargin/330800fee39443dbf340c7b41377ba50 to your computer and use it in GitHub Desktop.
panic: test timed out after 10m0s
running tests:
TestGORM (10m0s)
goroutine 43 [running]:
testing.(*M).startAlarm.func1()
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:2373 +0x1dc
created by time.goFunc
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/time/sleep.go:215 +0x44
goroutine 1 [chan receive, 10 minutes]:
testing.(*T).Run(0xc000145860, {0x101423826, 0x8}, 0x101751dd0)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:1751 +0x600
testing.runTests.func1(0xc000145860)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:2168 +0x84
testing.tRunner(0xc000145860, 0xc000629ad8)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:1690 +0x188
testing.runTests(0xc0003828a0, {0x101b52720, 0x1, 0x1}, {0xc000370cf0?, 0x100c59dd0?, 0x101bb1d20?})
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:2166 +0x6e4
testing.(*M).Run(0xc0001435e0)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:2034 +0xb78
main.main()
_testmain.go:45 +0x114
goroutine 36 [select]:
github.com/jackc/pgx/v5/pgxpool.(*Pool).backgroundHealthCheck(0xc0001e6600)
/Users/wchargin/go/pkg/mod/github.com/jackc/pgx/[email protected]/pgxpool/pool.go:433 +0x140
github.com/jackc/pgx/v5/pgxpool.NewWithConfig.func3()
/Users/wchargin/go/pkg/mod/github.com/jackc/pgx/[email protected]/pgxpool/pool.go:286 +0x84
created by github.com/jackc/pgx/v5/pgxpool.NewWithConfig in goroutine 1
/Users/wchargin/go/pkg/mod/github.com/jackc/pgx/[email protected]/pgxpool/pool.go:283 +0x840
goroutine 37 [select, 10 minutes]:
database/sql.(*DB).connectionOpener(0xc000364820, {0x10175e948, 0xc000354a50})
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1253 +0xbc
created by database/sql.OpenDB in goroutine 1
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:833 +0x25c
goroutine 21 [select, 10 minutes]:
gorm.io/gorm/internal/lru.NewLRU[...].func1()
/path/to/mod/gorm/internal/lru/lru.go:83 +0x150
created by gorm.io/gorm/internal/lru.NewLRU[...] in goroutine 1
/path/to/mod/gorm/internal/lru/lru.go:79 +0x46c
goroutine 97 [chan receive, 10 minutes]:
database/sql.(*Tx).awaitDone(0xc0002a6680)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:2204 +0x50
created by database/sql.(*DB).beginDC in goroutine 14
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1917 +0x35c
goroutine 42 [chan receive, 10 minutes]:
database/sql.(*Tx).awaitDone(0xc000310500)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:2204 +0x50
created by database/sql.(*DB).beginDC in goroutine 15
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1917 +0x35c
goroutine 13 [select, 10 minutes]:
golang.org/x/sync/semaphore.(*Weighted).Acquire(0xc000354a00, {0x10175e830, 0x102b20500}, 0x1)
/Users/wchargin/go/pkg/mod/golang.org/x/[email protected]/semaphore/semaphore.go:74 +0x450
github.com/jackc/puddle/v2.(*Pool[...]).acquire(0x101775d40, {0x10175e830, 0x102b20500})
/Users/wchargin/go/pkg/mod/github.com/jackc/puddle/[email protected]/pool.go:360 +0xc4
github.com/jackc/puddle/v2.(*Pool[...]).Acquire(0x101775d40, {0x10175e830, 0x102b20500})
/Users/wchargin/go/pkg/mod/github.com/jackc/puddle/[email protected]/pool.go:347 +0xc0
github.com/jackc/pgx/v5/pgxpool.(*Pool).Acquire(0xc0001e6600, {0x10175e830, 0x102b20500})
/Users/wchargin/go/pkg/mod/github.com/jackc/pgx/[email protected]/pgxpool/pool.go:549 +0x190
github.com/jackc/pgx/v5/stdlib.connector.Connect({{{{0x0, 0x0}, 0x0, {0x0, 0x0}, {0x0, 0x0}, {0x0, 0x0}, 0x0, ...}, ...}, ...}, ...)
/Users/wchargin/go/pkg/mod/github.com/jackc/pgx/[email protected]/stdlib/sql.go:266 +0x8c
database/sql.(*DB).conn(0xc000364820, {0x10175e830, 0x102b20500}, 0x1)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1423 +0xa84
database/sql.(*DB).prepare(0xc000364820, {0x10175e830, 0x102b20500}, {0xc00014e560, 0x18}, 0x1)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1617 +0x50
database/sql.(*DB).PrepareContext.func1(0x1)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1591 +0x7c
database/sql.(*DB).retry(0x1013e5214?, 0xc00045b7d8)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1568 +0x50
database/sql.(*DB).PrepareContext(0xc000364820, {0x10175e830, 0x102b20500}, {0xc00014e560, 0x18})
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/database/sql/sql.go:1590 +0xd0
gorm.io/gorm/internal/stmt_store.(*lruStore).New(0xc0001221e8, {0x10175e830, 0x102b20500}, {0xc00014e560, 0x18}, 0x0, {0x103058098, 0xc000364820}, {0x101759e68, 0xc00013c000})
/path/to/mod/gorm/internal/stmt_store/stmt_store.go:173 +0x1b4
gorm.io/gorm.(*PreparedStmtDB).prepare(0xc00012b440, {0x10175e830, 0x102b20500}, {0x10175e868, 0xc000364820}, 0x0, {0xc00014e560, 0x18})
/path/to/mod/gorm/prepare_stmt.go:85 +0x288
gorm.io/gorm.(*PreparedStmtDB).QueryContext(0xc00012b440, {0x10175e830, 0x102b20500}, {0xc00014e560, 0x18}, {0xc0002a6700, 0x2, 0x8})
/path/to/mod/gorm/prepare_stmt.go:121 +0x74
gorm.io/gorm/callbacks.Query(0xc0003a6390)
/path/to/mod/gorm/callbacks/query.go:19 +0x1bc
gorm.io/gorm.(*processor).Execute(0xc00012c050, 0xc0003a6390)
/path/to/mod/gorm/callbacks.go:130 +0x814
gorm.io/gorm.(*DB).First(0xc0003a6390, {0x1016369c0, 0xc0000114fc}, {0x0, 0x0, 0x0})
/path/to/mod/gorm/finisher_api.go:131 +0x254
gorm.io/playground.addTwoNumbers(0xc000145a00, 0xc00012a060, {0x101422feb, 0x7})
/path/to/mod/main_test.go:45 +0x128
gorm.io/playground.TestGORM(0xc000145a00)
/path/to/mod/main_test.go:38 +0x2b8
testing.tRunner(0xc000145a00, 0x101751dd0)
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:1690 +0x188
created by testing.(*T).Run in goroutine 1
/Users/wchargin/go/pkg/mod/golang.org/[email protected]/src/testing/testing.go:1743 +0x5e4
goroutine 14 [chan receive, 10 minutes]:
gorm.io/gorm/internal/stmt_store.(*lruStore).Get(0xc0001221e8, {0xc00014e5c0, 0x18})
/path/to/mod/gorm/internal/stmt_store/stmt_store.go:126 +0x80
gorm.io/gorm.(*PreparedStmtDB).prepare(0xc00012b440, {0x10175e830, 0x102b20500}, {0x10175eb08, 0xc0002a6680}, 0x1, {0xc00014e5c0, 0x18})
/path/to/mod/gorm/prepare_stmt.go:69 +0x9c
gorm.io/gorm.(*PreparedStmtTX).QueryContext(0xc000126b28, {0x10175e830, 0x102b20500}, {0xc00014e5c0, 0x18}, {0xc0002a6800, 0x2, 0x8})
/path/to/mod/gorm/prepare_stmt.go:182 +0xb8
gorm.io/gorm/callbacks.Query(0xc0003a6570)
/path/to/mod/gorm/callbacks/query.go:19 +0x1bc
gorm.io/gorm.(*processor).Execute(0xc00012c050, 0xc0003a6570)
/path/to/mod/gorm/callbacks.go:130 +0x814
gorm.io/gorm.(*DB).First(0xc0003a6570, {0x1016369c0, 0xc0000115cc}, {0x0, 0x0, 0x0})
/path/to/mod/gorm/finisher_api.go:131 +0x254
gorm.io/playground.addTwoNumbers(0xc000145a00, 0xc0000fff20, {0x101422189, 0x5})
/path/to/mod/main_test.go:45 +0x128
gorm.io/playground.TestGORM.func1.1(0xc0000fff20)
/path/to/mod/main_test.go:32 +0x114
gorm.io/gorm.(*DB).Transaction(0xc00012a060, 0xc000459f88, {0x0, 0x0, 0x0})
/path/to/mod/gorm/finisher_api.go:654 +0x378
gorm.io/playground.TestGORM.func1()
/path/to/mod/main_test.go:25 +0xd4
created by gorm.io/playground.TestGORM in goroutine 13
/path/to/mod/main_test.go:24 +0xf4
goroutine 15 [chan receive, 10 minutes]:
gorm.io/gorm/internal/stmt_store.(*lruStore).Get(0xc0001221e8, {0xc00014e5a0, 0x18})
/path/to/mod/gorm/internal/stmt_store/stmt_store.go:126 +0x80
gorm.io/gorm.(*PreparedStmtDB).prepare(0xc00012b440, {0x10175e830, 0x102b20500}, {0x10175eb08, 0xc000310500}, 0x1, {0xc00014e5a0, 0x18})
/path/to/mod/gorm/prepare_stmt.go:69 +0x9c
gorm.io/gorm.(*PreparedStmtTX).QueryContext(0xc0001c4438, {0x10175e830, 0x102b20500}, {0xc00014e5a0, 0x18}, {0xc0002a6780, 0x2, 0x8})
/path/to/mod/gorm/prepare_stmt.go:182 +0xb8
gorm.io/gorm/callbacks.Query(0xc0003a64b0)
/path/to/mod/gorm/callbacks/query.go:19 +0x1bc
gorm.io/gorm.(*processor).Execute(0xc00012c050, 0xc0003a64b0)
/path/to/mod/gorm/callbacks.go:130 +0x814
gorm.io/gorm.(*DB).First(0xc0003a64b0, {0x1016369c0, 0xc00001155c}, {0x0, 0x0, 0x0})
/path/to/mod/gorm/finisher_api.go:131 +0x254
gorm.io/playground.addTwoNumbers(0xc000145a00, 0xc000370e40, {0x10142188a, 0x3})
/path/to/mod/main_test.go:45 +0x128
gorm.io/playground.TestGORM.func1.1(0xc000370e40)
/path/to/mod/main_test.go:32 +0x114
gorm.io/gorm.(*DB).Transaction(0xc00012a060, 0xc00045df88, {0x0, 0x0, 0x0})
/path/to/mod/gorm/finisher_api.go:654 +0x378
gorm.io/playground.TestGORM.func1()
/path/to/mod/main_test.go:25 +0xd4
created by gorm.io/playground.TestGORM in goroutine 13
/path/to/mod/main_test.go:24 +0xf4
FAIL gorm.io/playground 600.409s
FAIL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment