Hello community,

here is the log from the commit of package yast2-bootloader for 
openSUSE:Factory checked in at 2018-05-06 14:58:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-bootloader (Old)
 and      /work/SRC/openSUSE:Factory/.yast2-bootloader.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-bootloader"

Sun May  6 14:58:15 2018 rev:260 rq:604035 version:4.0.29

Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-bootloader/yast2-bootloader.changes        
2018-04-26 13:31:45.861858697 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-bootloader.new/yast2-bootloader.changes   
2018-05-06 14:58:17.492021518 +0200
@@ -1,0 +2,13 @@
+Fri May  4 12:43:44 UTC 2018 - [email protected]
+
+- Inform user when an unsupported bootloader is defined in the
+  AutoYaST profile, display the valid values (bsc#1091284)
+- 4.0.29
+
+-------------------------------------------------------------------
+Wed May  2 10:35:56 UTC 2018 - [email protected]
+
+- Fix test failure on s390 (no functionality change)(bsc#1091631)
+- 4.0.28
+
+-------------------------------------------------------------------

Old:
----
  yast2-bootloader-4.0.27.tar.bz2

New:
----
  yast2-bootloader-4.0.29.tar.bz2

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

Other differences:
------------------
++++++ yast2-bootloader.spec ++++++
--- /var/tmp/diff_new_pack.NGVTqn/_old  2018-05-06 14:58:17.996003024 +0200
+++ /var/tmp/diff_new_pack.NGVTqn/_new  2018-05-06 14:58:18.000002878 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-bootloader
-Version:        4.0.27
+Version:        4.0.29
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build

++++++ yast2-bootloader-4.0.27.tar.bz2 -> yast2-bootloader-4.0.29.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-bootloader-4.0.27/package/yast2-bootloader.changes 
new/yast2-bootloader-4.0.29/package/yast2-bootloader.changes
--- old/yast2-bootloader-4.0.27/package/yast2-bootloader.changes        
2018-04-25 13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/package/yast2-bootloader.changes        
2018-05-04 15:02:21.000000000 +0200
@@ -1,4 +1,17 @@
 -------------------------------------------------------------------
+Fri May  4 12:43:44 UTC 2018 - [email protected]
+
+- Inform user when an unsupported bootloader is defined in the
+  AutoYaST profile, display the valid values (bsc#1091284)
+- 4.0.29
+
+-------------------------------------------------------------------
+Wed May  2 10:35:56 UTC 2018 - [email protected]
+
+- Fix test failure on s390 (no functionality change)(bsc#1091631)
+- 4.0.28
+
+-------------------------------------------------------------------
 Tue Apr 24 14:36:12 UTC 2018 - [email protected]
 
 - Do not crash when clicking on booting during upgrade
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-bootloader-4.0.27/package/yast2-bootloader.spec 
new/yast2-bootloader-4.0.29/package/yast2-bootloader.spec
--- old/yast2-bootloader-4.0.27/package/yast2-bootloader.spec   2018-04-25 
13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/package/yast2-bootloader.spec   2018-05-04 
15:02:21.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-bootloader
-Version:        4.0.27
+Version:        4.0.29
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-bootloader-4.0.27/src/lib/bootloader/auto_client.rb 
new/yast2-bootloader-4.0.29/src/lib/bootloader/auto_client.rb
--- old/yast2-bootloader-4.0.27/src/lib/bootloader/auto_client.rb       
2018-04-25 13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/src/lib/bootloader/auto_client.rb       
2018-05-04 15:02:21.000000000 +0200
@@ -3,8 +3,10 @@
 require "installation/auto_client"
 require "bootloader/bootloader_factory"
 require "bootloader/autoyast_converter"
+require "bootloader/exceptions"
 require "bootloader/main_dialog"
 
+Yast.import "AutoInstall"
 Yast.import "Bootloader"
 Yast.import "BootStorage"
 Yast.import "Initrd"
@@ -14,6 +16,8 @@
 module Bootloader
   # Autoyast client for bootloader
   class AutoClient < ::Installation::AutoClient
+    include Yast::I18n
+
     class << self
       attr_accessor :changed
     end
@@ -27,7 +31,19 @@
     end
 
     def import(data)
-      Yast::Bootloader.Import(data)
+      begin
+        Yast::Bootloader.Import(data)
+      rescue ::Bootloader::UnsupportedBootloader => e
+        textdomain "bootloader"
+        possible_values = BootloaderFactory.supported_names + 
[BootloaderFactory::DEFAULT_KEYWORD]
+        Yast::AutoInstall.issues_list.add(:invalid_value, "bootloader", 
"loader_type",
+          e.bootloader_name,
+          _("The selected bootloader is not supported on this architecture. 
Possible values: ") +
+            possible_values.join(", "),
+          :fatal)
+        # AutoInstall issues itself will abort import, so do not stop here 
prematurely.
+        return true
+      end
 
       Yast::PackagesProposal.AddResolvables("yast2-bootloader",
         :package, BootloaderFactory.current.packages)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-bootloader-4.0.27/src/lib/bootloader/autoyast_converter.rb 
new/yast2-bootloader-4.0.29/src/lib/bootloader/autoyast_converter.rb
--- old/yast2-bootloader-4.0.27/src/lib/bootloader/autoyast_converter.rb        
2018-04-25 13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/src/lib/bootloader/autoyast_converter.rb        
2018-05-04 15:02:21.000000000 +0200
@@ -177,8 +177,8 @@
       end
 
       def bootloader_from_data(data)
-        loader_type = data["loader_type"] || "default"
-        allowed = BootloaderFactory::SUPPORTED_BOOTLOADERS + ["default"]
+        loader_type = data["loader_type"] || BootloaderFactory::DEFAULT_KEYWORD
+        allowed = BootloaderFactory.supported_names + 
[BootloaderFactory::DEFAULT_KEYWORD]
 
         raise UnsupportedBootloader, loader_type if 
!allowed.include?(loader_type)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-bootloader-4.0.27/src/lib/bootloader/bootloader_factory.rb 
new/yast2-bootloader-4.0.29/src/lib/bootloader/bootloader_factory.rb
--- old/yast2-bootloader-4.0.27/src/lib/bootloader/bootloader_factory.rb        
2018-04-25 13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/src/lib/bootloader/bootloader_factory.rb        
2018-05-04 15:02:21.000000000 +0200
@@ -18,6 +18,9 @@
       "grub2-efi"
     ].freeze
 
+    # Keyword used in autoyast for default bootloader used for given system.
+    DEFAULT_KEYWORD = "default".freeze
+
     class << self
       attr_writer :current
 
@@ -44,7 +47,7 @@
       def supported_names
         if Yast::Mode.config
           # default means bootloader use what it think is the best
-          return BootloaderFactory::SUPPORTED_BOOTLOADERS + ["default"]
+          return BootloaderFactory::SUPPORTED_BOOTLOADERS + [DEFAULT_KEYWORD]
         end
 
         system_bl = begin
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-bootloader-4.0.27/test/data/trivial.yaml 
new/yast2-bootloader-4.0.29/test/data/trivial.yaml
--- old/yast2-bootloader-4.0.27/test/data/trivial.yaml  2018-04-25 
13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/test/data/trivial.yaml  2018-05-04 
15:02:21.000000000 +0200
@@ -10,7 +10,7 @@
         name:         /dev/sda1
         id:           bios_boot
         file_system:  vfat
-        uuid:         3de29985-8cc6-4c9d-8562-2ede26b0c5b6
+        uuid:         3de29985-8cc6-4c9d-8562-2ede26b0c5b7
 
     - partition:
         size:         1002 MiB
@@ -25,3 +25,5 @@
         name:         /dev/sda3
         file_system:  btrfs
         mount_point:  "/"
+        uuid:         3de29985-8cc6-4c9d-8562-2ede26b0c5b6
+        label:        DATA
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-bootloader-4.0.27/test/udev_mapping_test.rb 
new/yast2-bootloader-4.0.29/test/udev_mapping_test.rb
--- old/yast2-bootloader-4.0.27/test/udev_mapping_test.rb       2018-04-25 
13:37:03.000000000 +0200
+++ new/yast2-bootloader-4.0.29/test/udev_mapping_test.rb       2018-05-04 
15:02:21.000000000 +0200
@@ -32,7 +32,7 @@
     end
 
     it "return kernel device name for udev mapped name" do
-      
expect(subject.to_kernel_device("/dev/disk/by-uuid/3de29985-8cc6-4c9d-8562-2ede26b0c5b6")).to
 eq "/dev/sda1"
+      
expect(subject.to_kernel_device("/dev/disk/by-uuid/3de29985-8cc6-4c9d-8562-2ede26b0c5b6")).to
 eq "/dev/sda3"
     end
 
     it "raise exception if udev link is not known" do
@@ -48,57 +48,47 @@
       allow(Y2Storage::BlkDevice).to receive(:find_by_name).and_return(device)
     end
 
-    it "returns udev link in same format as used to its mounting if defined" do
-      allow(device).to receive(:blk_filesystem).and_return(
-        double(
-          mount_by: Y2Storage::Filesystems::MountByType.new(:uuid),
-          uuid:     "3de29985-8cc6-4c9d-8562-2ede26b0c5b6"
-        )
-      )
+    it "returns udev link in same format as used to its mounting" do
+      device.filesystem.mount_point.mount_by = 
Y2Storage::Filesystems::MountByType.new(:uuid)
 
       expect(subject.to_mountby_device(device.name)).to eq 
"/dev/disk/by-uuid/3de29985-8cc6-4c9d-8562-2ede26b0c5b6"
     end
 
     it "returns udev link by label if defined" do
-      allow(device).to receive(:blk_filesystem).and_return(
-        double(
-          mount_by: Y2Storage::Filesystems::MountByType.new(:uuid),
-          uuid:     nil,
-          label:    "DATA"
-        )
-      )
+      device.filesystem.remove_mount_point
 
       expect(subject.to_mountby_device(device.name)).to eq 
"/dev/disk/by-label/DATA"
     end
 
     it "returns udev link by uuid if defined" do
-      allow(device).to receive(:blk_filesystem).and_return(
-        double(
-          mount_by: Y2Storage::Filesystems::MountByType.new(:label),
-          uuid:     "3de29985-8cc6-4c9d-8562-2ede26b0c5b6",
-          label:    ""
-        )
-      )
+      device.filesystem.remove_mount_point
+      allow(device).to receive(:udev_full_label).and_return(nil)
 
       expect(subject.to_mountby_device(device.name)).to eq 
"/dev/disk/by-uuid/3de29985-8cc6-4c9d-8562-2ede26b0c5b6"
     end
 
     it "returns first udev link by id if defined" do
-      allow(device).to receive(:blk_filesystem).and_return(nil)
+      device.filesystem.remove_mount_point
+      allow(device).to receive(:udev_full_label).and_return(nil)
+      allow(device).to receive(:udev_full_uuid).and_return(nil)
       allow(device).to receive(:udev_ids).and_return(["abc", "cde"])
 
       expect(subject.to_mountby_device(device.name)).to eq 
"/dev/disk/by-id/abc"
     end
 
     it "returns first udev link by path if defined" do
-      allow(device).to receive(:blk_filesystem).and_return(nil)
+      device.filesystem.remove_mount_point
+      allow(device).to receive(:udev_full_label).and_return(nil)
+      allow(device).to receive(:udev_full_uuid).and_return(nil)
       allow(device).to receive(:udev_paths).and_return(["abc", "cde"])
 
       expect(subject.to_mountby_device(device.name)).to eq 
"/dev/disk/by-path/abc"
     end
 
     it "returns kernel name as last fallback" do
-      allow(device).to receive(:blk_filesystem).and_return(nil)
+      device.filesystem.remove_mount_point
+      allow(device).to receive(:udev_full_label).and_return(nil)
+      allow(device).to receive(:udev_full_uuid).and_return(nil)
 
       expect(subject.to_mountby_device(device.name)).to eq device.name
     end


Reply via email to