Hello community,

here is the log from the commit of package yast2-network for openSUSE:Factory 
checked in at 2016-10-13 11:25:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-network (Old)
 and      /work/SRC/openSUSE:Factory/.yast2-network.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-network"

Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-network/yast2-network.changes      
2016-09-24 15:18:45.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-network.new/yast2-network.changes 
2016-10-13 11:25:53.000000000 +0200
@@ -1,0 +2,36 @@
+Mon Oct 10 09:11:29 UTC 2016 - mfi...@suse.com
+
+- do not duplicate work of network service at the beginning of
+  AutoYaST's second stage - not loading modules and so on.
+- 3.2.4
+
+-------------------------------------------------------------------
+Fri Oct  7 15:16:11 UTC 2016 - kanders...@suse.com
+
+- If an interface is not configured yet then just set the interface
+  link, the backend should handle at least the up event.
+  (bsc#991694)
+- 3.2.3
+
+-------------------------------------------------------------------
+Fri Oct  7 15:12:05 UTC 2016 - an...@suse.com
+
+- Extra space in the remote administration dialog (bsc#988904)
+
+-------------------------------------------------------------------
+Thu Oct  6 09:22:25 UTC 2016 - mfi...@suse.com
+
+- Use full interface up / down instead of setting just link
+  up / down to allow proper update of interface's configuration.
+  (bsc#991694)
+- 3.2.2
+
+-------------------------------------------------------------------
+Wed Oct  5 13:49:08 UTC 2016 - an...@suse.com
+
+- If WIFI is configured during installation, make sure the packages
+  required for WIFI to work are installed in the resulting system
+  (bsc#1002700)
+- 3.2.1
+
+-------------------------------------------------------------------
@@ -5 +41 @@
-- 3.1.171
+- 3.2.0

Old:
----
  yast2-network-3.1.171.tar.bz2

New:
----
  yast2-network-3.2.4.tar.bz2

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

Other differences:
------------------
++++++ yast2-network.spec ++++++
--- /var/tmp/diff_new_pack.h2zVCD/_old  2016-10-13 11:25:54.000000000 +0200
+++ /var/tmp/diff_new_pack.h2zVCD/_new  2016-10-13 11:25:54.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-network
-Version:        3.1.171
+Version:        3.2.4
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build

++++++ yast2-network-3.1.171.tar.bz2 -> yast2-network-3.2.4.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/package/yast2-network.changes 
new/yast2-network-3.2.4/package/yast2-network.changes
--- old/yast2-network-3.1.171/package/yast2-network.changes     2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/package/yast2-network.changes       2016-10-12 
14:00:20.000000000 +0200
@@ -1,8 +1,44 @@
 -------------------------------------------------------------------
+Mon Oct 10 09:11:29 UTC 2016 - mfi...@suse.com
+
+- do not duplicate work of network service at the beginning of
+  AutoYaST's second stage - not loading modules and so on.
+- 3.2.4
+
+-------------------------------------------------------------------
+Fri Oct  7 15:16:11 UTC 2016 - kanders...@suse.com
+
+- If an interface is not configured yet then just set the interface
+  link, the backend should handle at least the up event.
+  (bsc#991694)
+- 3.2.3
+
+-------------------------------------------------------------------
+Fri Oct  7 15:12:05 UTC 2016 - an...@suse.com
+
+- Extra space in the remote administration dialog (bsc#988904)
+
+-------------------------------------------------------------------
+Thu Oct  6 09:22:25 UTC 2016 - mfi...@suse.com
+
+- Use full interface up / down instead of setting just link
+  up / down to allow proper update of interface's configuration.
+  (bsc#991694)
+- 3.2.2
+
+-------------------------------------------------------------------
+Wed Oct  5 13:49:08 UTC 2016 - an...@suse.com
+
+- If WIFI is configured during installation, make sure the packages
+  required for WIFI to work are installed in the resulting system
+  (bsc#1002700)
+- 3.2.1
+
+-------------------------------------------------------------------
 Wed Sep 21 09:57:30 UTC 2016 - jreidin...@suse.com
 
 - reduce rpm build time (bsc#999203)
-- 3.1.171
+- 3.2.0
 
 -------------------------------------------------------------------
 Wed Sep  7 11:23:16 UTC 2016 - mfi...@suse.com
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/package/yast2-network.spec 
new/yast2-network-3.2.4/package/yast2-network.spec
--- old/yast2-network-3.1.171/package/yast2-network.spec        2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/package/yast2-network.spec  2016-10-12 
14:00:20.000000000 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package yast2-network
 #
-# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-network
-Version:        3.1.171
+Version:        3.2.4
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
@@ -52,7 +52,7 @@
 Requires:       yast2-packager >= 3.1.47
 
 # testsuite
-BuildRequires:       rubygem(rspec)
+BuildRequires:  rubygem(rspec)
 
 PreReq:         /bin/rm
 
@@ -64,6 +64,8 @@
 Obsoletes:      yast2-network-devel-doc
 
 Summary:        YaST2 - Network Configuration
+License:        GPL-2.0
+Group:          System/YaST
 
 %description 
 This package contains the YaST2 component for network configuration.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/src/clients/inst_netprobe.rb 
new/yast2-network-3.2.4/src/clients/inst_netprobe.rb
--- old/yast2-network-3.1.171/src/clients/inst_netprobe.rb      2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/clients/inst_netprobe.rb        1970-01-01 
01:00:00.000000000 +0100
@@ -1,69 +0,0 @@
-# encoding: utf-8
-
-# ***************************************************************************
-#
-# Copyright (c) 2012 Novell, Inc.
-# All Rights Reserved.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of version 2 of the GNU General Public License as
-# published by the Free Software Foundation.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.   See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, contact Novell, Inc.
-#
-# To contact Novell about this file by physical or electronic mail,
-# you may find current contact information at www.novell.com
-#
-# **************************************************************************
-# File:        clients/inst_netprobe
-# Package:     Network configuration
-# Summary:     Start the network detection
-# Authors:     Michal Svec <ms...@suse.cz>
-#
-module Yast
-  class InstNetprobeClient < Client
-    def main
-      Yast.import "UI"
-
-      textdomain "network"
-
-      Yast.import "NetHwDetection"
-
-      Yast.include self, "network/routines.rb"
-
-      Builtins.y2milestone("----------------------------------------")
-      Builtins.y2milestone("Lan netprobe module started")
-      Builtins.y2milestone("Args: %1", WFM.Args)
-
-      @succeeded = true
-
-      if !NetHwDetection.running
-        if !NetHwDetection.Start
-          Builtins.y2milestone("Network hardware detection failed.")
-          @succeeded = false
-        end
-      end
-
-      if NetHwDetection.running
-        # Start interfaces iff running installation. See bnc#395014, 
bnc#782283 and bnc#792985
-        SetAllLinksUp()
-      end
-
-      Builtins.y2milestone(
-        "Lan netprobe module finished ... %1",
-        @succeeded ? "OK" : "Failed"
-      )
-      Builtins.y2milestone("----------------------------------------")
-
-      :auto
-    end
-  end
-end
-
-Yast::InstNetprobeClient.new.main
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-network-3.1.171/src/include/network/lan/wizards.rb 
new/yast2-network-3.2.4/src/include/network/lan/wizards.rb
--- old/yast2-network-3.1.171/src/include/network/lan/wizards.rb        
2016-09-21 13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/include/network/lan/wizards.rb  2016-10-12 
14:00:20.000000000 +0200
@@ -53,13 +53,14 @@
     # @return successfully finished
     def LanSequence
       aliases = {
-        "read"     => [-> { ReadDialog() }, true],
-        "main"     => -> { MainSequence("") },
-        "packages" => [-> { PackagesInstall(Lan.Packages) }, true],
-        "write"    => [-> { WriteDialog() }, true]
+        "read"  => [-> { ReadDialog() }, true],
+        "main"  => -> { MainSequence("") },
+        "write" => [-> { WriteDialog() }, true]
       }
 
       if Mode.installation || Mode.update
+        aliases["packages"] = [-> { add_pkgs_to_proposal(Lan.Packages) }, true]
+
         sequence = {
           "ws_start" => "read",
           "read"     => { abort: :abort, back: :back, next: "main" },
@@ -70,6 +71,8 @@
 
         Wizard.OpenNextBackDialog
       else
+        aliases["packages"] = [-> { PackagesInstall(Lan.Packages) }, true]
+
         sequence = {
           "ws_start" => "read",
           "read"     => { abort: :abort, next: "main" },
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-network-3.1.171/src/include/network/remote/dialogs.rb 
new/yast2-network-3.2.4/src/include/network/remote/dialogs.rb
--- old/yast2-network-3.1.171/src/include/network/remote/dialogs.rb     
2016-09-21 13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/include/network/remote/dialogs.rb       
2016-10-12 14:00:20.000000000 +0200
@@ -57,6 +57,8 @@
 
       allow_buttons = RadioButtonGroup(
         VBox(
+          # Small spacing (bsc#988904)
+          VSpacing(0.3),
           # RadioButton label
           Left(
             RadioButton(
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-network-3.1.171/src/include/network/routines.rb 
new/yast2-network-3.2.4/src/include/network/routines.rb
--- old/yast2-network-3.1.171/src/include/network/routines.rb   2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/include/network/routines.rb     2016-10-12 
14:00:20.000000000 +0200
@@ -50,6 +50,7 @@
       Yast.import "IP"
       Yast.import "TypeRepository"
       Yast.import "Stage"
+      Yast.import "PackagesProposal"
     end
 
     # Abort function
@@ -104,6 +105,16 @@
       nil
     end
 
+    # Adds the packages to the software proposal to make sure they are 
available
+    # in the installed system
+    # @param [Array<String>] packages list of required packages (["rpm", 
"bash"])
+    # @return :next in any case
+    def add_pkgs_to_proposal(packages)
+      log.info "Adding network packages to proposal: #{packages}"
+      PackagesProposal.AddResolvables("network", :package, packages) unless 
packages.empty?
+      :next
+    end
+
     # Check if required packages are installed and install them if they're not
     # @param [Array<String>] packages list of required packages (["rpm", 
"bash"])
     # @return `next if packages installation is successfull, `abort otherwise
@@ -711,36 +722,41 @@
       end
     end
 
+    # Wrapper to call 'ip link set up' with the given interface
+    #
+    # @param [String] name of interface to 'set link up'
     def SetLinkUp(dev_name)
       log.info("Setting link up for interface #{dev_name}")
       Run("ip link set #{dev_name} up")
     end
 
+    # Wrapper to call 'ip link set down' with the given interface
+    #
+    # @param [String] name of interface to 'set link down'
     def SetLinkDown(dev_name)
       log.info("Setting link down for interface #{dev_name}")
       Run("ip link set #{dev_name} down")
     end
 
-    # Tries to set all available interfaces up
+    # Calls wicked ifup with the given interface
     #
-    # @return [boolean] false if some of interfaces cannot be set up
-    def SetAllLinksUp
-      interfaces = GetAllInterfaces()
-
-      return false if interfaces.empty?
-
-      interfaces.all? { |i| SetLinkUp(i) }
+    # @param [String] name of interface to put down
+    def SetIfaceUp(dev_name)
+      log.info("Setting interface #{dev_name} up")
+      Run("ifup #{dev_name}")
     end
 
-    # Tries to set all available interfaces down
+    # Calls wicked ifdown with the given interface
     #
-    # @return [boolean] false if some of interfaces cannot be set down
-    def SetAllLinksDown
-      interfaces = GetAllInterfaces()
-
-      return false if interfaces.empty?
+    # @param [String] name of interface to put down
+    def SetIfaceDown(dev_name)
+      log.info("Setting interface #{dev_name} down")
+      Run("ifdown #{dev_name}")
+    end
 
-      interfaces.all? { |i| SetLinkDown(i) }
+    # Tries to set the link up of all available interfaces
+    def SetAllLinksUp
+      GetAllInterfaces().each { |i| SetLinkUp(i) }
     end
 
     # Checks if given device has carrier
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/src/lib/network/wicked.rb 
new/yast2-network-3.2.4/src/lib/network/wicked.rb
--- old/yast2-network-3.1.171/src/lib/network/wicked.rb 2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/lib/network/wicked.rb   2016-10-12 
14:00:20.000000000 +0200
@@ -8,8 +8,8 @@
 
     # Reloads configuration for each device named in devs
     #
-    # @devs [Array] list of device names
-    # @return true if configuration was reloaded
+    # @param [Array] list of device names
+    # @return [Boolean] true if configuration was reloaded; false otherwise
     def reload_config(devs)
       raise ArgumentError if devs.nil?
       return true if devs.empty?
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/src/modules/LanItems.rb 
new/yast2-network-3.2.4/src/modules/LanItems.rb
--- old/yast2-network-3.1.171/src/modules/LanItems.rb   2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/src/modules/LanItems.rb     2016-10-12 
14:00:20.000000000 +0200
@@ -430,7 +430,13 @@
       operator = new_key == "NAME" ? "=" : "=="
       current_rule = getUdevFallback
       rule = RemoveKeyFromUdevRule(getUdevFallback, replace_key)
+
+      # NAME="devname" has to be last in the rule.
+      # otherwise SCR agent .udev_persistent.net returns crap
+      # isn't that fun
+      name_tuple = rule.pop
       new_rule = AddToUdevRule(rule, "#{new_key}#{operator}\"#{new_val}\"")
+      new_rule.push(name_tuple)
 
       log.info("ReplaceItemUdev: new udev rule = #{new_rule}")
 
@@ -543,7 +549,7 @@
           # removing is less error prone when tracking name changes, so it was 
chosen.
           item_udev_net = RemoveKeyFromUdevRule(item_udev_net, "KERNEL")
           # setting links down during AY is forbidden bcs it can freeze ssh 
installation
-          SetLinkDown(dev_name) if !Mode.autoinst
+          SetIfaceDown(dev_name) if !Mode.autoinst
 
           @force_restart = true
         end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/test/edit_nic_name_test.rb 
new/yast2-network-3.2.4/test/edit_nic_name_test.rb
--- old/yast2-network-3.1.171/test/edit_nic_name_test.rb        2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/test/edit_nic_name_test.rb  2016-10-12 
14:00:20.000000000 +0200
@@ -19,10 +19,11 @@
       NetworkInterfaces.as_null_object
 
       # mock devices configuration
-      allow(LanItems).to receive(:ReadHardware) { [{ "dev_name" => 
CURRENT_NAME }] }
+      allow(LanItems).to receive(:ReadHardware) { [{ "dev_name" => 
CURRENT_NAME, "mac" => "00:01:02:03:04:05" }] }
       allow(LanItems).to receive(:getNetworkInterfaces) { [CURRENT_NAME] }
       allow(LanItems).to receive(:GetItemUdev) { "" }
       allow(LanItems).to receive(:GetItemUdev).with("NAME") { CURRENT_NAME }
+      allow(LanItems).to receive(:GetItemUdev).with("ATTR{address}") { 
"00:01:02:03:04:05" }
 
       # LanItems initialization
       Yast.import "LanItems"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/test/link_handlers_test.rb 
new/yast2-network-3.2.4/test/link_handlers_test.rb
--- old/yast2-network-3.1.171/test/link_handlers_test.rb        2016-09-21 
13:38:52.000000000 +0200
+++ new/yast2-network-3.2.4/test/link_handlers_test.rb  2016-10-12 
14:00:20.000000000 +0200
@@ -20,12 +20,12 @@
   end
 
   it "returns true if PHY layer is available" do
-    allow(Yast::SCR).to receive(:Read).with(path(".target.string"), 
/\/sys\/class\/net/) { 1 }
+    allow(subject).to receive(:has_carrier?).and_return true
     expect(subject.phy_connected?("enp0s3")).to eql true
   end
 
-  it "returns false if PHY layer is available" do
-    allow(Yast::SCR).to receive(:Read).with(path(".target.string"), 
/\/sys\/class\/net/) { 0 }
+  it "returns false if PHY layer is not available" do
+    allow(subject).to receive(:has_carrier?).and_return false
     expect(subject.phy_connected?("enp0s3")).to eql false
   end
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/test/udev_test.rb 
new/yast2-network-3.2.4/test/udev_test.rb
--- old/yast2-network-3.1.171/test/udev_test.rb 2016-09-21 13:38:53.000000000 
+0200
+++ new/yast2-network-3.2.4/test/udev_test.rb   2016-10-12 14:00:20.000000000 
+0200
@@ -152,4 +152,25 @@
 
     expect(Yast::LanItems).not_to receive(:SetModified)
   end
+
+  # this is an SCR limitation
+  it "contains NAME tuplet at last position" do
+    allow(Yast::LanItems)
+      .to receive(:getUdevFallback)
+      .and_return(
+        [
+          "ATTR{address}==\"xx:01:02:03:04:05\"",
+          "KERNEL=\"eth*\"",
+          "NAME=\"eth1\""
+        ]
+      )
+
+    updated_rule = Yast::LanItems.ReplaceItemUdev(
+      "KERNELS",
+      "ATTR{address}",
+      "xx:01:02:03:04:AA"
+    )
+
+    expect(updated_rule.last).to match(/NAME.*/)
+  end
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-network-3.1.171/test/wicked_test.rb 
new/yast2-network-3.2.4/test/wicked_test.rb
--- old/yast2-network-3.1.171/test/wicked_test.rb       1970-01-01 
01:00:00.000000000 +0100
+++ new/yast2-network-3.2.4/test/wicked_test.rb 2016-10-12 14:00:20.000000000 
+0200
@@ -0,0 +1,29 @@
+#!/usr/bin/env rspec
+
+require_relative "test_helper"
+
+require "yast"
+require "network/wicked"
+
+class DummyNetwork
+  include Yast::Wicked
+end
+
+describe "#reload_config" do
+  let(:subject) { DummyNetwork.new }
+
+  it "raises ArgumentError if dev names parameter is nil" do
+    expect { subject.reload_config(nil) }.to raise_error("ArgumentError")
+  end
+
+  it "returns true if given device names are empty" do
+    expect(subject.reload_config([])).to eql(true)
+  end
+
+  it "returns true if given devices reload successfully" do
+    expect(Yast::SCR).to receive(:Execute)
+      .with(DummyNetwork::BASH_PATH, "wicked ifreload eth0 eth1").and_return(0)
+
+    expect(subject.reload_config(["eth0", "eth1"])).to eql(true)
+  end
+end


Reply via email to