Skip to content
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

TestMiddlewareTestSuite is unstable #8513

Closed
lhy1024 opened this issue Aug 9, 2024 · 0 comments · Fixed by #8540
Closed

TestMiddlewareTestSuite is unstable #8513

lhy1024 opened this issue Aug 9, 2024 · 0 comments · Fixed by #8540
Labels
type/ci The issue is related to CI.

Comments

@lhy1024
Copy link
Contributor

lhy1024 commented Aug 9, 2024

Flaky Test

Which jobs are failing

2024-08-09T09:16:08.8855215Z     suite.go:87: test panicked: runtime error: invalid memory address or nil pointer dereference
2024-08-09T09:16:08.8856405Z         goroutine 1943 [running]:
2024-08-09T09:16:08.8857063Z         runtime/debug.Stack()
2024-08-09T09:16:08.8858131Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/runtime/debug/stack.go:24 +0x67
2024-08-09T09:16:08.8859587Z         github.com/stretchr/testify/suite.failOnPanic(0xc008b7e1a0, {0x4438340, 0x6afdd90})
2024-08-09T09:16:08.8861256Z         	/home/runner/go/pkg/mod/github.com/stretchr/testify@v1.8.4/suite/suite.go:87 +0x4e
2024-08-09T09:16:08.8862517Z         github.com/stretchr/testify/suite.Run.func1.1()
2024-08-09T09:16:08.8863920Z         	/home/runner/go/pkg/mod/github.com/stretchr/testify@v1.8.4/suite/suite.go:183 +0x345
2024-08-09T09:16:08.8865038Z         panic({0x4438340?, 0x6afdd90?})
2024-08-09T09:16:08.8866130Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/runtime/panic.go:920 +0x270
2024-08-09T09:16:08.8867260Z         github.com/tikv/pd/tests.(*TestServer).GetServer(0x0)
2024-08-09T09:16:08.8868288Z         	/home/runner/work/pd/pd/tests/cluster.go:217 +0x85
2024-08-09T09:16:08.8869774Z         github.com/tikv/pd/tests/server/api.(*middlewareTestSuite).TestRateLimitMiddleware(0xc0001ac320)
2024-08-09T09:16:08.8873022Z         	/home/runner/work/pd/pd/tests/server/api/api_test.go:304 +0x1a32
2024-08-09T09:16:08.8874616Z         reflect.Value.call({0xc0010dbfc0?, 0xc0065a9c78?, 0x13?}, {0x4782a5e, 0x4}, {0xc008e47db0, 0x1, 0x1?})
2024-08-09T09:16:08.8876195Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/reflect/value.go:596 +0x14ce
2024-08-09T09:16:08.8877705Z         reflect.Value.Call({0xc0010dbfc0?, 0xc0065a9c78?, 0xc0001ac320?}, {0xc005fb4db0, 0x1, 0x1})
2024-08-09T09:16:08.8879210Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/reflect/value.go:380 +0xb6
2024-08-09T09:16:08.8880357Z         github.com/stretchr/testify/suite.Run.func1(0xc008b7e1a0)
2024-08-09T09:16:08.8882282Z         	/home/runner/go/pkg/mod/github.com/stretchr/testify@v1.8.4/suite/suite.go:197 +0x767
2024-08-09T09:16:08.8883493Z         testing.tRunner(0xc008b7e1a0, 0xc001342990)
2024-08-09T09:16:08.8884767Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/testing/testing.go:1595 +0x262
2024-08-09T09:16:08.8885830Z         created by testing.(*T).Run in goroutine 255
2024-08-09T09:16:08.8887022Z         	/opt/hostedtoolcache/go/1.21.12/x64/src/testing/testing.go:1648 +0x846
2024-08-09T09:16:08.8888020Z === RUN   TestMiddlewareTestSuite/TestRequestInfoMiddleware
2024-08-09T09:16:08.8888814Z     api_test.go:143: 
2024-08-09T09:16:08.8889865Z         	Error Trace:	/home/runner/work/pd/pd/tests/server/api/api_test.go:143
2024-08-09T09:16:08.8891022Z         	Error:      	Expected value not to be nil.
2024-08-09T09:16:08.8892135Z         	Test:       	TestMiddlewareTestSuite/TestRequestInfoMiddleware
2024-08-09T09:16:08.8893339Z === RUN   TestMiddlewareTestSuite/TestSwaggerUrl
2024-08-09T09:16:08.8894086Z     api_test.go:393: 
2024-08-09T09:16:08.8895167Z         	Error Trace:	/home/runner/work/pd/pd/tests/server/api/api_test.go:393
2024-08-09T09:16:08.8896262Z         	Error:      	Expected value not to be nil.
2024-08-09T09:16:08.8897220Z         	Test:       	TestMiddlewareTestSuite/TestSwaggerUrl

CI link

https://github.com/tikv/pd/actions/runs/10316739856/job/28559587719
https://github.com/tikv/pd/actions/runs/10314613258/job/28553316701

Reason for failure (if possible)

Anything else

@lhy1024 lhy1024 added the type/ci The issue is related to CI. label Aug 9, 2024
@lhy1024 lhy1024 changed the title TestRateLimitMiddleware is unstable TestMiddlewareTestSuite is unstable Aug 9, 2024
@ti-chi-bot ti-chi-bot bot closed this as completed in 4b0878e Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/ci The issue is related to CI.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant