Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package kor for openSUSE:Factory checked in 
at 2024-08-07 06:10:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/kor (Old)
 and      /work/SRC/openSUSE:Factory/.kor.new.7232 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "kor"

Wed Aug  7 06:10:21 2024 rev:22 rq:1191793 version:0.5.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/kor/kor.changes  2024-07-26 16:16:21.635783734 
+0200
+++ /work/SRC/openSUSE:Factory/.kor.new.7232/kor.changes        2024-08-07 
06:10:52.195484655 +0200
@@ -1,0 +2,12 @@
+Tue Aug 06 05:53:28 UTC 2024 - opensuse_buildserv...@ojkastl.de
+
+- Update to version 0.5.4:
+  * chore: update chart version pre-release (#342)
+  * Feat: Enhance unused jobs discovery (#336)
+  * docs(README): Update release badges & ClusterRole aggregation
+    (#340)
+  * revert: Update chart release workflow (#339)
+  * Update chart release workflow (#338)
+  * update chart version 0.5.3 (#337)
+
+-------------------------------------------------------------------

Old:
----
  kor-0.5.3.obscpio

New:
----
  kor-0.5.4.obscpio

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ kor.spec ++++++
--- /var/tmp/diff_new_pack.oAyb9y/_old  2024-08-07 06:10:53.391534462 +0200
+++ /var/tmp/diff_new_pack.oAyb9y/_new  2024-08-07 06:10:53.391534462 +0200
@@ -19,7 +19,7 @@
 %define __arch_install_post export NO_BRP_STRIP_DEBUG=true
 
 Name:           kor
-Version:        0.5.3
+Version:        0.5.4
 Release:        0
 Summary:        Tool to discover unused Kubernetes Resources
 License:        MIT

++++++ _service ++++++
--- /var/tmp/diff_new_pack.oAyb9y/_old  2024-08-07 06:10:53.423535794 +0200
+++ /var/tmp/diff_new_pack.oAyb9y/_new  2024-08-07 06:10:53.427535961 +0200
@@ -3,9 +3,9 @@
     <param name="url">https://github.com/yonahd/kor</param>
     <param name="scm">git</param>
     <param name="exclude">.git</param>
-    <param name="revision">v0.5.3</param>
-    <!-- the helm-related tag kor-0.1.10 is sitting on the same commit... -->
-    <param name="match-tag">v0.5.3</param>
+    <param name="revision">v0.5.4</param>
+    <!-- the helm-related tag kor-0.1.xx is sitting on the same commit... -->
+    <param name="match-tag">v0.5.4</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="changesgenerate">enable</param>
     <param name="versionrewrite-pattern">v(.*)</param>

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.oAyb9y/_old  2024-08-07 06:10:53.447536794 +0200
+++ /var/tmp/diff_new_pack.oAyb9y/_new  2024-08-07 06:10:53.451536961 +0200
@@ -1,6 +1,6 @@
 <servicedata>
 <service name="tar_scm">
                 <param name="url">https://github.com/yonahd/kor</param>
-              <param 
name="changesrevision">93e7d8066142e3225ec04e7d699ff2843db97a81</param></service></servicedata>
+              <param 
name="changesrevision">fbc63c921294011ba57bc41ac4e72aa40634a187</param></service></servicedata>
 (No newline at EOF)
 

++++++ kor-0.5.3.obscpio -> kor-0.5.4.obscpio ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kor-0.5.3/README.md new/kor-0.5.4/README.md
--- old/kor-0.5.3/README.md     2024-07-25 19:58:13.000000000 +0200
+++ new/kor-0.5.4/README.md     2024-08-04 21:46:10.000000000 +0200
@@ -1,5 +1,6 @@
 ![GitHub go.mod Go version (subdirectory of 
monorepo)](https://img.shields.io/github/go-mod/go-version/yonahd/kor)
-![GitHub release (with 
filter)](https://img.shields.io/github/v/release/yonahd/kor?color=green&link=https://github.com/yonahd/kor/releases)
+![GitHub 
Release](https://img.shields.io/github/v/release/yonahd/kor?filter=v*&color=green&link=https://github.com/yonahd/kor/releases)
+![GitHub 
Release](https://img.shields.io/github/v/release/yonahd/kor?filter=kor-*&logo=Helm&color=green&link=https://github.com/yonahd/kor/releases)
 ![Docker Pulls](https://img.shields.io/docker/pulls/yonahdissen/kor)
 
[![codecov](https://codecov.io/gh/yonahd/kor/branch/main/graph/badge.svg?token=tNKcOjlxLo)](https://codecov.io/gh/yonahd/kor)
 
[![Discord](https://discord.com/api/guilds/1159544275722321990/embed.png)](https://discord.gg/ajptYPwcJY)
@@ -166,14 +167,14 @@
 | ServiceAccounts | ServiceAccounts unused by Pods<br/>ServiceAccounts unused 
by roleBinding or clusterRoleBinding                                            
                                                                                
        |                                                                       
                                                                                
                |
 | StatefulSets    | Statefulsets with no Replicas                              
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
 | Roles           | Roles not used in roleBinding                              
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
-| ClusterRoles    | ClusterRoles not used in roleBinding or clusterRoleBinding 
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
+| ClusterRoles    | ClusterRoles not used in roleBinding or 
clusterRoleBinding<br/>ClusterRoles not used in ClusterRole aggregation         
                                                                                
                                                                               
|                                                                               
                                                                                
        |
 | PVCs            | PVCs not used in Pods                                      
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
 | Ingresses       | Ingresses not pointing at any Service                      
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
 | Hpas            | HPAs not used in Deployments<br/> HPAs not used in 
StatefulSets                                                                    
                                                                                
               |                                                                
                                                                                
                       |
 | CRDs            | CRDs not used the cluster                                  
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
 | Pvs             | PVs not bound to a PVC                                     
                                                                                
                                                                                
       |                                                                        
                                                                                
               |
 | Pdbs            | PDBs not used in Deployments<br/> PDBs not used in 
StatefulSets                                                                    
                                                                                
               |                                                                
                                                                                
                       |
-| Jobs            | Jobs status is completed<br/>  Jobs failed with no retries 
left                                                                            
                                                                                
                                             |                                  
                                                                                
                                                     |
+| Jobs            | Jobs status is completed<br/>  Jobs status is 
suspended<br/>  Jobs failed with backoff limit exceeded (including indexed 
jobs) <br/> Jobs failed with dedaline exceeded                                  
                                                                                
                            |                                                   
                                                                                
                                    |
 | ReplicaSets     | replicaSets that specify replicas to 0 and has already 
completed it's work                                                             
                                                                                
           |
 | DaemonSets      | DaemonSets not scheduled on any nodes                      
                                                                                
                                                                                
       |
 | StorageClasses  | StorageClasses not used by any PVs/PVCs                    
                                                                                
                                                                                
       |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kor-0.5.3/charts/kor/Chart.yaml 
new/kor-0.5.4/charts/kor/Chart.yaml
--- old/kor-0.5.3/charts/kor/Chart.yaml 2024-07-25 19:58:13.000000000 +0200
+++ new/kor-0.5.4/charts/kor/Chart.yaml 2024-08-04 21:46:10.000000000 +0200
@@ -2,8 +2,8 @@
 name: kor
 description: A Kubernetes Helm Chart to discover orphaned resources using kor
 type: application
-version: 0.1.10
-appVersion: "0.5.2"
+version: 0.1.12
+appVersion: "0.5.4"
 maintainers:
   - name: "yonahd"
     url: "https://github.com/yonahd/kor";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kor-0.5.3/charts/kor/README.md 
new/kor-0.5.4/charts/kor/README.md
--- old/kor-0.5.3/charts/kor/README.md  2024-07-25 19:58:13.000000000 +0200
+++ new/kor-0.5.4/charts/kor/README.md  2024-08-04 21:46:10.000000000 +0200
@@ -1,6 +1,6 @@
 # kor
 
-![Version: 
0.1.10](https://img.shields.io/badge/Version-0.1.10-informational?style=flat-square)
 ![Type: 
application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
 ![AppVersion: 
0.5.2](https://img.shields.io/badge/AppVersion-0.5.2-informational?style=flat-square)
+![Version: 
0.1.12](https://img.shields.io/badge/Version-0.1.12-informational?style=flat-square)
 ![Type: 
application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
 ![AppVersion: 
0.5.4](https://img.shields.io/badge/AppVersion-0.5.4-informational?style=flat-square)
 
 A Kubernetes Helm Chart to discover orphaned resources using kor
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kor-0.5.3/pkg/kor/jobs.go 
new/kor-0.5.4/pkg/kor/jobs.go
--- old/kor-0.5.3/pkg/kor/jobs.go       2024-07-25 19:58:13.000000000 +0200
+++ new/kor-0.5.4/pkg/kor/jobs.go       2024-08-04 21:46:10.000000000 +0200
@@ -7,6 +7,7 @@
        "encoding/json"
        "fmt"
        "os"
+       "slices"
 
        batchv1 "k8s.io/api/batch/v1"
        metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
@@ -52,11 +53,16 @@
                        unusedJobNames = append(unusedJobNames, 
ResourceInfo{Name: job.Name, Reason: reason})
                        continue
                } else {
-                       // Check if the job has a condition indicating it has 
exceeded the backoff limit
+                       failureReasons := []string{"BackoffLimitExceeded", 
"DeadlineExceeded", "FailedIndexes"}
+
+                       // Check if the job has a condition indicating it has 
failed
                        for _, condition := range job.Status.Conditions {
-                               if condition.Type == batchv1.JobFailed && 
condition.Reason == "BackoffLimitExceeded" {
-                                       reason := "Job has exceeded backoff 
limit"
-                                       unusedJobNames = append(unusedJobNames, 
ResourceInfo{Name: job.Name, Reason: reason})
+                               if condition.Type == batchv1.JobFailed && 
slices.Contains(failureReasons, condition.Reason) {
+                                       unusedJobNames = append(unusedJobNames, 
ResourceInfo{Name: job.Name, Reason: condition.Message})
+                                       break
+                               }
+                               if condition.Type == batchv1.JobSuspended {
+                                       unusedJobNames = append(unusedJobNames, 
ResourceInfo{Name: job.Name, Reason: condition.Message})
                                        break
                                }
                        }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kor-0.5.3/pkg/kor/jobs_test.go 
new/kor-0.5.4/pkg/kor/jobs_test.go
--- old/kor-0.5.3/pkg/kor/jobs_test.go  2024-07-25 19:58:13.000000000 +0200
+++ new/kor-0.5.4/pkg/kor/jobs_test.go  2024-08-04 21:46:10.000000000 +0200
@@ -90,6 +90,60 @@
                t.Fatalf("Error creating fake job: %v", err)
        }
 
+       job6 := CreateTestJob(testNamespace, "test-job6", &batchv1.JobStatus{
+               Succeeded: 0,
+               Failed:    1,
+               Conditions: []batchv1.JobCondition{
+                       {
+                               Type:    batchv1.JobFailed,
+                               Status:  corev1.ConditionTrue,
+                               Reason:  "DeadlineExceeded",
+                               Message: "Job was active longer than specified 
deadline",
+                       },
+               },
+       }, AppLabels)
+
+       _, err = clientset.BatchV1().Jobs(testNamespace).Create(context.TODO(), 
job6, v1.CreateOptions{})
+       if err != nil {
+               t.Fatalf("Error creating fake job: %v", err)
+       }
+
+       job7 := CreateTestJob(testNamespace, "test-job7", &batchv1.JobStatus{
+               Succeeded: 0,
+               Failed:    1,
+               Conditions: []batchv1.JobCondition{
+                       {
+                               Type:    batchv1.JobFailed,
+                               Status:  corev1.ConditionTrue,
+                               Reason:  "FailedIndexes",
+                               Message: "Job has failed indexes",
+                       },
+               },
+       }, AppLabels)
+
+       _, err = clientset.BatchV1().Jobs(testNamespace).Create(context.TODO(), 
job7, v1.CreateOptions{})
+       if err != nil {
+               t.Fatalf("Error creating fake job: %v", err)
+       }
+
+       job8 := CreateTestJob(testNamespace, "test-job8", &batchv1.JobStatus{
+               Succeeded: 0,
+               Failed:    1,
+               Conditions: []batchv1.JobCondition{
+                       {
+                               Type:    batchv1.JobSuspended,
+                               Status:  corev1.ConditionTrue,
+                               Reason:  "JobSuspended",
+                               Message: "Job suspended",
+                       },
+               },
+       }, AppLabels)
+
+       _, err = clientset.BatchV1().Jobs(testNamespace).Create(context.TODO(), 
job8, v1.CreateOptions{})
+       if err != nil {
+               t.Fatalf("Error creating fake job: %v", err)
+       }
+
        return clientset
 }
 
@@ -101,12 +155,16 @@
                t.Errorf("Expected no error, got %v", err)
        }
 
-       if len(unusedJobs) != 3 {
-               t.Errorf("Expected 3 jobs unused got %d", len(unusedJobs))
+       expectedJobsNames := []string{"test-job2", "test-job4", "test-job5", 
"test-job6", "test-job7", "test-job8"}
+
+       if len(unusedJobs) != len(expectedJobsNames) {
+               t.Errorf("Expected %d jobs unused got %d", 
len(expectedJobsNames), len(unusedJobs))
        }
 
-       if unusedJobs[0].Name != "test-job2" && unusedJobs[1].Name != 
"test-job4" && unusedJobs[2].Name != "test-job5" {
-               t.Errorf("job2', got %s", unusedJobs[0])
+       for i, job := range unusedJobs {
+               if job.Name != expectedJobsNames[i] {
+                       t.Errorf("Expected %s, got %s", expectedJobsNames[i], 
job.Name)
+               }
        }
 }
 
@@ -133,6 +191,9 @@
                                "test-job2",
                                "test-job4",
                                "test-job5",
+                               "test-job6",
+                               "test-job7",
+                               "test-job8",
                        },
                },
        }

++++++ kor.obsinfo ++++++
--- /var/tmp/diff_new_pack.oAyb9y/_old  2024-08-07 06:10:53.607543457 +0200
+++ /var/tmp/diff_new_pack.oAyb9y/_new  2024-08-07 06:10:53.611543624 +0200
@@ -1,5 +1,5 @@
 name: kor
-version: 0.5.3
-mtime: 1721930293
-commit: 93e7d8066142e3225ec04e7d699ff2843db97a81
+version: 0.5.4
+mtime: 1722800770
+commit: fbc63c921294011ba57bc41ac4e72aa40634a187
 

++++++ vendor.tar.gz ++++++
/work/SRC/openSUSE:Factory/kor/vendor.tar.gz 
/work/SRC/openSUSE:Factory/.kor.new.7232/vendor.tar.gz differ: char 5, line 1

Reply via email to