{"id":"5f86aea3e39682ac","repo":"docker/cli","slug":"cannot-configure-multiple-ranges-s-s-on-the-s","errorCode":null,"errorMessage":"cannot configure multiple ranges (%s, %s) on the same subnet (%s)","messagePattern":"cannot configure multiple ranges \\((.+?), (.+?)\\) on the same subnet \\((.+?)\\)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/command/network/create.go","lineNumber":181,"sourceCode":"\t\t}\n\t\tiData[s] = &network.IPAMConfig{Subnet: sn, AuxAddress: map[string]netip.Addr{}}\n\t}\n\n\t// Validate and add valid ip ranges\n\tfor _, r := range options.ipRanges {\n\t\tmatch := false\n\t\tfor _, s := range options.subnets {\n\t\t\tok, err := subnetMatches(s, r.String())\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\t\tif !ok {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\t// Using \"IsValid\" to check if a valid IPRange was already set.\n\t\t\tif iData[s].IPRange.IsValid() {\n\t\t\t\treturn nil, fmt.Errorf(\"cannot configure multiple ranges (%s, %s) on the same subnet (%s)\", r.String(), iData[s].IPRange.String(), s)\n\t\t\t}\n\t\t\tif ipRange, ok := toPrefix(r); ok {\n\t\t\t\tiData[s].IPRange = ipRange\n\t\t\t\tmatch = true\n\t\t\t}\n\t\t}\n\t\tif !match {\n\t\t\treturn nil, fmt.Errorf(\"no matching subnet for range %s\", r.String())\n\t\t}\n\t}\n\n\t// Validate and add valid gateways\n\tfor _, g := range options.gateways {\n\t\tmatch := false\n\t\tfor _, s := range options.subnets {\n\t\t\tok, err := subnetMatches(s, g.String())\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err","sourceCodeStart":163,"sourceCodeEnd":199,"githubUrl":"https://github.com/docker/cli/blob/e9452d6e785f6e365712b9d71bd7517591773c86/cli/command/network/create.go#L163-L199","documentation":"Error \"cannot configure multiple ranges (%s, %s) on the same subnet (%s)\" thrown in docker/cli.","triggerScenarios":"Thrown at cli/command/network/create.go:181 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}