{"record":{"id":"e4bc99af73ea0224","repo":"kubernetes/kops","slug":"getting-instance-s-s-s-w","errorCode":null,"errorMessage":"getting instance %s/%s/%s: %w","messagePattern":"getting instance (.+?)/(.+?)/(.+?): %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/kops-controller/controllers/gceipam.go","lineNumber":118,"sourceCode":"\t\t// e.g. providerID: gce://example-project-id/us-west2-a/instance-id\n\t\tproviderURL, err := url.Parse(node.Spec.ProviderID)\n\t\tif err != nil {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"parsing providerID %q: %w\", node.Spec.ProviderID, err)\n\t\t}\n\t\ttokens := strings.Split(strings.Trim(providerURL.Path, \"/\"), \"/\")\n\t\tif len(tokens) != 2 {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"unexpected format for providerID %q\", node.Spec.ProviderID)\n\t\t}\n\t\tproject := providerURL.Host\n\t\tzone := tokens[0]\n\t\tinstanceID := tokens[1]\n\t\tif project == \"\" || zone == \"\" || instanceID == \"\" {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"unexpected format for providerID %q\", node.Spec.ProviderID)\n\t\t}\n\n\t\tinstance, err := r.gceClient.Instances.Get(project, zone, instanceID).Context(ctx).Do()\n\t\tif err != nil {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"getting instance %s/%s/%s: %w\", project, zone, instanceID, err)\n\t\t}\n\n\t\tvar ipv6Addresses []string\n\t\tfor _, nic := range instance.NetworkInterfaces {\n\t\t\tfor _, ipv6AccessConfig := range nic.Ipv6AccessConfigs {\n\t\t\t\tif ipv6AccessConfig.ExternalIpv6 != \"\" {\n\t\t\t\t\tipv6Address := fmt.Sprintf(\"%s/%d\", ipv6AccessConfig.ExternalIpv6, ipv6AccessConfig.ExternalIpv6PrefixLength)\n\t\t\t\t\tipv6Addresses = append(ipv6Addresses, ipv6Address)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif len(ipv6Addresses) == 0 {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"no ipv6 address found on interface %q\", instance.NetworkInterfaces[0].Name)\n\t\t}\n\t\tif len(ipv6Addresses) != 1 {\n\t\t\treturn ctrl.Result{}, fmt.Errorf(\"multiple ipv6 addresses found on interface %q: %v\", instance.NetworkInterfaces[0].Name, ipv6Addresses)\n\t\t}","sourceCodeStart":100,"sourceCodeEnd":136,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/cmd/kops-controller/controllers/gceipam.go#L100-L136","documentation":"The GCE IPAM reconciler's call to the GCE compute API to fetch the instance (identified from the node's providerID) failed. Inputs were validated; this wraps a GCE API error such as the instance being deleted, permissions, or transient API failure.","triggerScenarios":"Thrown at cmd/kops-controller/controllers/gceipam.go:118 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the wrapped GCE API error for the exact cause","Verify the instance still exists in the project/zone","Check the service account's compute.instance.get permissions"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T12:17:11.808Z"}