{"record":{"id":"25503c8f01806929","repo":"grafana/k6","slug":"group-and-check-names-may-not-contain","errorCode":null,"errorMessage":"group and check names may not contain '::'","messagePattern":"group and check names may not contain '::'","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"lib/models.go","lineNumber":29,"sourceCode":"\t\"time\"\n\n\t\"gopkg.in/guregu/null.v3\"\n\n\t\"go.k6.io/k6/v2/lib/types\"\n)\n\n// GroupSeparator for group IDs.\nconst GroupSeparator = \"::\"\n\n// RootGroupPath is the id of the root group\n//\n// Note(@mstoykov): the constant shouldn't be used in all tests in order to not couple the tests too much with it.\n// Changing this will be a breaking change and in this way it will be more obvious.\nconst RootGroupPath = \"\"\n\nvar (\n\t// ErrNameContainsGroupSeparator is emitted if you attempt to instantiate a Group or Check that contains the separator.\n\tErrNameContainsGroupSeparator = errors.New(\"group and check names may not contain '\" + GroupSeparator + \"'\")\n\n\t// ErrCheckGroupIsNil is emitted if you attempt to instantiate a Check (see NewCheck) with a nil Group.\n\tErrCheckGroupIsNil = errors.New(\"check's group must not be nil\")\n)\n\n// StageFields defines the fields used for a Stage; this is a dumb hack to make the JSON code\n// cleaner. pls fix.\ntype StageFields struct {\n\t// Duration of the stage.\n\tDuration types.NullDuration `json:\"duration\"`\n\n\t// If Valid, the VU count will be linearly interpolated towards this value.\n\tTarget null.Int `json:\"target\"`\n}\n\n// A Stage defines a step in a test's timeline.\ntype Stage StageFields\n","sourceCodeStart":11,"sourceCodeEnd":47,"githubUrl":"https://github.com/grafana/k6/blob/01ffac6f245854c1b8adc6a69857c76a15f90022/lib/models.go#L11-L47","documentation":"Sentinel error (ErrNameContainsGroupSeparator) returned when a group or check name contains the '::' separator, which k6 reserves for building hierarchical group IDs. It fires from NewGroupPath or when exporting a JS object whose keys (used as group/check names) contain '::'.","triggerScenarios":"Thrown at lib/models.go:29 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Remove any '::' from group() and check() names in the script","Use a single ':' or another separator character in names","Rename the exported JS object keys that k6 interprets as group/check names"],"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"}