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

concurrent map iteration and map write: FrameSession.attachWorkerToTarget #4566

Open
inancgumus opened this issue Feb 19, 2025 · 0 comments
Open

Comments

@inancgumus
Copy link
Member

Summary

Test run ID: 3459317 (Browser version: 1.8.5)
fatal error: concurrent map writes

goroutine 2289755 [running]:
github.com/grafana/xk6-browser/common.(*FrameSession).attachWorkerToTarget(0xc0008a1bc0, 0xc0007d2bd0, {0xc001c789c0, 0x20})
github.com/grafana/[email protected]/common/frame_session.go:1056 +0x19b
github.com/grafana/xk6-browser/common.(*FrameSession).onAttachedToTarget(0xc0008a1bc0, 0xc00901c220)
github.com/grafana/[email protected]/common/frame_session.go:969 +0x2a6
github.com/grafana/xk6-browser/common.(*FrameSession).initEvents.func1()
github.com/grafana/[email protected]/common/frame_session.go:303 +0x233
created by github.com/grafana/xk6-browser/common.(*FrameSession).initEvents in goroutine 2278207
github.com/grafana/[email protected]/common/frame_session.go:239 +0x19b

goroutine 1 [chan receive, 3 minutes]:
go.k6.io/k6/execution.(*Scheduler).Run(0xc000190f80, {0x1f91908, 0xc0002e01e0}, {0x1f918d0, 0xc0003d8360}, 0xc000270850)
go.k6.io/k6/execution/scheduler.go:508 +0xcb4
go.k6.io/k6/cmd.(*cmdRun).run(0xc0003c9bc0, 0xc000330588, {0xc000227508, 0x1, 0x2d})
go.k6.io/k6/cmd/run.go:397 +0x1545
github.com/spf13/cobra.(*Command).execute(0xc000330588, {0xc000227208, 0x2d, 0x2f})
github.com/spf13/[email protected]/command.go:856 +0x68a
github.com/spf13/cobra.(*Command).ExecuteC(0xc00026d608)
github.com/spf13/[email protected]/command.go:974 +0x38d
github.com/spf13/cobra.(*Command).Execute(...)
github.com/spf13/[email protected]/command.go:902
go.k6.io/k6/cmd.(*rootCommand).execute(0xc000032810)
go.k6.io/k6/cmd/root.go:108 +0xfb
go.k6.io/k6/cmd.Execute()
go.k6.io/k6/cmd/root.go:130 +0x2f
main.main()
go.k6.io/k6/main.go:9 +0xf

goroutine 21 [select]:
go.k6.io/k6/log.(*lokiHook).Listen(0xc000323e10, {0x1f91908, 0xc0002e0190})
go.k6.io/k6/log/loki.go:220 +0x3dc
go.k6.io/k6/cmd.(*rootCommand).setLoggerHook.func1()
go.k6.io/k6/cmd/root.go:287 +0x2d
created by go.k6.io/k6/cmd.(*rootCommand).setLoggerHook in goroutine 1
go.k6.io/k6/cmd/root.go:286 +0xb0

goroutine 22 [select, 3 minutes]:
io.(*pipe).read(0xc000230d20, {0xc000476000, 0x10000, 0xc0000b8fc0?})
io/pipe.go:57 +0xa5
io.(*PipeReader).Read(0xc00043ae90?, {0xc000476000?, 0x4?, 0x10000?})
io/pipe.go:134 +0x1a
bufio.(*Scanner).Scan(0xc000457f28)
bufio/scan.go:219 +0x81e
github.com/sirupsen/logrus.(*Entry).writerScanner(0xc0002ccd90, 0xc000230d20, 0xc0001224c0)
github.com/sirupsen/[email protected]/writer.go:86 +0x11d
created by github.com/sirupsen/logrus.(*Entry).WriterLevel in goroutine 1
github.com/sirupsen/[email protected]/writer.go:57 +0x31f

goroutine 23 [chan receive, 3 minutes]:
go.k6.io/k6/cmd.(*rootCommand).setupLoggers.func2()
go.k6.io/k6/cmd/root.go:276 +0x34
created by go.k6.io/k6/cmd.(*rootCommand).setupLoggers in goroutine 1
go.k6.io/k6/cmd/root.go:275 +0x637

goroutine 7 [chan receive]:
go.k6.io/k6/log.(*lokiHook).Listen.func2()
go.k6.io/k6/log/loki.go:168 +0x10f
created by go.k6.io/k6/log.(*lokiHook).Listen in goroutine 21
go.k6.io/k6/log/loki.go:165 +0x2f9

goroutine 68 [chan receive, 3 minutes]:
github.com/grafana/xk6-browser/browser.(*browserRegistry).handleExitEvent(0xc0000acd20, 0x422d2d2d2d2d0a0a?, 0x524543204e494745?)
github.com/grafana/[email protected]/browser/registry.go:333 +0x45
created by github.com/grafana/xk6-browser/browser.newBrowserRegistry in goroutine 14
github.com/grafana/[email protected]/browser/registry.go:250 +0x2b2

goroutine 25 [chan receive, 3 minutes]:
github.com/grafana/xk6-browser/browser.(*browserRegistry).handleExitEvent(0xc000140780, 0x0?, 0x0?)
github.com/grafana/[email protected]/browser/registry.go:333 +0x45
created by github.com/grafana/xk6-browser/browser.newBrowserRegistry in goroutine 1
github.com/grafana/[email protected]/browser/registry.go:250 +0x2b2

goroutine 26 [chan receive, 3 minutes]:
github.com/grafana/xk6-browser/browser.(*browserRegistry).handleIterEvents(0xc000140780, {0x1f91718, 0x2fc9fa0}, 0xc00026bf10, 0xc000296330)
github.com/grafana/[email protected]/browser/registry.go:264 +0x85
created by github.com/grafana/xk6-browser/browser.newBrowserRegistry in goroutine 1
github.com/grafana/[email protected]/browser/registry.go:251 +0x336

goroutine 27 [select]:
go.opentelemetry.io/otel/sdk/trace.(*batchSpanProcessor).processQueue(0xc0001c9ea0)
go.opentelemetry.io/otel/[email protected]/trace/batch_span_processor.go:301 +0x114
go.opentelemetry.io/otel/sdk/trace.NewBatchSpanProcessor.func1()
go.opentelemetry.io/otel/[email protected]/trace/batch_span_processor.go:117 +0x4e
created by go.opentelemetry.io/otel/sdk/trace.NewBatchSpanProcessor in goroutine 1
go.opentelemetry.io/otel/[email protected]/trace/batch_span_processor.go:115 +0x2e5

goroutine 69 [chan receive]:
github.com/grafana/xk6-browser/browser.(*browserRegistry).handleIterEvents(0xc0000acd20, {0x1f91718, 0x2fc9fa0}, 0xc00029c5b0, 0xc0006351d0)
github.com/grafana/[email protected]/browser/registry.go:264 +0x85
created by github.com/grafana/xk6-browser/browser.newBrowserRegistry in goroutine 14
github.com/grafana/[email protected]/browser/registry.go:251 +0x336

goroutine 212 [chan receive, 3 minutes]:
go.k6.io/k6/lib/executor.trackProgress({0x1f91908, 0xc000a9e320}, {0x1f918d0, 0xc000a

k6 version

v0.57

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

No branches or pull requests

1 participant