You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
go run run.go -- fixedbugs/issue24491b.go
exit status 2
panic: GC late
goroutine 1 [running]:
main.after(0x900e018)
/workdir/go/test/fixedbugs/issue24491b.go:39 +0x54
main.main()
/workdir/go/test/fixedbugs/issue24491b.go:45 +0x2e
FAIL fixedbugs/issue24491b.go 0.111s
2020/09/13 04:48:44 Failed: exit status 1
go tool dist: FAILED
The test was added in 1f45216, and builder on this commit passed. The builder fails when commit 5f1b12b was submitted, it's a refactoring only, so it's not clear to me yet why the test can be failed.
Oh, probably because runtime.GC() doesn't guarantee the finalizer has run. (I guess that's why I used channels in the other test cases I wrote.)
That's probably the best fix here too. Change done to a channel; make the finalizer close it; have before check that it's not closed (non-blocking receive using select); and have after check that it is closed (blocking receive).
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
No
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
go tool dist test
passes.What did you see instead?
Test fails on builder: https://build.golang.org/log/72b1813880f8c739753c10320bc0ca2745aa73f9
The test was added in 1f45216, and builder on this commit passed. The builder fails when commit 5f1b12b was submitted, it's a refactoring only, so it's not clear to me yet why the test can be failed.
cc @mdempsky
The text was updated successfully, but these errors were encountered: