Hello community, here is the log from the commit of package yast2 for openSUSE:Factory checked in at 2020-01-11 14:47:40 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/yast2 (Old) and /work/SRC/openSUSE:Factory/.yast2.new.6675 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2" Sat Jan 11 14:47:40 2020 rev:469 rq:762884 version:4.2.53 Changes: -------- --- /work/SRC/openSUSE:Factory/yast2/yast2.changes 2020-01-04 19:20:47.565122655 +0100 +++ /work/SRC/openSUSE:Factory/.yast2.new.6675/yast2.changes 2020-01-11 14:47:54.081371010 +0100 @@ -1,0 +2,27 @@ +Fri Jan 10 13:43:20 UTC 2020 - Ancor Gonzalez Sosa <[email protected]> + +- Fixed error during upgrade if Btrfs is used and '/var/lib/YaST2' + is missing (bsc#1159562) +- 4.2.53 + +------------------------------------------------------------------- +Fri Jan 10 09:04:16 UTC 2020 - Martin Vidner <[email protected]> + +- Propagate an error status when a CommandLine module gets an + unknown command (related to bsc#1144351). +- 4.2.52 + +------------------------------------------------------------------- +Wed Jan 8 16:27:59 UTC 2020 - Ancor Gonzalez Sosa <[email protected]> + +- Fix an exception in the live installation caused by a missing + "require" clause (bsc#1160362). +- 4.2.51 + +------------------------------------------------------------------- +Mon Jan 6 15:03:45 UTC 2020 - Ladislav Slezák <[email protected]> + +- Persian is also an RTL language (related to bsc#1156437) +- 4.2.50 + +------------------------------------------------------------------- Old: ---- yast2-4.2.49.tar.bz2 New: ---- yast2-4.2.53.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2.spec ++++++ --- /var/tmp/diff_new_pack.Qo1UCa/_old 2020-01-11 14:47:54.657371235 +0100 +++ /var/tmp/diff_new_pack.Qo1UCa/_new 2020-01-11 14:47:54.657371235 +0100 @@ -1,7 +1,7 @@ # # spec file for package yast2 # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 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 -Version: 4.2.49 +Version: 4.2.53 Release: 0 Summary: YaST2 Main Package License: GPL-2.0-only ++++++ yast2-4.2.49.tar.bz2 -> yast2-4.2.53.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/commandline/src/modules/CommandLine.rb new/yast2-4.2.53/library/commandline/src/modules/CommandLine.rb --- old/yast2-4.2.49/library/commandline/src/modules/CommandLine.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/commandline/src/modules/CommandLine.rb 2020-01-10 17:18:34.000000000 +0100 @@ -360,7 +360,7 @@ # translators: error message in command line interface Error(Builtins.sformat(_("Unknown Command: %1"), command)) - return { "command" => command } + return {} end # build the list of options for the command diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/commandline/test/commandline_test.rb new/yast2-4.2.53/library/commandline/test/commandline_test.rb --- old/yast2-4.2.49/library/commandline/test/commandline_test.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/commandline/test/commandline_test.rb 2020-01-10 17:18:34.000000000 +0100 @@ -4,6 +4,10 @@ Yast.import "CommandLine" +# If these test fail (or succeed) in mysterious ways then it may be +# wfm.rb eagerly rescuing a RSpec::Mocks::MockExpectationError +# (fixed meanwhile in ruby-bindings). In such cases see the y2log. + describe Yast::CommandLine do # restore the original modes to not accidentally influence the other tests # (these tests change the UI mode to "commandline") @@ -38,4 +42,11 @@ Yast::WFM.CallFunction("dummy_cmdline", ["crash"]) end + + it "complains about unknown commands and returns false" do + expect(Yast::CommandLine).to receive(:Print).with(/Unknown Command:/) + expect(Yast::CommandLine).to receive(:Print).with(/Use.*help.*available commands/) + + expect(Yast::WFM.CallFunction("dummy_cmdline", ["unknowncommand"])).to eq false + end end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/general/src/lib/ui/text_helpers.rb new/yast2-4.2.53/library/general/src/lib/ui/text_helpers.rb --- old/yast2-4.2.49/library/general/src/lib/ui/text_helpers.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/general/src/lib/ui/text_helpers.rb 2020-01-10 17:18:34.000000000 +0100 @@ -72,7 +72,8 @@ def div_with_direction(text, lang = nil) Yast.import "Language" lang ||= Yast::Language.language - direction = lang.start_with?("ar", "he") ? "rtl" : "ltr" + # RTL languages: Arabic, Persian, Hebrew + direction = lang.start_with?("ar", "fa", "he") ? "rtl" : "ltr" "<div dir=\"#{direction}\">#{text}</div>" end end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/packages/src/lib/y2packager/product_reader.rb new/yast2-4.2.53/library/packages/src/lib/y2packager/product_reader.rb --- old/yast2-4.2.49/library/packages/src/lib/y2packager/product_reader.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/packages/src/lib/y2packager/product_reader.rb 2020-01-10 17:18:34.000000000 +0100 @@ -14,6 +14,7 @@ require "y2packager/product" require "y2packager/product_sorter" require "y2packager/resolvable" +require "y2packager/product_control_product" Yast.import "Pkg" Yast.import "Linuxrc" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/packages/test/y2packager/product_reader_test.rb new/yast2-4.2.53/library/packages/test/y2packager/product_reader_test.rb --- old/yast2-4.2.49/library/packages/test/y2packager/product_reader_test.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/packages/test/y2packager/product_reader_test.rb 2020-01-10 17:18:34.000000000 +0100 @@ -216,6 +216,41 @@ expect(subject.all_products.size).to eq(1) end + + # Smoke test. There was a missing "require" clause in one part of the code. + # This context ensures that part is executed in the tests, basically to + # make sure the "require" is not forgotten (bsc#1160362). But the tests on + # this context do not guarantee the code is working correctly in all cases. + # They only test a simplistic case with quite some mocking. + context "with the online media and no base product" do + # FIXME: needed because MediumType is wrongly located in yast2-packager + module Y2Packager + class MediumType + def self.online? + true + end + end + end + + before do + allow(Yast::Stage).to receive(:initial).and_return true + + # The tests at test/y2packager/product_control_product_test.rb mock + # this to always be an array. Let's copy the most simplistic of those + # mocks. + allow(Yast::ProductFeatures).to receive(:GetFeature) + .with("software", "base_products").and_return([]) + end + + after do + # the read products are cached, we need to reset them manually for the next test + Y2Packager::ProductControlProduct.instance_variable_set(:@products, nil) + end + + it "does not crash" do + expect { subject.all_products }.to_not raise_error + end + end end describe ".installation_package_mapping" do diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/system/src/lib/yast2/fs_snapshot_store.rb new/yast2-4.2.53/library/system/src/lib/yast2/fs_snapshot_store.rb --- old/yast2-4.2.49/library/system/src/lib/yast2/fs_snapshot_store.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/system/src/lib/yast2/fs_snapshot_store.rb 2020-01-10 17:18:34.000000000 +0100 @@ -30,6 +30,12 @@ # @param[String] purpose of snapshot like "upgrade" # @raise[RuntimeError] if writing to file failed def self.save(purpose, snapshot_id) + # Ensure the directory is there (bsc#1159562) + Yast::SCR.Execute( + Yast::Path.new(".target.bash"), + "/bin/mkdir -p #{snapshot_dir_path}" + ) + result = Yast::SCR.Write( Yast::Path.new(".target.string"), snapshot_path(purpose), @@ -61,7 +67,13 @@ # Path where is stored given purpose def self.snapshot_path(purpose) - path = "/var/lib/YaST2/pre_snapshot_#{purpose}.id" + ::File.join(snapshot_dir_path, "pre_snapshot_#{purpose}.id") + end + private_class_method :snapshot_path + + # Path of the directory where the ids of the snapshots are stored + def self.snapshot_dir_path + path = "/var/lib/YaST2" Yast.import "Stage" if Yast::Stage.initial && !Yast::WFM.scr_chrooted? @@ -71,6 +83,6 @@ path end - private_class_method :snapshot_path + private_class_method :snapshot_dir_path end end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/library/system/test/fs_snapshot_store_test.rb new/yast2-4.2.53/library/system/test/fs_snapshot_store_test.rb --- old/yast2-4.2.49/library/system/test/fs_snapshot_store_test.rb 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/library/system/test/fs_snapshot_store_test.rb 2020-01-10 17:18:34.000000000 +0100 @@ -6,6 +6,11 @@ describe Yast2::FsSnapshotStore do describe ".save" do it "stores snapshot id to file identified by purpose" do + expect(Yast::SCR).to receive(:Execute).with( + path(".target.bash"), + "/bin/mkdir -p /var/lib/YaST2" + ) + expect(Yast::SCR).to receive(:Write).with( path(".target.string"), "/var/lib/YaST2/pre_snapshot_test.id", @@ -16,6 +21,8 @@ end it "raises exception if writing failed" do + allow(Yast::SCR).to receive(:Execute).with(path(".target.bash"), anything) + expect(Yast::SCR).to receive(:Write).with( path(".target.string"), "/var/lib/YaST2/pre_snapshot_test.id", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/package/yast2.changes new/yast2-4.2.53/package/yast2.changes --- old/yast2-4.2.49/package/yast2.changes 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/package/yast2.changes 2020-01-10 17:18:34.000000000 +0100 @@ -1,4 +1,31 @@ ------------------------------------------------------------------- +Fri Jan 10 13:43:20 UTC 2020 - Ancor Gonzalez Sosa <[email protected]> + +- Fixed error during upgrade if Btrfs is used and '/var/lib/YaST2' + is missing (bsc#1159562) +- 4.2.53 + +------------------------------------------------------------------- +Fri Jan 10 09:04:16 UTC 2020 - Martin Vidner <[email protected]> + +- Propagate an error status when a CommandLine module gets an + unknown command (related to bsc#1144351). +- 4.2.52 + +------------------------------------------------------------------- +Wed Jan 8 16:27:59 UTC 2020 - Ancor Gonzalez Sosa <[email protected]> + +- Fix an exception in the live installation caused by a missing + "require" clause (bsc#1160362). +- 4.2.51 + +------------------------------------------------------------------- +Mon Jan 6 15:03:45 UTC 2020 - Ladislav Slezák <[email protected]> + +- Persian is also an RTL language (related to bsc#1156437) +- 4.2.50 + +------------------------------------------------------------------- Thu Dec 19 14:51:23 UTC 2019 - Knut Anderssen <[email protected]> - Yast2::ServiceWidget: By default, propose to reload or restart diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.2.49/package/yast2.spec new/yast2-4.2.53/package/yast2.spec --- old/yast2-4.2.49/package/yast2.spec 2019-12-19 15:11:34.000000000 +0100 +++ new/yast2-4.2.53/package/yast2.spec 2020-01-10 17:18:34.000000000 +0100 @@ -17,7 +17,7 @@ Name: yast2 -Version: 4.2.49 +Version: 4.2.53 Release: 0 Summary: YaST2 Main Package License: GPL-2.0-only
