Skip to content
This repository has been archived by the owner on Jan 30, 2025. It is now read-only.

WaitFor NPD #1319

Closed
5 tasks
inancgumus opened this issue May 9, 2024 · 1 comment
Closed
5 tasks

WaitFor NPD #1319

inancgumus opened this issue May 9, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@inancgumus
Copy link
Member

What?

WaitFor generates an NPD when the execution context is not found.

time="2024-05-09T08:32:41Z" level=error msg="error on evaluating window.k6SpanId: evaluating JS in global context: context canceled" category="FrameSession:onFrameNavigated" elapsed="0 ms" source=browser
--- FAIL: TestShadowDOMAndDocumentFragment (15.30s)
    --- FAIL: TestShadowDOMAndDocumentFragment/waitFor_DocumentFragment (0.47s)
        page_test.go:1697: 
            	Error Trace:	/home/runner/work/xk6-browser/xk6-browser/tests/page_test.go:1697
            	Error:      	Received unexpected error:
            	            	GoError: waiting for "//p[@id=\"inDocFrag\"]": getting new document handle: getting document element handle: Cannot find context with specified id at github.com/grafana/xk6-browser/common.(*Locator).WaitFor-fm (native)
            	Test:       	TestShadowDOMAndDocumentFragment/waitFor_DocumentFragment

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

goroutine 1310 [running]:
testing.tRunner.func1.2({0x1c0ba60, 0x2daa270})
	/opt/hostedtoolcache/go/1.21.10/x64/src/testing/testing.go:1545 +0x3f7
testing.tRunner.func1()
	/opt/hostedtoolcache/go/1.21.10/x64/src/testing/testing.go:1548 +0x716
panic({0x1c0ba60?, 0x2daa270?})
	/opt/hostedtoolcache/go/1.21.10/x64/src/runtime/panic.go:[92](https://github.com/grafana/xk6-browser/actions/runs/9014614523/job/24767627412?pr=1318#step:4:93)0 +0x270
github.com/grafana/xk6-browser/tests.TestShadowDOMAndDocumentFragment.func1(0x0?)
	/home/runner/work/xk6-browser/xk6-browser/tests/page_test.go:1698 +0x1fe
testing.tRunner(0xc00092a4e0, 0xc00096f7c0)
	/opt/hostedtoolcache/go/1.21.10/x64/src/testing/testing.go:15[95](https://github.com/grafana/xk6-browser/actions/runs/9014614523/job/24767627412?pr=1318#step:4:96) +0x262
created by testing.(*T).Run in goroutine 676
	/opt/hostedtoolcache/go/1.21.10/x64/src/testing/testing.go:1648 +0x846
FAIL	github.com/grafana/xk6-browser/tests	19.282s
FAIL

Details

Why?

Reliability.

How?

No response

Tasks

Tasks

Preview Give feedback

Related PR(s)/Issue(s)

No response

@inancgumus inancgumus added the bug Something isn't working label May 9, 2024
@ankur22
Copy link
Collaborator

ankur22 commented Dec 16, 2024

I believe this was solved with #1469

@ankur22 ankur22 closed this as completed Dec 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants