{"record":{"id":"5bb0e4ff67171d88","repo":"grafana/k6","slug":"parsing-page-go-forward-options-w","errorCode":null,"errorMessage":"parsing page go forward options: %w","messagePattern":"parsing page go forward options: %w","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/js/modules/k6/browser/browser/page_mapping.go","lineNumber":407,"sourceCode":"\t\t\tpopts := common.NewPageGoBackForwardOptions(common.LifecycleEventLoad, p.NavigationTimeout())\n\t\t\tif err := popts.Parse(vu.Context(), opts); err != nil {\n\t\t\t\treturn nil, fmt.Errorf(\"parsing page go back options: %w\", err)\n\t\t\t}\n\t\t\treturn promise(vu, func() (any, error) {\n\t\t\t\tresp, err := p.GoBackForward(-1, popts)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err //nolint:wrapcheck\n\t\t\t\t}\n\t\t\t\tif resp == nil {\n\t\t\t\t\treturn nil, nil //nolint:nilnil\n\t\t\t\t}\n\t\t\t\treturn mapResponse(vu, resp), nil\n\t\t\t}), nil\n\t\t},\n\t\t\"goForward\": func(opts sobek.Value) (*sobek.Promise, error) {\n\t\t\tpopts := common.NewPageGoBackForwardOptions(common.LifecycleEventLoad, p.NavigationTimeout())\n\t\t\tif err := popts.Parse(vu.Context(), opts); err != nil {\n\t\t\t\treturn nil, fmt.Errorf(\"parsing page go forward options: %w\", err)\n\t\t\t}\n\t\t\treturn promise(vu, func() (any, error) {\n\t\t\t\tresp, err := p.GoBackForward(+1, popts)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err //nolint:wrapcheck\n\t\t\t\t}\n\t\t\t\tif resp == nil {\n\t\t\t\t\treturn nil, nil //nolint:nilnil\n\t\t\t\t}\n\t\t\t\treturn mapResponse(vu, resp), nil\n\t\t\t}), nil\n\t\t},\n\t\t\"route\": mapPageRoute(vu, p),\n\t\t\"screenshot\": func(opts sobek.Value) (*sobek.Promise, error) {\n\t\t\tpopts, err := parsePageScreenshotOptions(rt, opts)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, fmt.Errorf(\"parsing page screenshot options: %w\", err)\n\t\t\t}","sourceCodeStart":389,"sourceCodeEnd":425,"githubUrl":"https://github.com/grafana/k6/blob/8d06114777191d21ef885d05c5f8aa9e1ed838ae/internal/js/modules/k6/browser/browser/page_mapping.go#L389-L425","documentation":"Generic parse wrapper for page.goForward: the options argument failed to decode into common.PageGoBackForwardOptions (waitUntil, timeout). Identical failure mode to goBack — the wrapped error names the malformed key.","triggerScenarios":"Thrown at internal/js/modules/k6/browser/browser/page_mapping.go:406 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use only supported keys: waitUntil ('load'|'domcontentloaded'|'networkidle') and timeout (ms)","Check the wrapped error for the failing field","Omit options to use defaults"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"8d06114777191d21ef885d05c5f8aa9e1ed838ae","analyzedAt":"2026-08-18T03:05:52.393Z","contentChangedAt":"2026-08-18T03:05:52.393Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}