Hello community,

here is the log from the commit of package yast2-installation for 
openSUSE:Factory checked in at 2016-07-01 09:57:56
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-installation (Old)
 and      /work/SRC/openSUSE:Factory/.yast2-installation.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-installation"

Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-installation/yast2-installation.changes    
2016-06-13 21:50:10.000000000 +0200
+++ 
/work/SRC/openSUSE:Factory/.yast2-installation.new/yast2-installation.changes   
    2016-07-01 09:57:58.000000000 +0200
@@ -1,0 +2,35 @@
+Mon Jun 27 13:00:24 UTC 2016 - jreidin...@suse.com
+
+- Make writing of bootloader settings the last step so that other
+  installation steps (kdump, cio-ignore) do not have to waste time
+  repeating it
+  (bnc#986649)
+- 3.1.198
+
+-------------------------------------------------------------------
+Thu Jun 23 08:17:24 UTC 2016 - lsle...@suse.cz
+
+- Display more information in the error popup when downloading
+  the optional installer updates fails (bsc#986091)
+- 3.1.197
+
+-------------------------------------------------------------------
+Thu Jun 16 13:31:16 UTC 2016 - igonzalezs...@suse.com
+
+- Avoid restarting YaST when self-update repository exists but
+  is empty (bsc#985113)
+- 3.1.196
+
+-------------------------------------------------------------------
+Wed Jun 15 15:15:15 CEST 2016 - snw...@suse.de
+
+- call set_videomode to adjust video mode (bsc#974821)
+- 3.1.195
+
+-------------------------------------------------------------------
+Tue Jun 14 14:17:53 UTC 2016 - igonzalezs...@suse.com
+
+- Fix architecture detection during self-update (bsc#984656)
+- 3.1.194
+
+-------------------------------------------------------------------

Old:
----
  yast2-installation-3.1.193.tar.bz2

New:
----
  yast2-installation-3.1.198.tar.bz2

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

Other differences:
------------------
++++++ yast2-installation.spec ++++++
--- /var/tmp/diff_new_pack.2ewVCF/_old  2016-07-01 09:57:59.000000000 +0200
+++ /var/tmp/diff_new_pack.2ewVCF/_new  2016-07-01 09:57:59.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-installation
-Version:        3.1.193
+Version:        3.1.198
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build

++++++ yast2-installation-3.1.193.tar.bz2 -> yast2-installation-3.1.198.tar.bz2 
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/package/yast2-installation.changes 
new/yast2-installation-3.1.198/package/yast2-installation.changes
--- old/yast2-installation-3.1.193/package/yast2-installation.changes   
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/package/yast2-installation.changes   
2016-06-29 11:30:45.000000000 +0200
@@ -1,4 +1,39 @@
 -------------------------------------------------------------------
+Mon Jun 27 13:00:24 UTC 2016 - jreidin...@suse.com
+
+- Make writing of bootloader settings the last step so that other
+  installation steps (kdump, cio-ignore) do not have to waste time
+  repeating it
+  (bnc#986649)
+- 3.1.198
+
+-------------------------------------------------------------------
+Thu Jun 23 08:17:24 UTC 2016 - lsle...@suse.cz
+
+- Display more information in the error popup when downloading
+  the optional installer updates fails (bsc#986091)
+- 3.1.197
+
+-------------------------------------------------------------------
+Thu Jun 16 13:31:16 UTC 2016 - igonzalezs...@suse.com
+
+- Avoid restarting YaST when self-update repository exists but
+  is empty (bsc#985113)
+- 3.1.196
+
+-------------------------------------------------------------------
+Wed Jun 15 15:15:15 CEST 2016 - snw...@suse.de
+
+- call set_videomode to adjust video mode (bsc#974821)
+- 3.1.195
+
+-------------------------------------------------------------------
+Tue Jun 14 14:17:53 UTC 2016 - igonzalezs...@suse.com
+
+- Fix architecture detection during self-update (bsc#984656)
+- 3.1.194
+
+-------------------------------------------------------------------
 Thu Jun  2 11:09:33 UTC 2016 - sch...@suse.de
 
 - Adapt AutoYaST to support import of SSH server keys/configuration
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/package/yast2-installation.spec 
new/yast2-installation-3.1.198/package/yast2-installation.spec
--- old/yast2-installation-3.1.193/package/yast2-installation.spec      
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/package/yast2-installation.spec      
2016-06-29 11:30:45.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-installation
-Version:        3.1.193
+Version:        3.1.198
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/src/lib/installation/cio_ignore.rb 
new/yast2-installation-3.1.198/src/lib/installation/cio_ignore.rb
--- old/yast2-installation-3.1.193/src/lib/installation/cio_ignore.rb   
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/src/lib/installation/cio_ignore.rb   
2016-06-29 11:30:45.000000000 +0200
@@ -189,13 +189,8 @@
     def add_boot_kernel_parameters
       Yast.import "Bootloader"
 
-      res = Yast::Bootloader.Read
-
-      res &&= Yast::Bootloader.modify_kernel_params("cio_ignore" => 
"all,!ipldev,!condev")
-
-      res &&= Yast::Bootloader.Write
-
-      raise "failed to write kernel parameters for IPL and console device" if 
!res
+      # boot code is already proposed and will be written in next step, so 
just modify
+      Yast::Bootloader.modify_kernel_params("cio_ignore" => 
"all,!ipldev,!condev")
     end
 
     ACTIVE_DEVICES_FILE = "/boot/zipl/active_devices.txt"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/src/lib/installation/clients/inst_finish.rb 
new/yast2-installation-3.1.198/src/lib/installation/clients/inst_finish.rb
--- old/yast2-installation-3.1.193/src/lib/installation/clients/inst_finish.rb  
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/src/lib/installation/clients/inst_finish.rb  
2016-06-29 11:30:45.000000000 +0200
@@ -191,8 +191,8 @@
         install_bootloader_steps = [
           "prep_shrink", # ensure that prep partition is small enough for boot 
sector (bnc#867345)
           "cio_ignore", # needs to be run before initrd is created (bsc#933177)
-          "bootloader",
-          ProductFeatures.GetBooleanFeature("globals", "enable_kdump") == true 
? "kdump" : ""
+          ProductFeatures.GetBooleanFeature("globals", "enable_kdump") == true 
? "kdump" : "",
+          "bootloader"
         ]
       end
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/src/lib/installation/clients/inst_update_installer.rb
 
new/yast2-installation-3.1.198/src/lib/installation/clients/inst_update_installer.rb
--- 
old/yast2-installation-3.1.193/src/lib/installation/clients/inst_update_installer.rb
        2016-06-09 17:16:03.000000000 +0200
+++ 
new/yast2-installation-3.1.198/src/lib/installation/clients/inst_update_installer.rb
        2016-06-29 11:30:45.000000000 +0200
@@ -24,7 +24,7 @@
     UPDATED_FLAG_FILENAME = "installer_updated"
     REMOTE_SCHEMES = ["http", "https", "ftp", "tftp", "sftp", "nfs", "nfs4", 
"cifs", "smb"]
 
-    Yast.import "Arch"
+    Yast.import "Pkg"
     Yast.import "GetInstArgs"
     Yast.import "Directory"
     Yast.import "Installation"
@@ -129,7 +129,7 @@
     # @see URI.regexp
     def get_url_from(url)
       return nil unless url.is_a?(::String)
-      real_url = url.gsub(/\$arch\b/, Arch.architecture)
+      real_url = url.gsub(/\$arch\b/, Pkg.GetArchitecture)
       URI.regexp.match(real_url) ? URI(real_url) : nil
     end
 
@@ -174,9 +174,12 @@
     def update_installer
       log.info("Adding update from #{self_update_url}")
       updates_manager.add_repository(self_update_url)
-      log.info("Applying installer updates")
-      updates_manager.apply_all
-      true
+      updated = updates_manager.repositories?
+      if updated
+        log.info("Applying installer updates")
+        updates_manager.apply_all
+      end
+      updated
 
     rescue ::Installation::UpdatesManager::NotValidRepo
       if !using_default_url?
@@ -211,9 +214,19 @@
     #                   false if the network is not configured.
     def configure_network?
       if Popup.YesNo(
+        # Note: the proxy cannot be configured in the YaST installer yet,
+        # it needs to be set via the "proxy" boot option.
         # TRANSLATORS: %s is an URL
-        format(_("Downloading installer updates from \n%s\nfailed.\n\n" \
-                 "Would you like to check your network configuration?"), 
self_update_url))
+        format(_("Downloading the optional installer updates from 
\n%s\nfailed.\n" \
+                 "\n" \
+                 "You can continue the installation without applying the 
updates.\n" \
+                 "However, some potentially important bug fixes might be 
missing.\n" \
+                 "\n" \
+                 "If you need a proxy server to access the update 
repository\n" \
+                 "then use the \"proxy\" boot parameter.\n" \
+                 "\n" \
+                 "Would you like to check your network configuration\n" \
+                 "and try installing the updates again?"), self_update_url))
         Yast::WFM.CallFunction("inst_lan", [{ "skip_detection" => true }])
         true
       else
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/src/lib/installation/update_repository.rb 
new/yast2-installation-3.1.198/src/lib/installation/update_repository.rb
--- old/yast2-installation-3.1.193/src/lib/installation/update_repository.rb    
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/src/lib/installation/update_repository.rb    
2016-06-29 11:30:45.000000000 +0200
@@ -189,6 +189,15 @@
       Yast::Pkg.SourceDelete(repo_id)
     end
 
+    # Determine whether the repository is empty or not
+    #
+    # @return [Boolean] true if the repository is empty; false otherwise.
+    #
+    # @see #packages
+    def empty?
+      packages.empty?
+    end
+
   private
 
     # Fetch and build a squashfs filesytem for a given package
@@ -205,7 +214,7 @@
       tempfile = Tempfile.new(package["name"])
       tempfile.close
       Dir.mktmpdir do |workdir|
-        log.info("DEBUG 1")
+        log.info("Trying to get #{package["name"]} from repo #{repo_id}")
         if !Yast::Pkg.ProvidePackage(repo_id, package["name"], 
tempfile.path.to_s)
           log.error("Package #{package} could not be retrieved.")
           raise PackageNotFound
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/src/lib/installation/updates_manager.rb 
new/yast2-installation-3.1.198/src/lib/installation/updates_manager.rb
--- old/yast2-installation-3.1.193/src/lib/installation/updates_manager.rb      
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/src/lib/installation/updates_manager.rb      
2016-06-29 11:30:45.000000000 +0200
@@ -75,13 +75,19 @@
     # information.
     #
     # @param uri [URI] URI where the repository lives
-    # @return [Array<UpdateRepository] Array of repositories to be applied
+    # @return [Boolean] true if the repository was added; false otherwise.
     #
     # @see Installation::UpdateRepository
     def add_repository(uri)
       new_repository = Installation::UpdateRepository.new(uri)
       new_repository.fetch
-      @repositories << new_repository
+      has_packages = !new_repository.empty?
+      if has_packages
+        repositories << new_repository
+      else
+        log.info("Update repository at #{uri} is empty. Skipping...")
+      end
+      has_packages
     rescue Installation::UpdateRepository::NotValidRepo
       log.warn("Update repository at #{uri} could not be found")
       raise NotValidRepo
@@ -105,5 +111,10 @@
       (repositories + driver_updates).each(&:apply)
       repositories.each(&:cleanup)
     end
+
+    # Determines whether the manager has repositories with updates
+    def repositories?
+      !repositories.empty?
+    end
   end
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-installation-3.1.193/startup/YaST2.call 
new/yast2-installation-3.1.198/startup/YaST2.call
--- old/yast2-installation-3.1.193/startup/YaST2.call   2016-06-09 
17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/startup/YaST2.call   2016-06-29 
11:30:45.000000000 +0200
@@ -54,6 +54,11 @@
                        # server is running, detach oom-killer from it
                        echo -n '-17' > /proc/$xserver_pid/oom_score_adj
                        server_running=1
+                       # adjust video mode using xrandr, if requested
+                       SETMODE=/usr/lib/YaST2/bin/set_videomode
+                       if [ -n "$XVideo" -a -x $SETMODE ];then
+                         $SETMODE "$XVideo"
+                       fi
                        break
                fi
        done
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-installation-3.1.193/test/cio_ignore_test.rb 
new/yast2-installation-3.1.198/test/cio_ignore_test.rb
--- old/yast2-installation-3.1.193/test/cio_ignore_test.rb      2016-06-09 
17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/test/cio_ignore_test.rb      2016-06-29 
11:30:45.000000000 +0200
@@ -178,23 +178,12 @@
         end
 
         it "adds kernel parameters IPLDEV and CONDEV to the bootloader" do
-          expect(Yast::Bootloader).to receive(:Write).once { true }
-          expect(Yast::Bootloader).to receive(:Read).once { true }
           expect(Yast::Bootloader).to receive(:modify_kernel_params).once
             .and_return(true)
 
           subject.run("Write")
         end
 
-        it "raises an exception if modifying kernel parameters failed" do
-          expect(Yast::Bootloader).to receive(:Write).never
-          expect(Yast::Bootloader).to receive(:Read).once { true }
-          allow(Yast::Bootloader).to receive(:modify_kernel_params).once
-            .and_return(false)
-
-          expect { subject.run("Write") }.to raise_error(RuntimeError, /failed 
to write kernel parameters/)
-        end
-
         it "writes list of active devices to zipl so it is not blocked" do
           test_output = <<-EOL
 Devices that are not ignored:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/test/inst_update_installer_test.rb 
new/yast2-installation-3.1.198/test/inst_update_installer_test.rb
--- old/yast2-installation-3.1.193/test/inst_update_installer_test.rb   
2016-06-09 17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/test/inst_update_installer_test.rb   
2016-06-29 11:30:45.000000000 +0200
@@ -4,22 +4,25 @@
 require "installation/clients/inst_update_installer"
 
 describe Yast::InstUpdateInstaller do
-  Yast.import "Arch"
   Yast.import "Linuxrc"
   Yast.import "ProductFeatures"
   Yast.import "GetInstArgs"
   Yast.import "UI"
 
-  let(:manager) { double("update_manager", all_signed?: all_signed?, 
apply_all: true) }
+  let(:manager) do
+    double("update_manager", all_signed?: all_signed?, apply_all: true,
+      repositories?: has_repos)
+  end
   let(:url) { "http://update.opensuse.org/\$arch/update.dud"; }
   let(:real_url) { "http://update.opensuse.org/#{arch}/update.dud"; }
   let(:arch) { "x86_64" }
   let(:all_signed?) { true }
   let(:network_running) { true }
   let(:repo) { double("repo") }
+  let(:has_repos) { true }
 
   before do
-    allow(Yast::Arch).to receive(:architecture).and_return(arch)
+    allow(Yast::Pkg).to receive(:GetArchitecture).and_return(arch)
     allow(Yast::Mode).to receive(:auto).and_return(false)
     allow(Yast::NetworkService).to 
receive(:isNetworkRunning).and_return(network_running)
     allow(::Installation::UpdatesManager).to receive(:new).and_return(manager)
@@ -79,11 +82,22 @@
         end
       end
 
+      context "when repository is empty" do
+        let(:has_repos) { false }
+
+        it "does not restart YaST" do
+          expect(manager).to receive(:add_repository)
+            .and_return(false)
+          expect(subject.main).to eq(:next)
+        end
+      end
+
       context "when repository can't be probed" do
         context "and self-update URL is remote" do
           it "shows a dialog suggesting to check the network configuration" do
             expect(Yast::Popup).to receive(:YesNo).with(/installer updates 
from/)
-            expect(manager).to 
receive(:add_repository).and_raise(::Installation::UpdatesManager::CouldNotProbeRepo)
+            expect(manager).to receive(:add_repository)
+              .and_raise(::Installation::UpdatesManager::CouldNotProbeRepo)
             expect(subject.main).to eq(:next)
           end
         end
@@ -106,7 +120,7 @@
         end
 
         it "tries to update the installer using the given URL" do
-          expect(manager).to receive(:add_repository).with(URI(custom_url))
+          expect(manager).to 
receive(:add_repository).with(URI(custom_url)).and_return(true)
           expect(manager).to receive(:apply_all)
           allow(::FileUtils).to receive(:touch)
           expect(subject.main).to eq(:restart_yast)
@@ -128,7 +142,7 @@
         context "in standard installation" do
           it "gets URL from control file" do
             allow(::FileUtils).to receive(:touch)
-            expect(manager).to receive(:add_repository).with(URI(real_url))
+            expect(manager).to 
receive(:add_repository).with(URI(real_url)).and_return(true)
             expect(subject.main).to eq(:restart_yast)
           end
 
@@ -161,11 +175,13 @@
           context "the profile defines the update URL" do
             it "gets the URL from AutoYaST profile" do
               expect(manager).to 
receive(:add_repository).with(URI(profile_url))
+                .and_return(true)
               subject.main
             end
 
             it "returns :restart_yast" do
               allow(manager).to receive(:add_repository).with(URI(profile_url))
+                .and_return(true)
               expect(subject.main).to eq(:restart_yast)
             end
 
@@ -182,6 +198,7 @@
 
             it "gets URL from control file" do
               expect(manager).to receive(:add_repository).with(URI(real_url))
+                .and_return(true)
               expect(subject.main).to eq(:restart_yast)
             end
 
@@ -216,6 +233,7 @@
       context "when a error happens while applying the update" do
         it "does not catch the exception" do
           expect(manager).to receive(:add_repository)
+            .and_return(true)
           expect(manager).to receive(:apply_all)
             .and_raise(StandardError)
           expect { subject.update_installer }.to raise_error(StandardError)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-installation-3.1.193/test/updates_manager_test.rb 
new/yast2-installation-3.1.198/test/updates_manager_test.rb
--- old/yast2-installation-3.1.193/test/updates_manager_test.rb 2016-06-09 
17:16:03.000000000 +0200
+++ new/yast2-installation-3.1.198/test/updates_manager_test.rb 2016-06-29 
11:30:45.000000000 +0200
@@ -12,8 +12,8 @@
 
   let(:uri) { URI("http://updates.opensuse.org/sles12";) }
 
-  let(:repo0) { double("repo0", apply: true, cleanup: true) }
-  let(:repo1) { double("repo1", apply: true, cleanup: true) }
+  let(:repo0) { double("repo0", apply: true, cleanup: true, empty?: false) }
+  let(:repo1) { double("repo1", apply: true, cleanup: true, empty?: false) }
   let(:dud0)  { double("dud0", apply: true) }
 
   describe "#add_repository" do
@@ -23,9 +23,19 @@
     end
 
     context "when repository is added successfully" do
-      it "returns an array containing all repos" do
+      it "returns true and add the repository" do
         allow(repo0).to receive(:fetch)
-        expect(manager.add_repository(uri)).to eq([repo0])
+        expect(manager.add_repository(uri)).to eq(true)
+        expect(manager.repositories).to eq([repo0])
+      end
+    end
+
+    context "when repository is empty" do
+      it "returns false" do
+        allow(repo0).to receive(:fetch)
+        allow(repo0).to receive(:empty?).and_return(true)
+        expect(manager.add_repository(uri)).to eq(false)
+        expect(manager.repositories).to be_empty
       end
     end
 
@@ -115,4 +125,26 @@
       end
     end
   end
+
+  describe "#repositories?" do
+    context "when some repository was added" do
+      before do
+        allow(manager).to receive(:repositories).and_return([repo0])
+      end
+
+      it "returns true" do
+        expect(manager.repositories?).to eq(true)
+      end
+    end
+
+    context "when no repository was added" do
+      before do
+        allow(manager).to receive(:repositories).and_return([])
+      end
+
+      it "returns false" do
+        expect(manager.repositories?).to eq(false)
+      end
+    end
+  end
 end


Reply via email to