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

panic: runtime error: invalid memory address or nil pointer dereference #65

Closed
gopi-nagarajan opened this issue Oct 19, 2020 · 2 comments
Labels

Comments

@gopi-nagarajan
Copy link

Hi,

We have received the below error quite frequently. Whenever we get this error, the container gets killed and new one is created.

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

goroutine 20 [running]:
sync.(*WaitGroup).state(...)
/usr/local/go/src/sync/waitgroup.go:33
sync.(*WaitGroup).Add(0x0, 0xffffffffffffffff)
/usr/local/go/src/sync/waitgroup.go:54 +0x26
sync.(*WaitGroup).Done(...)
/usr/local/go/src/sync/waitgroup.go:99
main.(*Worker).Start(0xc0001e4690, 0x7ffcccb85974, 0x24)
/go/src/app/worker.go:136 +0x1ac
created by main.main
/go/src/app/main.go:94 +0x7f4

Below is our configuration and we are using 'oracle' as driver.

Defined data sources

driver: oracle
port: 1521
cpu: 100m
memory: 128mi

We couldn't see any memory issues or cpu spikes at this time.

Cheers,
Gopi

@mainiak
Copy link

mainiak commented Jun 10, 2021

Hello.

I am seeing this as well whenever terminating docker container - with version 1.4.1 and whatever is current 'latest' docker image.

Stack flow is exact as above.

We are using MS SQL driver.

@haxorof haxorof added the bug label Jun 12, 2021
@haxorof
Copy link
Contributor

haxorof commented Jun 12, 2021

Seems to be that something is copied in the context to which the WaitGroup is added to. It is important not to copy thing when working with something in the sync package: https://golang.org/pkg/sync/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants