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

nil pointer dereference in test #14

Open
cjslep opened this issue Mar 6, 2021 · 1 comment
Open

nil pointer dereference in test #14

cjslep opened this issue Mar 6, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@cjslep
Copy link
Member

cjslep commented Mar 6, 2021

Server crashed due to a nil URL in the server DB, maybe related to #8 :

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x5c31da]

goroutine 2962 [running]:
net/url.(*URL).String(0x0, 0xc0003f4000, 0x0)
        net/url/url.go:775 +0x4a
github.com/go-fed/testsuite/server.(*Database).Create(0xc0001b5c00, 0x26137e0, 0xc0001b4cc0, 0x7fc849cbefd8, 0xc0003f4000, 0x0, 0x0)
        github.com/go-fed/testsuite/server/db.go:145 +0x5a
github.com/go-fed/testsuite/server.(*baseTest).helperMustAddToDatabase(0xc0001a7920, 0xc000258160, 0xc0003ca980, 0x7fc849cbefd8, 0xc0003f4000, 0x0)
        github.com/go-fed/testsuite/server/tests.go:276 +0x20f
github.com/go-fed/testsuite/server.newCommonTests.func2(0xc0001a7920, 0xc000258160, 0xc0000b5800, 0x1, 0xe, 0xc0001d6488)
        github.com/go-fed/testsuite/server/tests.go:975 +0x48c
github.com/go-fed/testsuite/server.(*baseTest).MaybeRunResult(0xc0001a7920, 0xc000258160, 0xc0000b5800, 0x1, 0xe, 0x0)
        github.com/go-fed/testsuite/server/tests.go:256 +0x5b
github.com/go-fed/testsuite/server.(*TestRunner).iterate(0xc0001d6480, 0xc000258160, 0x0, 0xd)
        github.com/go-fed/testsuite/server/testrunner.go:106 +0x144
github.com/go-fed/testsuite/server.(*TestRunner).Run.func1(0xc0001d6480, 0xc000258160)
        github.com/go-fed/testsuite/server/testrunner.go:71 +0x412
created by github.com/go-fed/testsuite/server.(*TestRunner).Run
        github.com/go-fed/testsuite/server/testrunner.go:65 +0xda
@cjslep cjslep added the bug Something isn't working label Mar 6, 2021
@gerard76
Copy link

Same problem here. Have you managed to get around this somehow?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants