{"record":{"id":"6a0073a9e9e1fd21","repo":"grafana/k6","slug":"parsing-frame-wait-for-navigation-options-w","errorCode":null,"errorMessage":"parsing frame wait for navigation options: %w","messagePattern":"parsing frame wait for navigation options: %w","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/js/modules/k6/browser/browser/page_mapping.go","lineNumber":992,"sourceCode":"\t}\n\n\tpurl := parseStringOrRegex(url, false)\n\ttq, ctx, stop := newTaskQueue(vu)\n\n\treturn promise(vu, func() (result any, reason error) {\n\t\tdefer stop()\n\t\treturn nil, target.WaitForURL(purl, popts, newRegExMatcher(ctx, vu, tq))\n\t}), nil\n}\n\nfunc mapWaitForNavigation(vu moduleVU, target interface {\n\tTimeout() time.Duration\n\tWaitForNavigation(*common.FrameWaitForNavigationOptions, common.RegExMatcher) (*common.Response, error)\n}, opts sobek.Value,\n) (*sobek.Promise, error) {\n\tpopts := common.NewFrameWaitForNavigationOptions(target.Timeout())\n\tif err := popts.Parse(vu.Context(), opts); err != nil {\n\t\treturn nil, fmt.Errorf(\"parsing frame wait for navigation options: %w\", err)\n\t}\n\n\t// Only use task queue and RegExMatcher if a URL is specified.\n\trm, stop := func() (common.RegExMatcher, func()) {\n\t\tif popts.URL == \"\" {\n\t\t\treturn nil, func() {}\n\t\t}\n\t\ttq, ctx, stop := newTaskQueue(vu)\n\t\treturn newRegExMatcher(ctx, vu, tq), stop\n\t}()\n\n\treturn promise(vu, func() (any, error) {\n\t\tdefer stop()\n\n\t\tresp, err := target.WaitForNavigation(popts, rm)\n\t\tif err != nil {\n\t\t\treturn nil, err //nolint:wrapcheck\n\t\t}","sourceCodeStart":974,"sourceCodeEnd":1010,"githubUrl":"https://github.com/grafana/k6/blob/93accf6570dcd306ca5e99cc44c393ee3797761b/internal/js/modules/k6/browser/browser/page_mapping.go#L974-L1010","documentation":"Error \"parsing frame wait for navigation options: %w\" thrown in grafana/k6.","triggerScenarios":"Thrown at internal/js/modules/k6/browser/browser/page_mapping.go:992 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"93accf6570dcd306ca5e99cc44c393ee3797761b","analyzedAt":"2026-08-15T21:23:27.118Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}