jiebi/CodeConvo huggingface dataset:
Change:
glog.Infof("[cpumanager] detected CPU topology: %v", topo) reservedCPUs, ok := nodeAllocatableReservation[v1.ResourceCPU] if !ok { <del> // The static policy cannot initialize without this information. Panic! panic("[cpumanager] unable to determine reserved CPU resources for static policy") </del> <ins> // The static policy cannot initialize without this information. return nil, fmt.Errorf("[cpumanager] unable to determine reserved CPU resources for static policy") </ins> } if reservedCPUs.IsZero() { <del> // Panic! // </del> // The static policy requires this to be nonzero. Zero CPU reservation // would allow the shared pool to be completely exhausted. At that point // either we would violate our guarantee of exclusivity or need to evict // any pod that has at least one container that requires zero CPUs. // See the comments in policy_static.go for more details. <del> panic("[cpumanager] the static policy requires systemreserved.cpu + kubereserved.cpu to be greater than zero") </del> <ins> return nil, fmt.Errorf("[cpumanager] the static policy requires systemreserved.cpu + kubereserved.cpu to be greater than zero") </ins> } // Take the ceiling of the reservation, since fractional CPUs cannot be

Discussion:
Is this a BUG REPORT or FEATURE REQUEST?: /kind bug What happened: When enable cpumanager by , but not set and , kubelet will get panic error in log What you expected to happen: Should graceful exit with error not panic. How to reproduce it (as minimally and precisely as possible): set and but not set and Anything else we need to know?:
/sig node
Great that it's not panicing anymore, but I'd also love to get the "requires + to be greater than zero" hint in this particular case. It looks like even with this doesn't seem to be the case (since it errors out with the non-actionable "unable to determine reserved CPU resources for static policy". Should I open another issue for this?
Change:
# Golang - name: "golang: upstream version" <del> version: 1.22 </del> <ins> version: 1.22.0 </ins> refPaths: - path: .go-version - path: build/build-image/cross/VERSION

Discussion:
https://prow.ppc64le- Tests are not getting executed due to improper go version. It has been failing since past 4 days. No response No response No response /sig node
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the label and provide further guidance. The label can be by org members by writing in a comment. <detailsInstructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details
This seems to be failing due to improper version addition in dependency files where is instead of at some places. I will raise a PR for it.
/assign
fixing that
Change:
func main() { command := newCommand() if err := command.Execute(); err != nil { <del> fmt.Fprintf(os.Stderr, "error: %vn", err) </del> os.Exit(1) } }

Discussion:
<!-- Please use this template while reporting a bug and provide as much info as possible. Not doing so may result in your bug not being addressed in a timely manner. Thanks! If the matter is security related, please disclose it privately via --What happened: kubectl version --client=yes command is giving the following error message. Error message is repeated at the start and the end and also containing programming jargon Error: invalid argument "yes" for "--client" flag: strconv.ParseBool: parsing "yes": invalid syntax Examples: Print the client and server versions for the current context kubectl version Options: --client=false: Client version only (no server required). -o, --output='': One of 'yaml' or 'json'. --short=false: Print just the version number. Usage: kubectl version [flags] [options] Use "kubectl options" for a list of global command-line options (applies to all commands). invalid argument "yes" for "--client" flag: strconv.ParseBool: parsing "yes": invalid syntax What you expected to happen: The error message can be improved with one of the two variants invalid argument "yes" for "--client" flag Examples: Print the client and server versions for the current context kubectl version Options: --client=false: Client version only (no server required). -o, --output='': One of 'yaml' or 'json'. --short=false: Print just the version number. Usage: kubectl version [flags] [options] Use "kubectl options" for a list of global command-line options (applies to all commands). (or) Invalid argument "yes" for "--client" flag How to reproduce it (as minimally and precisely as possible): Run the command kubectl version --client=yes Anything else we need to know?: Environment: Kubernetes version (use ): 1.15 Cloud provider or hardware configuration: AWS OS (e.g: ): Amazon Linux Kernel (e.g. ): Install tools: Network plugin and version (if this is a network-related bug): Others:
/sig cli
Hi Thanks for posting this issue! It turns out that this duplicate output has been in kubectl, and all the other cli cmds, since . This should be fixed by , and hopefully we can cherry pick it back to at least .
Change:
// How long a pod is allowed to become "running" and "ready" after a node // restart before test is considered failed. RestartPodReadyAgainTimeout = 5 * time.Minute <ins> // Number of times we want to retry Updates in case of conflict UpdateRetries = 5 </ins> ) var (

Discussion:
https://k8s- Failed: [] SchedulerPredicates [Serial] validates that NodeSelector is respected if matching [Conformance] {Kubernetes e2e suite}
Change:
} func getConformanceData(targetFrame frame) (*ConformanceData, error) { <del> // TODO: This is terribly hacky.  Why can't we rely on the --source flag in // all cases? https://issues.k8s.io/123567 // // Filenames may be in a couple special places, depending on if they were // built dockerized or with the host go.  We want to trim this prefix to // produce portable relative paths. containerGopath := "/go/src/k8s.io/kubernetes/_output/dockerized/go/src/k8s.io/kubernetes/" </del> root := *k8sPath if !strings.HasSuffix(root, string(os.PathSeparator)) { root += string(os.PathSeparator) } trimmedFile := strings.TrimPrefix(targetFrame.File, root) <del> trimmedFile = strings.TrimPrefix(trimmedFile, containerGopath) </del> targetFrame.File = trimmedFile freader, err := os.Open(targetFrame.File)

Discussion:
has code which takes a flag called but it tries to hunt for the file in both "local" and "dockerized" places. This doesn't feel right. /cc /cc
/triage accepted
Change:
return pod } <del> // Patch client pod with a map value func updateNetworkClientPodLabel(f *framework.Framework, namespace *v1.Namespace, podName string, patchOperation string, patchPath string, patchValue map[string]string) *v1.Pod { </del> <ins> // Patch pod with a map value func updatePodLabel(f *framework.Framework, namespace *v1.Namespace, podName string, patchOperation string, patchPath string, patchValue map[string]string) *v1.Pod { </ins> type patchMapValue struct { Op    string            `json:"op"` Path  string            `json:"path"`

