{"id":"97a60bf27e0ca042","repo":"docker/cli","slug":"empty-section-between-colons","errorCode":null,"errorMessage":"empty section between colons","messagePattern":"empty section between colons","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/volumespec/volumespec.go","lineNumber":60,"sourceCode":"\t\t\tbuffer = buffer[:0] // reset, but reuse capacity\n\t\tdefault:\n\t\t\tbuffer = append(buffer, char)\n\t\t}\n\t}\n\n\tpopulateType(&volume)\n\treturn volume, nil\n}\n\nfunc isWindowsDrive(buffer []rune, char rune) bool {\n\treturn char == ':' && len(buffer) == 1 && unicode.IsLetter(buffer[0])\n}\n\nfunc populateFieldFromBuffer(char rune, buffer []rune, volume *VolumeConfig) error {\n\tstrBuffer := string(buffer)\n\tswitch {\n\tcase len(buffer) == 0:\n\t\treturn errors.New(\"empty section between colons\")\n\t// Anonymous volume\n\tcase volume.Source == \"\" && char == endOfSpec:\n\t\tvolume.Target = strBuffer\n\t\treturn nil\n\tcase volume.Source == \"\":\n\t\tvolume.Source = strBuffer\n\t\treturn nil\n\tcase volume.Target == \"\":\n\t\tvolume.Target = strBuffer\n\t\treturn nil\n\tcase char == ':':\n\t\treturn errors.New(\"too many colons\")\n\t}\n\tfor option := range strings.SplitSeq(strBuffer, \",\") {\n\t\tswitch option {\n\t\tcase \"ro\":\n\t\t\tvolume.ReadOnly = true\n\t\tcase \"rw\":","sourceCodeStart":42,"sourceCodeEnd":78,"githubUrl":"https://github.com/docker/cli/blob/e9452d6e785f6e365712b9d71bd7517591773c86/internal/volumespec/volumespec.go#L42-L78","documentation":"Error \"empty section between colons\" thrown in docker/cli.","triggerScenarios":"Thrown at internal/volumespec/volumespec.go:60 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"e9452d6e785f6e365712b9d71bd7517591773c86","analyzedAt":"2026-08-01T07:09:22.474Z","schemaVersion":2}