Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package okteto for openSUSE:Factory checked 
in at 2022-10-21 16:20:10
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/okteto (Old)
 and      /work/SRC/openSUSE:Factory/.okteto.new.2275 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "okteto"

Fri Oct 21 16:20:10 2022 rev:30 rq:1030381 version:2.8.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/okteto/okteto.changes    2022-10-20 
11:11:50.544035576 +0200
+++ /work/SRC/openSUSE:Factory/.okteto.new.2275/okteto.changes  2022-10-21 
16:20:18.986259371 +0200
@@ -1,0 +2,7 @@
+Fri Oct 21 10:55:46 UTC 2022 - ka...@b1-systems.de
+
+- Update to version 2.8.2:
+  * logs: add logs to syncthing terminating process (#3184) (#3185)
+  * Revert "fix: volumes not being deleted (#2955)" (#3176) (#3181)
+
+-------------------------------------------------------------------

Old:
----
  okteto-2.8.1.tar.gz

New:
----
  okteto-2.8.2.tar.gz

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

Other differences:
------------------
++++++ okteto.spec ++++++
--- /var/tmp/diff_new_pack.fRrRdT/_old  2022-10-21 16:20:20.058261380 +0200
+++ /var/tmp/diff_new_pack.fRrRdT/_new  2022-10-21 16:20:20.062261388 +0200
@@ -19,7 +19,7 @@
 %define __arch_install_post export NO_BRP_STRIP_DEBUG=true
 
 Name:           okteto
-Version:        2.8.1
+Version:        2.8.2
 Release:        0
 Summary:        Develop your applications directly in your Kubernetes Cluster
 License:        Apache-2.0

++++++ _service ++++++
--- /var/tmp/diff_new_pack.fRrRdT/_old  2022-10-21 16:20:20.098261455 +0200
+++ /var/tmp/diff_new_pack.fRrRdT/_new  2022-10-21 16:20:20.102261462 +0200
@@ -3,10 +3,10 @@
     <param name="url">https://github.com/okteto/okteto</param>
     <param name="scm">git</param>
     <param name="exclude">.git</param>
-    <param name="revision">2.8.1</param>
+    <param name="revision">2.8.2</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="changesgenerate">enable</param>
-    <param name="match-tag">2.8.1</param>
+    <param name="match-tag">2.8.2</param>
   </service>
   <service name="set_version" mode="disabled">
     <param name="basename">okteto</param>
@@ -16,7 +16,7 @@
     <param name="compression">gz</param>
   </service>
   <service name="go_modules" mode="disabled">
-    <param name="archive">okteto-2.8.1.tar.gz</param>
+    <param name="archive">okteto-2.8.2.tar.gz</param>
   </service>
 </services>
 

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.fRrRdT/_old  2022-10-21 16:20:20.122261499 +0200
+++ /var/tmp/diff_new_pack.fRrRdT/_new  2022-10-21 16:20:20.126261507 +0200
@@ -1,6 +1,6 @@
 <servicedata>
 <service name="tar_scm">
                 <param name="url">https://github.com/okteto/okteto</param>
-              <param 
name="changesrevision">459515a8505d6992fc48c67e6bf1a24ca526c8b0</param></service></servicedata>
+              <param 
name="changesrevision">da425cf06ae7e0877a263574ef78fe96e0f1ab3d</param></service></servicedata>
 (No newline at EOF)
 

++++++ okteto-2.8.1.tar.gz -> okteto-2.8.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/okteto-2.8.1/cmd/deploy/proxy.go 
new/okteto-2.8.2/cmd/deploy/proxy.go
--- old/okteto-2.8.1/cmd/deploy/proxy.go        2022-10-19 09:15:06.000000000 
+0200
+++ new/okteto-2.8.2/cmd/deploy/proxy.go        2022-10-21 09:49:41.000000000 
+0200
@@ -227,7 +227,6 @@
 
                // Modify all resources updated or created to include the label.
                if r.Method == "PUT" || r.Method == "POST" {
-                       isCreation := r.Method == "POST"
                        b, err := io.ReadAll(r.Body)
                        if err != nil {
                                oktetoLog.Infof("could not read the request 
body: %s", err)
@@ -240,7 +239,7 @@
                                return
                        }
 
-                       b, err = ph.translateBody(b, isCreation)
+                       b, err = ph.translateBody(b)
                        if err != nil {
                                oktetoLog.Info(err)
                                rw.WriteHeader(500)
@@ -268,7 +267,7 @@
        ph.DivertedNamespace = divertedNamespace
 }
 
-func (ph *proxyHandler) translateBody(b []byte, isCreation bool) ([]byte, 
error) {
+func (ph *proxyHandler) translateBody(b []byte) ([]byte, error) {
        var body map[string]json.RawMessage
        if err := json.Unmarshal(b, &body); err != nil {
                oktetoLog.Infof("error unmarshalling resource body on proxy: 
%s", err.Error())
@@ -291,7 +290,7 @@
                        return nil, err
                }
        case "StatefulSet":
-               if err := ph.translateStatefulSetSpec(body, isCreation); err != 
nil {
+               if err := ph.translateStatefulSetSpec(body); err != nil {
                        return nil, err
                }
        case "Job":
@@ -366,18 +365,13 @@
        return nil
 }
 
-func (ph *proxyHandler) translateStatefulSetSpec(body 
map[string]json.RawMessage, isCreation bool) error {
+func (ph *proxyHandler) translateStatefulSetSpec(body 
map[string]json.RawMessage) error {
        var spec appsv1.StatefulSetSpec
        if err := json.Unmarshal(body["spec"], &spec); err != nil {
                oktetoLog.Infof("error unmarshalling statefulset spec on proxy: 
%s", err.Error())
                return nil
        }
        labels.SetInMetadata(&spec.Template.ObjectMeta, model.DeployedByLabel, 
ph.Name)
-       if isCreation {
-               for idx := range spec.VolumeClaimTemplates {
-                       
labels.SetInMetadata(&spec.VolumeClaimTemplates[idx].ObjectMeta, 
model.DeployedByLabel, ph.Name)
-               }
-       }
        ph.applyDivert(&spec.Template.Spec)
        specAsByte, err := json.Marshal(spec)
        if err != nil {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/okteto-2.8.1/cmd/deploy/proxy_test.go 
new/okteto-2.8.2/cmd/deploy/proxy_test.go
--- old/okteto-2.8.1/cmd/deploy/proxy_test.go   2022-10-19 09:15:06.000000000 
+0200
+++ new/okteto-2.8.2/cmd/deploy/proxy_test.go   2022-10-21 09:49:41.000000000 
+0200
@@ -13,39 +13,20 @@
 
 func Test_TranslateInvalidResourceBody(t *testing.T) {
        var tests = []struct {
-               name       string
-               body       []byte
-               isCreation bool
+               name string
+               body []byte
        }{
                {
-                       name:       "null body json.RawMessage POST",
-                       body:       []byte(``),
-                       isCreation: true,
+                       name: "null body json.RawMessage",
+                       body: []byte(``),
                },
                {
-                       name:       "correct body json.RawMessage POST",
-                       body:       
[]byte(`{"kind":"Secret","apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
-                       isCreation: true,
+                       name: "correct body json.RawMessage",
+                       body: 
[]byte(`{"kind":"Secret","apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
                },
                {
-                       name:       "incorrect body typemeta POST",
-                       body:       []byte(`{"kind": {"key": 
"value"},"apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
-                       isCreation: true,
-               },
-               {
-                       name:       "null body json.RawMessage PUT",
-                       body:       []byte(``),
-                       isCreation: false,
-               },
-               {
-                       name:       "correct body json.RawMessage PUT",
-                       body:       
[]byte(`{"kind":"Secret","apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
-                       isCreation: false,
-               },
-               {
-                       name:       "incorrect body typemeta PUT",
-                       body:       []byte(`{"kind": {"key": 
"value"},"apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
-                       isCreation: false,
+                       name: "incorrect body typemeta",
+                       body: []byte(`{"kind": {"key": 
"value"},"apiVersion":"v1","metadata":{"name":"sh.helm.release.v1.movies.v6"},"type":"helm.sh/release.v1"}`),
                },
        }
 
@@ -53,7 +34,7 @@
                tt := tt
                t.Run(tt.name, func(t *testing.T) {
                        t.Parallel()
-                       _, err := ph.translateBody(tt.body, tt.isCreation)
+                       _, err := ph.translateBody(tt.body)
                        assert.NoError(t, err)
                })
        }
@@ -64,7 +45,7 @@
                "spec": []byte(`{"selector": "invalid value"}`),
        }
        assert.NoError(t, ph.translateDeploymentSpec(invalidResourceSpec))
-       assert.NoError(t, ph.translateStatefulSetSpec(invalidResourceSpec, 
true))
+       assert.NoError(t, ph.translateStatefulSetSpec(invalidResourceSpec))
        assert.NoError(t, 
ph.translateReplicationControllerSpec(invalidResourceSpec))
        assert.NoError(t, ph.translateReplicaSetSpec(invalidResourceSpec))
        assert.NoError(t, ph.translateDaemonSetSpec(invalidResourceSpec))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/okteto-2.8.1/pkg/config/config.go 
new/okteto-2.8.2/pkg/config/config.go
--- old/okteto-2.8.1/pkg/config/config.go       2022-10-19 09:15:06.000000000 
+0200
+++ new/okteto-2.8.2/pkg/config/config.go       2022-10-21 09:49:41.000000000 
+0200
@@ -134,9 +134,12 @@
        }
 
        s := filepath.Join(GetAppHome(dev.Namespace, dev.Name), stateFile)
+
+       oktetoLog.Infof("updating file '%s'", s)
        if err := os.WriteFile(s, []byte(state), 0600); err != nil {
                return fmt.Errorf("failed to update state file: %s", err)
        }
+       oktetoLog.Infof("file '%s' updated successfully", s)
 
        return nil
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/okteto-2.8.1/pkg/syncthing/syncthing.go 
new/okteto-2.8.2/pkg/syncthing/syncthing.go
--- old/okteto-2.8.1/pkg/syncthing/syncthing.go 2022-10-19 09:15:06.000000000 
+0200
+++ new/okteto-2.8.2/pkg/syncthing/syncthing.go 2022-10-21 09:49:41.000000000 
+0200
@@ -793,6 +793,7 @@
 
 // HardTerminate halts the background process, waits for 1s and kills the 
process if it is still running
 func (s *Syncthing) HardTerminate() error {
+       oktetoLog.Info("termitating previous syncthing process")
        pList, err := process.Processes()
        if err != nil {
                return err
@@ -843,6 +844,7 @@
                        oktetoLog.Infof("error terminating syncthing %d with 
wait: %s", p.Pid, err.Error())
                }
                if parent != nil && parent.Pid != int32(pid) {
+                       oktetoLog.Infof("pid: %s / name: %s / cmd: %s", p.Pid, 
p.Name, p.Cmdline)
                        if err := terminate(parent, true); err != nil {
                                oktetoLog.Infof("error terminating syncthing %d 
with wait: %s", p.Pid, err.Error())
                                continue
@@ -857,11 +859,11 @@
 func getParent(p *process.Process) (*process.Process, error) {
        name, err := p.Name()
        if err != nil {
-               return nil, fmt.Errorf("can not get parent name")
+               return nil, fmt.Errorf("can not get name: %w", err)
        }
        parent, err := p.Parent()
        if err != nil {
-               return nil, fmt.Errorf("can not find parent")
+               return nil, fmt.Errorf("can not find parent process: %w", err)
        }
        if runtime.GOOS == "windows" && (parent.Pid == 0 || parent.Pid == 4) {
                return nil, fmt.Errorf("can't remove root process")
@@ -870,9 +872,10 @@
        }
        pName, err := parent.Name()
        if err != nil {
-               oktetoLog.Infof("could not get  parent: %s", err)
+               oktetoLog.Infof("could not get parent name: %w", err)
        }
        if pName == name {
+               oktetoLog.Infof("parent name is the same: %s", name)
                return getParent(parent)
        }
        return parent, nil

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

Reply via email to