Discussion:
<!-- Please use this template while reporting a bug and provide as much info as possible. Not doing so may result in your bug not being addressed in a timely manner. Thanks! If the matter is security related, please disclose it privately via --What happened: The NetworkPolicy e2e test fails regardless of which CNI plugin is enabled. The test assumes the client Pod can recheck connectivity after updating its label, but the client won't restart after the first failure, so the second check will always fail. What you expected to happen: The test should succeed if a CNI plugin implements NetworkPolicy correctly. How to reproduce it (as minimally and precisely as possible): a CNI that supports NetworkPolicy. the e2e test by focusing "should allow ingress access from updated pod". test will always fail. Anything else we need to know?: Environment: Kubernetes version (use ): 16.3 Cloud provider or hardware configuration: OS (e.g: ): Kernel (e.g. ): Install tools: Network plugin and version (if this is a network-related bug): Others:
/sig testing /assign
/remove-sig testing /sig network
/triage unresolved Comment when the issue is assessed and confirmed. I am a bot run by vllry. ‍
/remove-triage unresolved
I see this in Calico 3.10 as well confirming that its definitely an issue.
Change:
} } if !found { <del> log.Fatalf("%v dependency: file %v doesn't contain the expected version %v or matcher %v did change. check the %v file", dep.Name, refPath.Path, dep.Version, refPath.Match, externalDepsFilePath) </del> <ins> pathsToUpdate = append(pathsToUpdate, refPath.Path) </ins> } } <ins> if len(pathsToUpdate) > 0 { log.Fatalf(mismatchErrorMessage, externalDepsFilePath, dep.Name, dep.Version, strings.Join(pathsToUpdate, "n"), dep.Name, externalDepsFilePath) } </ins> } }

