{"record":{"id":"3a3a7622b94de7c4","repo":"grafana/k6","slug":"unsupported-browser-type-s","errorCode":null,"errorMessage":"unsupported browser type: %s","messagePattern":"unsupported browser type: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/js/modules/k6/browser/common/browser_options.go","lineNumber":70,"sourceCode":"\t\tTimeout:           DefaultTimeout,\n\t\tisRemoteBrowser:   true,\n\t}\n}\n\n// Parse parses browser options from a JS object.\nfunc (bo *BrowserOptions) Parse(\n\tctx context.Context, logger *log.Logger, opts map[string]any, envLookup env.LookupFunc,\n) error {\n\t// Parse opts\n\tbt, ok := opts[optType]\n\t// Only 'chromium' is supported by now, so return error\n\t// if type option is not set, or if it's set and its value\n\t// is different than 'chromium'\n\tif !ok {\n\t\treturn errors.New(\"browser type option must be set\")\n\t}\n\tif bt != \"chromium\" {\n\t\treturn fmt.Errorf(\"unsupported browser type: %s\", bt)\n\t}\n\n\t// Parse env\n\tenvOpts := [...]string{\n\t\tenv.BrowserArguments,\n\t\tenv.BrowserEnableDebugging,\n\t\tenv.BrowserExecutablePath,\n\t\tenv.BrowserHeadless,\n\t\tenv.BrowserIgnoreDefaultArgs,\n\t\tenv.LogCategoryFilter,\n\t\tenv.BrowserGlobalTimeout,\n\t}\n\n\tfor _, e := range envOpts {\n\t\tev, ok := envLookup(e)\n\t\tif !ok || ev == \"\" {\n\t\t\tcontinue\n\t\t}","sourceCodeStart":52,"sourceCodeEnd":88,"githubUrl":"https://github.com/grafana/k6/blob/01ffac6f245854c1b8adc6a69857c76a15f90022/internal/js/modules/k6/browser/common/browser_options.go#L52-L88","documentation":"BrowserOptions.Parse found a browser type option whose value is anything other than 'chromium'. k6 currently implements only chromium; setting options.type = 'firefox'/'webkit' (or a typo like 'chromiom') fires this guard during init.","triggerScenarios":"Thrown at internal/js/modules/k6/browser/common/browser_options.go:70 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set type: 'chromium' in the browser scenario options","Remove the type option to use the default","For other engines, use Playwright or xk6 extensions outside k6 browser module"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"01ffac6f245854c1b8adc6a69857c76a15f90022","analyzedAt":"2026-08-18T03:05:52.393Z","contentChangedAt":"2026-08-18T03:05:52.393Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}