mirror of https://github.com/k3s-io/k3s
Merge pull request #36734 from YuPengZTE/devPunctuation
Automatic merge from submit-queue error strings should not end with punctuation **What this PR does / why we need it**: Delete the end punctuation of error strings **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes # **Special notes for your reviewer**: https://github.com/golang/go/wiki/CodeReviewComments#error-strings **Release note**: ```release-note ``` Signed-off-by: yupeng <yu.peng36@zte.com.cn>pull/6/head
commit
96cfe7b938
|
@ -183,7 +183,7 @@ func getRemoteKubeletConfig(s *options.KubeletServer, kubeDeps *kubelet.KubeletD
|
|||
if kubeDeps != nil && kubeDeps.Cloud != nil {
|
||||
instances, ok := kubeDeps.Cloud.Instances()
|
||||
if !ok {
|
||||
err = fmt.Errorf("failed to get instances from cloud provider, can't determine nodename.")
|
||||
err = fmt.Errorf("failed to get instances from cloud provider, can't determine nodename")
|
||||
return nil, err
|
||||
}
|
||||
nodename, err = instances.CurrentNodeName(hostname)
|
||||
|
@ -754,7 +754,7 @@ func RunKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *kubelet
|
|||
// NewMainKubelet should have set up a pod source config if one didn't exist
|
||||
// when the builder was run. This is just a precaution.
|
||||
if kubeDeps.PodConfig == nil {
|
||||
return fmt.Errorf("failed to create kubelet, pod source config was nil!")
|
||||
return fmt.Errorf("failed to create kubelet, pod source config was nil")
|
||||
}
|
||||
podCfg := kubeDeps.PodConfig
|
||||
|
||||
|
|
|
@ -413,7 +413,7 @@ func (g openAPITypeWriter) generateProperty(m *types.Member) error {
|
|||
}
|
||||
switch t.Kind {
|
||||
case types.Builtin:
|
||||
return fmt.Errorf("please add type %v to getOpenAPITypeFormat function.", t)
|
||||
return fmt.Errorf("please add type %v to getOpenAPITypeFormat function", t)
|
||||
case types.Map:
|
||||
if err := g.generateMapProperty(t); err != nil {
|
||||
return err
|
||||
|
@ -425,7 +425,7 @@ func (g openAPITypeWriter) generateProperty(m *types.Member) error {
|
|||
case types.Struct, types.Interface:
|
||||
g.generateReferenceProperty(t)
|
||||
default:
|
||||
return fmt.Errorf("cannot generate spec for type %v.", t)
|
||||
return fmt.Errorf("cannot generate spec for type %v", t)
|
||||
}
|
||||
g.Do("},\n},\n", nil)
|
||||
return g.Error()
|
||||
|
|
|
@ -141,9 +141,9 @@ func getDnsZone(dnsZoneName string, dnsZoneID string, dnsZonesInterface dnsprovi
|
|||
}
|
||||
|
||||
if len(dnsZones) == 0 {
|
||||
return nil, fmt.Errorf("DNS zone %s not found.", name)
|
||||
return nil, fmt.Errorf("DNS zone %s not found", name)
|
||||
} else {
|
||||
return nil, fmt.Errorf("DNS zone %s is ambiguous (please specify zoneID).", name)
|
||||
return nil, fmt.Errorf("DNS zone %s is ambiguous (please specify zoneID)", name)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -421,7 +421,7 @@ func (s *ServiceController) init() error {
|
|||
}
|
||||
zones, ok := s.dns.Zones()
|
||||
if !ok {
|
||||
return fmt.Errorf("the dns provider does not support zone enumeration, which is required for creating dns records.")
|
||||
return fmt.Errorf("the dns provider does not support zone enumeration, which is required for creating dns records")
|
||||
}
|
||||
s.dnsZones = zones
|
||||
matchingZones, err := getDnsZones(s.zoneName, s.zoneID, s.dnsZones)
|
||||
|
|
|
@ -519,13 +519,13 @@ type kops struct {
|
|||
|
||||
func NewKops() (*kops, error) {
|
||||
if *kopsPath == "" {
|
||||
return nil, fmt.Errorf("--kops must be set to a valid binary path for kops deployment.")
|
||||
return nil, fmt.Errorf("--kops must be set to a valid binary path for kops deployment")
|
||||
}
|
||||
if *kopsCluster == "" {
|
||||
return nil, fmt.Errorf("--kops-cluster must be set to a valid cluster name for kops deployment.")
|
||||
return nil, fmt.Errorf("--kops-cluster must be set to a valid cluster name for kops deployment")
|
||||
}
|
||||
if *kopsState == "" {
|
||||
return nil, fmt.Errorf("--kops-state must be set to a valid S3 path for kops deployment.")
|
||||
return nil, fmt.Errorf("--kops-state must be set to a valid S3 path for kops deployment")
|
||||
}
|
||||
sshKey := *kopsSSHKey
|
||||
if sshKey == "" {
|
||||
|
|
Loading…
Reference in New Issue