Discussion:
What would you like to be : The current error message is vague and could be improved. (credit to Why is this needed: Improve contributor experience, make it easier to identify change to be fixed. /cc
/assign
Change:
"k8s.io/client-go/tools/cache" watchtools "k8s.io/client-go/tools/watch" "k8s.io/klog/v2" <ins> "k8s.io/kubernetes/pkg/kubelet/kuberuntime" </ins> "k8s.io/kubernetes/test/e2e/framework" e2epod "k8s.io/kubernetes/test/e2e/framework/pod"

Discussion:
Also appears to be failing on: Failures as of 01/05. /kind failing-test <!-- If this is a flake, please add: /kind flake --/sig node
/triage accepted /priority important-soon Guessing since all tests with apparmor started failing - maybe app armor config was removed or some PR submitted recently.
/assign
ci-cri-containerd-node-e2e-features Last green run: First failed run:
This () is the only PR merged in kubernetes during the time between: Test started yesterday at 8:11 PM passed after 13m50s. (more info) Test started yesterday at 9:11 PM failed after 16m6s. (more info) And it happens to be related to AppArmor:
Working on a fix in
Change:
// NewConverter creates a new Converter object. func NewConverter() *Converter { <del> return &Converter{ </del> <ins> c := &Converter{ </ins> conversionFuncs:    map[typePair]reflect.Value{}, defaultingFuncs:    map[reflect.Type]reflect.Value{}, nameFunc:           func(t reflect.Type) string { return t.Name() },

Discussion:
E.g., it calls Convert() for every byte of a slice of uint8. E0330 22:15:23. 5352 ] TIM: converting bool E0330 22:15:23. 5352 ] TIM: converting []v1.NamedExtension E0330 22:15:23. 5352 ] TIM: converting []v1.NamedCluster E0330 22:15:23. 5352 ] TIM: converting []v1.NamedCluster E0330 22:15:23. 5352 ] TIM: converting v1.Cluster E0330 22:15:23. 5352 ] TIM: converting v1.Cluster E0330 22:15:23. 5352 ] TIM: converting string E0330 22:15:23. 5352 ] TIM: converting string E0330 22:15:23. 5352 ] TIM: converting bool E0330 22:15:23. 5352 ] TIM: converting string E0330 22:15:23. 5352 ] TIM: converting []uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 E0330 22:15:23.

5352 ] TIM: converting uint8 E0330 22:15:23. 5352 ] TIM: converting uint8 ... thousands of these.
There's an easy fix for this :/
Change:
fi } <ins> # outputs md5 hash of $1, works on macOS and Linux function kube::util::md5() { if which md5 >/dev/null 2>&1; then md5 -q "$1" else md5sum "$1" | awk '{ print $1 }' fi } </ins> # kube::util::read-array # Reads in stdin and adds it line by line to the array provided. This can be # used instead of "mapfile -t", and is bash 3 compatible.

Discussion:
<!-- Please use this template while reporting a bug and provide as much info as possible. Not doing so may result in your bug not being addressed in a timely manner. Thanks! If the matter is security related, please disclose it privately via --What happened: run on macOS, all md5 hashes will be stripped from the output and the script will not fail or warn. What you expected to happen: The script should work or detect this issue and fail. Currently it silently ignores not existing on the host. We have some warning logic, but solely based on bash version, if the user upgraded their bash installation but did not install md5sum we don't warn them. How to reproduce it (as minimally and precisely as possible): run the script Anything else we need to know?: Environment: Kubernetes version (use ): Cloud provider or hardware configuration: OS (e.g: ): Kernel (e.g. ): Install tools: Network plugin and version (if this is a network-related bug): Others: /sig testing /priority important-longterm /assign
cc
Change:
"github.com/stretchr/testify/require" <ins> "k8s.io/apimachinery/pkg/util/wait" </ins> "k8s.io/klog" registerapi "k8s.io/kubernetes/pkg/kubelet/apis/pluginregistration/v1" )

Discussion:
What happened: A race condition in the plugin watcher might happen when a is created, started and immediately stopped and cleaned up. If executed several times, the unit test will expose this issue. The PR addressed part of the problem by serializing the handling of CREATE and DELETE events. However, a race might still happen in the function. describes in detail the problem. How to reproduce it (as minimally and precisely as possible): /sig storage /sig node
/assign
Change:
return url.String() } <del> // updateURLs checks and updates any of n's attributes that are listed in tagsToAttrs. // Any URLs found are, if they share the source host, updated with the necessary changes // to make a visit to that URL also go through the proxy. // sourceURL is the URL of the page which we're currently on. func (t *Transport) updateURLs(n *html.Node, sourceURL *url.URL) { if n.Type != html.ElementNode { return } attrs, ok := tagsToAttrs[n.Data] if !ok { return } for i, attr := range n.Attr { if !attrs.Has(attr.Key) { continue </del> <ins> // rewriteHTML scans the HTML for tags with url-valued attributes, and updates // those values with the urlRewriter function. The updated HTML is output to the // writer. func rewriteHTML(reader io.Reader, writer io.Writer, urlRewriter func(string) string) error { // Note: This assumes the content is UTF-8. tokenizer := html.NewTokenizer(reader) var err error for err == nil { tokenType := tokenizer.Next() switch tokenType { case html.ErrorToken: err = tokenizer.Err() case html.StartTagToken, html.SelfClosingTagToken: token := tokenizer.Token() if urlAttrs, ok := atomsToAttrs[token.DataAtom]; ok { for i, attr := range token.Attr { if urlAttrs.Has(attr.Key) { token.Attr[i].Val = urlRewriter(attr.Val) } } } _, err = writer.Write([]byte(token.String())) default: _, err = writer.Write(tokenizer.Raw()) </ins> } <del> n.Attr[i].Val = t.rewriteURL(attr.Val, sourceURL) </del> } <del> } // scan recursively calls f for every n and every subnode of n. func (t *Transport) scan(n *html.Node, f func(*html.Node)) { f(n) for c := n.FirstChild; c != nil; c = c.NextSibling { t.scan(c, f) </del> <ins> if err != io.EOF { return err </ins> } <ins> return nil </ins> } <del> // fixLinks modifies links in an HTML file such that they will be redirected through the proxy if needed. func (t *Transport) fixLinks(req *http.Request, resp *http.Response) (*http.Response, error) { </del> <ins> // rewriteResponse modifies an HTML response by updating absolute links refering // to the original host to instead refer to the proxy transport. func (t *Transport) rewriteResponse(req *http.Request, resp *http.Response) (*http.Response, error) { </ins> origBody := resp.Body defer origBody.Close()

