{"record":{"id":"9f614ec54663fcdc","repo":"grafana/k6","slug":"unqouting-k6-instance-scenarios-w","errorCode":null,"errorMessage":"unqouting K6_INSTANCE_SCENARIOS: %w","messagePattern":"unqouting K6_INSTANCE_SCENARIOS: %w","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/js/modules/k6/browser/browser/registry.go","lineNumber":126,"sourceCode":"\t}\n\n\treturn true, parts\n}\n\n// checkForScenarios will parse the K6_INSTANCE_SCENARIOS env var if\n// it has been defined.\nfunc checkForScenarios(envLookup env.LookupFunc) (bool, []string, error) {\n\tscenariosJSON, isRemote := envLookup(env.InstanceScenarios)\n\tif !isRemote {\n\t\treturn false, nil, nil\n\t}\n\t// prevent failing in unquoting empty string.\n\tif scenariosJSON == \"\" {\n\t\treturn false, nil, nil\n\t}\n\tscenariosJSON, err := strconv.Unquote(scenariosJSON)\n\tif err != nil {\n\t\treturn false, nil, fmt.Errorf(\"unqouting K6_INSTANCE_SCENARIOS: %w\", err)\n\t}\n\n\tvar scenarios []struct {\n\t\tID       string `json:\"id\"`\n\t\tBrowsers []struct {\n\t\t\tHandle string `json:\"handle\"`\n\t\t} `json:\"browsers\"`\n\t}\n\tif err := json.Unmarshal([]byte(scenariosJSON), &scenarios); err != nil {\n\t\treturn false, nil, fmt.Errorf(\"parsing K6_INSTANCE_SCENARIOS: %w\", err)\n\t}\n\n\tvar wsURLs []string\n\tfor _, s := range scenarios {\n\t\tfor _, b := range s.Browsers {\n\t\t\tif strings.TrimSpace(b.Handle) == \"\" {\n\t\t\t\tcontinue\n\t\t\t}","sourceCodeStart":108,"sourceCodeEnd":144,"githubUrl":"https://github.com/grafana/k6/blob/93accf6570dcd306ca5e99cc44c393ee3797761b/internal/js/modules/k6/browser/browser/registry.go#L108-L144","documentation":"Error \"unqouting K6_INSTANCE_SCENARIOS: %w\" thrown in grafana/k6.","triggerScenarios":"Thrown at internal/js/modules/k6/browser/browser/registry.go:126 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"}