{"record":{"id":"5256380d3d05ca00","repo":"grafana/k6","slug":"unexpected-type-t-525638","errorCode":null,"errorMessage":"unexpected type %T","messagePattern":"unexpected type %T","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/js/modules/k6/browser/common/frame.go","lineNumber":1317,"sourceCode":"\nfunc (f *Frame) innerHTML(selector string, opts *FrameInnerHTMLOptions) (string, error) {\n\tinnerHTML := func(apiCtx context.Context, handle *ElementHandle) (any, error) {\n\t\treturn handle.innerHTML(apiCtx)\n\t}\n\tact := f.newAction(\n\t\tselector, DOMElementStateAttached, opts.Strict, innerHTML,\n\t\t[]string{}, false, withRetry, true, opts.Timeout,\n\t)\n\tv, err := call(f.ctx, act, opts.Timeout)\n\tif err != nil {\n\t\treturn \"\", errorFromDOMError(err)\n\t}\n\tif v == nil {\n\t\treturn \"\", nil\n\t}\n\tgv, ok := v.(string)\n\tif !ok {\n\t\treturn \"\", fmt.Errorf(\"unexpected type %T\", v)\n\t}\n\n\treturn gv, nil\n}\n\n// InnerText returns the inner text of the first element found\n// that matches the selector.\nfunc (f *Frame) InnerText(selector string, popts *FrameInnerTextOptions) (string, error) {\n\tf.log.Debugf(\"Frame:InnerText\", \"fid:%s furl:%q sel:%q\", f.ID(), f.URL(), selector)\n\n\tv, err := f.innerText(selector, popts)\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"getting inner text of %q: %w\", selector, err)\n\t}\n\n\treturn v, nil\n}\n","sourceCodeStart":1299,"sourceCodeEnd":1335,"githubUrl":"https://github.com/grafana/k6/blob/93accf6570dcd306ca5e99cc44c393ee3797761b/internal/js/modules/k6/browser/common/frame.go#L1299-L1335","documentation":"Error \"unexpected type %T\" thrown in grafana/k6.","triggerScenarios":"Thrown at internal/js/modules/k6/browser/common/frame.go:1317 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"}