Discussion:
The ApiServer proxy wraps partial HTML responses to serve a complete HTML document in the proxy response. This is problematic for applications which expect HTML fragments, such as with AngularJS templates. Example: This is the response for a from the unproxied server: But the proxied response is: This issue is blocking
Change:
- 1 - 2 - 3 <ins> - description: sort nested pointers of ints original: mergeItemPtr: - name: 2 mergingIntList: - 1 - 3 - 2 - name: 1 mergingIntList: - 2 - 1 sorted: mergeItemPtr: - name: 1 mergingIntList: - 1 - 2 - name: 2 mergingIntList: - 1 - 2 - 3 - description: sort one pointer of maps original: mergeItemPtr: - name: 1 - name: 3 - name: 2 sorted: mergeItemPtr: - name: 1 - name: 2 - name: 3 </ins> `) func TestStrategicMergePatch(t *testing.T) {

Discussion:
PATCH http://IP:8080/api/v1beta3/namespaces/dev--ea6f-49cb-b5bb-/replicationcontrollers/redis-master {"spec":{"replicas":0}} answer: { "kind": "Status", "apiVersion": "v1beta3", "metadata": {}, "status": "Failure", "message": "the server responded with the status code 415 but did not return more information", "details": {}, "code": 415 } Before v0.15.0 it had worked well.
That error is returned by go-restful because it did not find any valid route with the same content type as specified in the request: Can you try setting the content-type in your request as is described here: cc
well, I've the same issue which is not fixed by setting the value, at least with the "strategic merge patch". Here's the request: Here's the response body: And here's the log trace of the request in the apiserver pod:
Come from a typo, purposed PR here:
Btw, I'm still having strange issues with sub-objects. Note that it appears only is the sub-object is already set. Here's the request: Here's the API log:
Looks like a bug in strategic merge -- it doesn't deal with pointers correctly:
cc
is it possible to have a milestone for this so I can tell if I should merger ? Thanks.
Change:
}}, }}, RestartPolicy: v1.RestartPolicyNever, <del> }}, metav1.CreateOptions{}) </del> <ins> }} _, err := f.ClientSet.CoreV1().Pods(ns).Create(context.TODO(), pod, metav1.CreateOptions{}) </ins> framework.ExpectNoError(err, "failed to create pod") <del> err = wait.PollImmediate(podRetryPeriod, podRetryTimeout, checkPodStatus(f, "test=response")) framework.ExpectNoError(err, "Pod didn't start within time out period") </del> <ins> framework.ExpectNoError(e2epod.WaitForPodRunningInNamespace(f.ClientSet, pod), "Pod didn't start within time out period") </ins> framework.Logf("Creating service...") _, err = f.ClientSet.CoreV1().Services(ns).Create(context.TODO(), &v1.Service{

Discussion:
pull-kubernetes-e2e-kind-ipv6 - Not sure. Time out on waiting Pod to be started. No response /sig network
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the label and provide further guidance. The label can be by org members by writing in a comment. <detailsInstructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details
Change:
"//staging/src/k8s.io/apimachinery/pkg/util/diff:go_default_library", "//staging/src/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", "//vendor/github.com/davecgh/go-spew/spew:go_default_library", <ins> "//vendor/github.com/stretchr/testify/assert:go_default_library", "//vendor/github.com/stretchr/testify/require:go_default_library", </ins> ], )

Discussion:
/kind bug What happened: In , there are tests for {Default,}AllowPrivilegeEscalation fields, but those in actually test the AllowPrivilegeEscalation as this is set in the test instead of testing its suggested Default* form, thus being mostly redundant to tests in . On top of that, part of the tests in test a scenario which is not allowed, that being are wrong due to but since this is assigned directly, it was never validated and thus no errors were found. What you expected to happen: There are no redundant or incorrect tests in . Environment: Kubernetes version: master
/sig auth
Resolved by
Change:
"reason":                   events.ContainerProbeWarning, }.AsSelector().String() framework.ExpectNoError(e2eevents.WaitTimeoutForEvent( <del> f.ClientSet, f.Namespace.Name, expectedEvent, "0.0.0.0", framework.PodEventTimeout)) </del> <ins> f.ClientSet, f.Namespace.Name, expectedEvent, "Probe terminated redirects, Response body: <a href="http://0.0.0.0/">Found</a>.", framework.PodEventTimeout)) </ins> }) /*

Discussion:
<!-- Please use this template while reporting a bug and provide as much info as possible. Not doing so may result in your bug not being addressed in a timely manner. Thanks! If the matter is security related, please disclose it privately via --Used a HTTP probe with external redirect: Got warning: Kubelet logs show: Warning messages either show additional context or don't show . I would probably have expected or just Not a big deal, just a bit confusing message Apply yaml above Kubernetes version (use ): v1.22.0-beta.1 Cloud provider or hardware configuration: kind OS (e.g: ): linux Kernel (e.g. ): 5.10.40 Install tools: kind /sig node
According to See and
thanks! I am not concerned about the actual implementation behavior, but rather the event: . We should not have an event ending with as it denotes there is more information to follow, but there is not.
Got it. /assign
/triage accepted I send to fix this issue.
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules: After 90d of inactivity, is applied After 30d of inactivity since was applied, is applied After 30d of inactivity since was applied, the issue is closed You can: Mark this issue or PR as fresh with Mark this issue or PR as rotten with Close this issue or PR with Offer to help out with [Issue Triage][1] Please send feedback to sig-contributor-experience at . /lifecycle stale [1]:
In 1.18 (because of EKS long term support I don't really want to get into), I get this: This is mildly aggravating, as it means I get fourteen lines of warning logs indicating that a service which exists solely to provide redirects is working as expected. Does this bug mean that I'll instead get an even more aggravating warning when I eventually upgrade? :) I found this bug while looking for a way to tell the probe that "getting a 308 or 302 or <insert one or a list of values heremeans success". It'd be ideal in my mind if the httpget probe allowed an "ok return values array" which accepted either single values or ranges, perhaps with a default value like .

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules: After 90d of inactivity, is applied After 30d of inactivity since was applied, is applied After 30d of inactivity since was applied, the issue is closed You can: Mark this issue or PR as fresh with Close this issue or PR with Offer to help out with [Issue Triage][1] Please send feedback to sig-contributor-experience at . /lifecycle rotten [1]:
Change:
) } <ins> func TestFilterOut(t *testing.T) { type Test struct { name            string input           []string x               string expected        []string expectedChanged bool } for _, tt := range []Test{ {"nil", nil, "foo", nil, false}, {"empty", []string{}, "foo", []string{}, false}, {"foo", []string{"foo"}, "foo", nil, true}, {"aaa", []string{"a", "a", "a"}, "a", nil, true}, {"abc", []string{"a", "b", "c"}, "c", []string{"a", "b"}, true}, {"abbbcc", []string{"a", "b", "b", "b", "c", "c"}, "b", []string{"a", "c", "c"}, true}, } { t.Run(tt.name, func(t *testing.T) { got, gotChanged := filterOut(tt.input, tt.x) if !reflect.DeepEqual(tt.expected, got) { t.Errorf("expected slice %v, got %v", tt.expected, got) } if tt.expectedChanged != gotChanged { t.Errorf("expected changed %v, got %v", tt.expected, got) } }) } } </ins> func max(i, j int) int { if i > j { return i

Discussion:
When doing in an OpenShift cluster with a nullable field being required (compare ) and of value null, one gets:
cc
is there a way to also fix the faulty kubectl validation in 1.18.x?