{"record":{"id":"dc86f6f40f1253c0","repo":"kubernetes/kops","slug":"rendering-volume-w","errorCode":null,"errorMessage":"rendering volume: %w","messagePattern":"rendering volume: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"upup/pkg/fi/cloudup/scalewaytasks/volume.go","lineNumber":131,"sourceCode":"\t\t\tVolumeID: fi.ValueOf(actual.ID),\n\t\t\tName:     expected.Name,\n\t\t\tTags:     new(expected.Tags),\n\t\t\tSize:     scw.SizePtr(scw.Size(fi.ValueOf(expected.Size))),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"updating volume %s (%s): %w\", *actual.Name, *actual.ID, err)\n\t\t}\n\n\t} else {\n\t\t_, err := instanceService.CreateVolume(&instance.CreateVolumeRequest{\n\t\t\tZone:       zone,\n\t\t\tName:       fi.ValueOf(expected.Name),\n\t\t\tVolumeType: instance.VolumeVolumeType(fi.ValueOf(expected.Type)),\n\t\t\tSize:       scw.SizePtr(scw.Size(fi.ValueOf(expected.Size))),\n\t\t\tTags:       expected.Tags,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"rendering volume: %w\", err)\n\t\t}\n\t}\n\n\treturn nil\n}\n\ntype terraformVolume struct {\n\tName     *string  `cty:\"name\"`\n\tSizeInGB *int     `cty:\"size_in_gb\"`\n\tType     *string  `cty:\"type\"`\n\tTags     []string `cty:\"tags\"`\n\tBoot     *bool    `cty:\"boot\"`\n}\n\nfunc (_ *Volume) RenderTerraform(t *terraform.TerraformTarget, actual, expected, changes *Volume) error {\n\ttfName := strings.ReplaceAll(fi.ValueOf(expected.Name), \".\", \"-\")\n\ttf := &terraformVolume{\n\t\tName:     expected.Name,","sourceCodeStart":113,"sourceCodeEnd":149,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/upup/pkg/fi/cloudup/scalewaytasks/volume.go#L113-L149","documentation":"kOps wraps errors from the Scaleway instance API when creating a new volume in RenderScw. The CreateVolume call failed inside scaleway-sdk-go; kOps reports it as a 'rendering' failure because it happens while rendering the volume task during a `kops update cluster` run.","triggerScenarios":"RenderScw determines the volume does not exist yet and calls instanceService.CreateVolume with zone/name/type/size/tags; the Scaleway API rejects or fails — invalid zone, quota exceeded, invalid volume type, or transient API error.","commonSituations":"Cluster spec targets a zone where the project has no quota; unsupported volume type string in the spec; Scaleway API outage or rate limiting; project limit for total volume size reached.","solutions":["Inspect the wrapped SDK error; if it is a quota/limit error, raise the volume quota for your Scaleway project or reduce the requested size.","Verify the zone in the cluster spec is a valid Scaleway availability zone for the project.","Confirm the volume type (e.g. sbs_volume/legacy b_ssd) is valid for the account; older types may be deprecated.","Retry after a transient 429/5xx; use exponential backoff via re-running `kops update cluster`."],"exampleFix":"// before: unsupported/legacy type\nvolumeType: b_ssd\n// after: current supported type\nvolumeType: sbs_volume","handlingStrategy":"validation","validationCode":"// validate zone and size before CreateVolume\nvalidZones := map[string]bool{\"fr-par-1\": true, \"nl-ams-1\": true, \"pl-waw-2\": true}\nif !validZones[zone] {\n    return fmt.Errorf(\"invalid Scaleway zone %q\", zone)\n}\nif fi.ValueOf(expected.Size) < minVolumeGB {\n    return fmt.Errorf(\"volume size %d below Scaleway minimum\", fi.ValueOf(expected.Size))\n}","typeGuard":null,"tryCatchPattern":"vol, err := instanceService.CreateVolume(&instance.CreateVolumeRequest{...})\nif err != nil {\n    var apiErr *sdk.Error\n    if errors.As(err, &apiErr) && (apiErr.StatusCode == 429 || apiErr.StatusCode >= 500) {\n        // retry with backoff\n    }\n    return fmt.Errorf(\"rendering volume: %w\", err)\n}","preventionTips":["Validate zone and volume type against current Scaleway offerings","Monitor project quota for volume count/size","Retry transient API failures with backoff"],"tags":["scaleway","storage","cloud-api"],"backgroundTag":"cloud-api-create-failed","analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T07:17:12.445Z"}