openSUSE Commits
Threads by month
- ----- 2024 -----
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
July 2020
- 1 participants
- 2232 discussions
Hello community,
here is the log from the commit of package qgis for openSUSE:Factory checked in at 2020-07-01 14:26:14
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/qgis (Old)
and /work/SRC/openSUSE:Factory/.qgis.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "qgis"
Wed Jul 1 14:26:14 2020 rev:14 rq:816985 version:3.14.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/qgis/qgis.changes 2020-06-10 00:47:45.906842791 +0200
+++ /work/SRC/openSUSE:Factory/.qgis.new.3060/qgis.changes 2020-07-01 14:26:22.202707107 +0200
@@ -1,0 +2,19 @@
+Thu Jun 25 09:12:52 UTC 2020 - Guillaume GARDET <guillaume.gardet(a)opensuse.org>
+
+- proj.db is required, so requires proj package
+
+-------------------------------------------------------------------
+Tue Jun 23 08:10:59 UTC 2020 - Guillaume GARDET <guillaume.gardet(a)opensuse.org>
+
+- Update to 3.14.0, changes are documented at
+ https://changelog.qgis.org/en/qgis/version/3.14/
+- Drop upstream patch:
+ * qgis-qt5.15.patch
+
+-------------------------------------------------------------------
+Fri Jun 12 06:34:58 UTC 2020 - Guillaume GARDET <guillaume.gardet(a)opensuse.org>
+
+- Requires at least gdal 3.1 for GeoTIFF and Proj >= 6
+ https://github.com/qgis/QGIS/issues/36699#issuecomment-633539864
+
+-------------------------------------------------------------------
Old:
----
qgis-3.12.3.tar.bz2
qgis-3.12.3.tar.bz2.sha256
qgis-qt5.15.patch
New:
----
qgis-3.14.0.tar.bz2
qgis-3.14.0.tar.bz2.sha256
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ qgis.spec ++++++
--- /var/tmp/diff_new_pack.3bgRdo/_old 2020-07-01 14:26:23.942712503 +0200
+++ /var/tmp/diff_new_pack.3bgRdo/_new 2020-07-01 14:26:23.942712503 +0200
@@ -18,7 +18,7 @@
%bcond_without grass
Name: qgis
-Version: 3.12.3
+Version: 3.14.0
Release: 0
Summary: A Geographic Information System (GIS)
License: GPL-2.0-only
@@ -28,8 +28,6 @@
Source1: https://qgis.org/downloads/%{name}-%{version}.tar.bz2.sha256
Source2: %{name}.rpmlintrc
Source3: qgis_sample_data.zip
-# PATCH-FIX-UPSTREAM - Commit 31f586ec
-Patch1: qgis-qt5.15.patch
BuildRequires: FastCGI-devel
BuildRequires: bison >= 2.4
BuildRequires: cmake >= 3.0.0
@@ -50,6 +48,7 @@
BuildRequires: opencl-cpp-headers
BuildRequires: pkgconfig
BuildRequires: poppler-tools
+BuildRequires: protobuf-devel
BuildRequires: python-qscintilla-qt5-sip
BuildRequires: python3-GDAL
BuildRequires: python3-Jinja2
@@ -104,7 +103,8 @@
BuildRequires: pkgconfig(Qt5Xml)
BuildRequires: pkgconfig(Qt5XmlPatterns)
BuildRequires: pkgconfig(expat) >= 1.95
-BuildRequires: pkgconfig(gdal) >= 3
+# Requires at least gdal 3.1 for GeoTIFF and Proj >= 6 - https://github.com/qgis/QGIS/issues/36699#issuecomment-633539864
+BuildRequires: pkgconfig(gdal) >= 3.1
BuildRequires: pkgconfig(gsl) >= 1.8
BuildRequires: pkgconfig(libpq) > 9.4
BuildRequires: pkgconfig(libzip)
@@ -112,10 +112,12 @@
BuildRequires: pkgconfig(python3) >= 3.4
BuildRequires: pkgconfig(qca2-qt5)
BuildRequires: pkgconfig(spatialite) >= 4.2.0
+# Force requires of those 3 main component.
Requires: libQt5Sql5-mysql
Requires: libQt5Sql5-postgresql
-# Force requires of those 3 main component.
Requires: libQt5Sql5-sqlite
+# proj.db is required
+Requires: proj
Requires: python3-GDAL
Requires: python3-Jinja2
Requires: python3-OWSLib
++++++ qgis-3.12.3.tar.bz2 -> qgis-3.14.0.tar.bz2 ++++++
/work/SRC/openSUSE:Factory/qgis/qgis-3.12.3.tar.bz2 /work/SRC/openSUSE:Factory/.qgis.new.3060/qgis-3.14.0.tar.bz2 differ: char 11, line 1
++++++ qgis-3.12.3.tar.bz2.sha256 -> qgis-3.14.0.tar.bz2.sha256 ++++++
--- /work/SRC/openSUSE:Factory/qgis/qgis-3.12.3.tar.bz2.sha256 2020-06-10 00:47:45.798842508 +0200
+++ /work/SRC/openSUSE:Factory/.qgis.new.3060/qgis-3.14.0.tar.bz2.sha256 2020-07-01 14:26:21.846706003 +0200
@@ -1 +1 @@
-c2b53815f9b994e1662995d1f25f90628156b996758f5471bffb74ab29a95220 qgis-3.12.3.tar.bz2
+1b76c5278def0c447c3d354149a2afe2562ac26cf0bcbe69b9e0528356d407b8 qgis-3.14.0.tar.bz2
1
0
Hello community,
here is the log from the commit of package yast2-services-manager for openSUSE:Factory checked in at 2020-07-01 14:26:08
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-services-manager (Old)
and /work/SRC/openSUSE:Factory/.yast2-services-manager.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-services-manager"
Wed Jul 1 14:26:08 2020 rev:53 rq:817913 version:4.3.1
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-services-manager/yast2-services-manager.changes 2020-05-15 23:50:43.989361060 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-services-manager.new.3060/yast2-services-manager.changes 2020-07-01 14:26:16.210688524 +0200
@@ -1,0 +2,8 @@
+Tue Jun 30 11:48:27 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- Honor the 'target' argument when cloning the system. If it is
+ set to 'compact', it only exports those services which start
+ mode is not set to their predefined values (bsc#1172749).
+- 4.3.1
+
+-------------------------------------------------------------------
Old:
----
yast2-services-manager-4.3.0.tar.bz2
New:
----
yast2-services-manager-4.3.1.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-services-manager.spec ++++++
--- /var/tmp/diff_new_pack.hohsoQ/_old 2020-07-01 14:26:17.310691936 +0200
+++ /var/tmp/diff_new_pack.hohsoQ/_new 2020-07-01 14:26:17.314691948 +0200
@@ -24,7 +24,7 @@
######################################################################
Name: yast2-services-manager
-Version: 4.3.0
+Version: 4.3.1
Release: 0
Summary: YaST2 - Services Manager
License: GPL-2.0-or-later
@@ -35,8 +35,8 @@
BuildRequires: ruby
BuildRequires: update-desktop-files
-# Yast2::Firewalld::Interface#zone returns a Zone object
-BuildRequires: yast2 >= 4.1.17
+# 'target' argument for Installation::AutoClient#export method
+BuildRequires: yast2 >= 4.3.10
BuildRequires: yast2-ruby-bindings >= 1.2.0
# To show service logs
BuildRequires: yast2-journal >= 4.1.1
@@ -46,8 +46,8 @@
BuildRequires: rubygem(%{rb_default_ruby_abi}:yast-rake) >= 0.1.7
Requires: ruby
-# Yast2::Firewalld::Interface#zone returns a Zone object
-Requires: yast2 >= 4.1.17
+ # 'target' argument for Installation::AutoClient#export method
+Requires: yast2 >= 4.3.10
Requires: yast2-ruby-bindings >= 1.2.0
# To show service logs
++++++ yast2-services-manager-4.3.0.tar.bz2 -> yast2-services-manager-4.3.1.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/package/yast2-services-manager.changes new/yast2-services-manager-4.3.1/package/yast2-services-manager.changes
--- old/yast2-services-manager-4.3.0/package/yast2-services-manager.changes 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/package/yast2-services-manager.changes 2020-06-30 17:16:09.000000000 +0200
@@ -1,4 +1,12 @@
-------------------------------------------------------------------
+Tue Jun 30 11:48:27 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- Honor the 'target' argument when cloning the system. If it is
+ set to 'compact', it only exports those services which start
+ mode is not set to their predefined values (bsc#1172749).
+- 4.3.1
+
+-------------------------------------------------------------------
Tue May 12 15:32:28 UTC 2020 - josef Reidinger <jreidinger@localhost>
- Autoyast schema: Allow optional types for string and map objects
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/package/yast2-services-manager.spec new/yast2-services-manager-4.3.1/package/yast2-services-manager.spec
--- old/yast2-services-manager-4.3.0/package/yast2-services-manager.spec 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/package/yast2-services-manager.spec 2020-06-30 17:16:09.000000000 +0200
@@ -24,7 +24,7 @@
######################################################################
Name: yast2-services-manager
-Version: 4.3.0
+Version: 4.3.1
Release: 0
Summary: YaST2 - Services Manager
Group: System/YaST
@@ -35,8 +35,8 @@
BuildRequires: ruby
BuildRequires: update-desktop-files
-# Yast2::Firewalld::Interface#zone returns a Zone object
-BuildRequires: yast2 >= 4.1.17
+# 'target' argument for Installation::AutoClient#export method
+BuildRequires: yast2 >= 4.3.10
BuildRequires: yast2-ruby-bindings >= 1.2.0
# To show service logs
BuildRequires: yast2-journal >= 4.1.1
@@ -46,8 +46,8 @@
BuildRequires: yast2-devtools >= 4.2.2
Requires: ruby
-# Yast2::Firewalld::Interface#zone returns a Zone object
-Requires: yast2 >= 4.1.17
+ # 'target' argument for Installation::AutoClient#export method
+Requires: yast2 >= 4.3.10
Requires: yast2-ruby-bindings >= 1.2.0
# To show service logs
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/src/lib/services-manager/clients/auto.rb new/yast2-services-manager-4.3.1/src/lib/services-manager/clients/auto.rb
--- old/yast2-services-manager-4.3.0/src/lib/services-manager/clients/auto.rb 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/src/lib/services-manager/clients/auto.rb 2020-06-30 17:16:09.000000000 +0200
@@ -46,8 +46,8 @@
end
# @see ::Installation::AutoClient#export
- def export
- Yast::ServicesManager.export
+ def export(target: :default)
+ Yast::ServicesManager.export(target: target)
end
# @see ::Installation::AutoClient#read
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/src/modules/services_manager.rb new/yast2-services-manager-4.3.1/src/modules/services_manager.rb
--- old/yast2-services-manager-4.3.0/src/modules/services_manager.rb 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/src/modules/services_manager.rb 2020-06-30 17:16:09.000000000 +0200
@@ -29,10 +29,13 @@
textdomain 'services-manager'
end
- def export
+ # @param target [Symbol] Control how much information should be exported
+ # (e.g., :default or :compact).
+ # @return [Hash] profile data
+ def export(target: :default)
{
TARGET => ServicesManagerTarget.export,
- SERVICES => ServicesManagerService.export
+ SERVICES => ServicesManagerService.export(target: target)
}
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/src/modules/services_manager_service.rb new/yast2-services-manager-4.3.1/src/modules/services_manager_service.rb
--- old/yast2-services-manager-4.3.0/src/modules/services_manager_service.rb 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/src/modules/services_manager_service.rb 2020-06-30 17:16:09.000000000 +0200
@@ -111,7 +111,7 @@
# @param key [Symbol] value that has been changed (:active and :start_mode)
# @return [Boolean] true if the key has changed
def changed_value?(name, key)
- exists?(name) { |s| s.changed?(:active) }
+ exists?(name) { |s| s.changed?(key) }
end
# Returns whether the given service has been enabled
@@ -206,16 +206,37 @@
#
# FIXME: should be checked (and decided what to do if so) if service is marked to be exported as
# both, enabled or disabled
- # @return [Hash{String => Array<String>}]
- def export
- on_boot_srvs = exportable_on_boot_services | ServicesProposal.enabled_services
- on_demand_srvs = exportable_on_demand_services
- disabled_srvs = exportable_disabled_services | ServicesProposal.disabled_services
+ #
+ # @param target [Symbol] Control how much information should be exported
+ # (e.g., :default or :compact).
+ # @return [Hash{String => Array<String>}] profile data
+ def export(target: :default)
+ exportable_services = select_exportable_services(target == :compact)
+
+ on_boot_srvs = exportable_on_boot_services(exportable_services)
+ on_demand_srvs = exportable_on_demand_services(exportable_services)
+ disabled_srvs = exportable_disabled_services(exportable_services)
log.info "Exported services: on boot: #{on_boot_srvs}; on-demand: #{on_demand_srvs}; " \
"disabled: #{disabled_srvs}"
- { "enable" => on_boot_srvs, "on_demand" => on_demand_srvs, "disable" => disabled_srvs }
+ exported = {
+ "enable" => on_boot_srvs, "on_demand" => on_demand_srvs, "disable" => disabled_srvs
+ }
+ exported.reject { |_k, v| v.empty? }
+ end
+
+ # Selects which services should be exported
+ #
+ # @param changed_preset [Boolean] Consider only those services which start mode is not the preset
+ # @return [Hash{String => Array<String>}] profile data
+ def select_exportable_services(changed_preset)
+ exportable_services = services.keys
+ return exportable_services unless changed_preset
+
+ exportable_services.reject! do |name|
+ exists?(name, &:default_start_mode?)
+ end
end
# Import services from AutoYast profile
@@ -460,16 +481,19 @@
# Selects candidate services to be exported as enabled to AutoYast profile
#
- # @return [Array<String>]
- def exportable_on_boot_services
- services.select { |n, _| start_mode(n) == :on_boot }.keys
+ # @param srvs [Array<String>] Exportable services names
+ # @return [Array<String>] Service names
+ def exportable_on_boot_services(srvs)
+ service_names = srvs.select { |s| start_mode(s) == :on_boot }
+ service_names | ServicesProposal.enabled_services
end
# Selects candidate services to be exported as enabled on-demand to AutoYast profile
#
- # @return [Array<String>]
- def exportable_on_demand_services
- services.select { |n, _| start_mode(n) == :on_demand }.keys
+ # @param srvs [Array<String>] Exportable services names
+ # @return [Array<String>] Service names
+ def exportable_on_demand_services(srvs)
+ srvs.select { |s| start_mode(s) == :on_demand }
end
# Selects candidate services to be exported as disabled to AutoYast profile
@@ -477,9 +501,11 @@
# Untouched services are discarded; only services modified by the user to be disabled must be
# exported to AutoYast profile.
#
- # @return [Array<String>]
- def exportable_disabled_services
- services.select { |n, s| s.changed? && !enabled(n) }.keys
+ # @param srvs [Array<String>] Exportable services names
+ # @return [Array<String>] Service names
+ def exportable_disabled_services(srvs)
+ service_names = srvs.select { |s| !enabled(s) && changed_value?(s, :start_mode) }
+ service_names | ServicesProposal.disabled_services
end
# Enable or disable given services according to its status
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-services-manager-4.3.0/test/services_manager_service_test.rb new/yast2-services-manager-4.3.1/test/services_manager_service_test.rb
--- old/yast2-services-manager-4.3.0/test/services_manager_service_test.rb 2020-05-12 18:02:09.000000000 +0200
+++ new/yast2-services-manager-4.3.1/test/services_manager_service_test.rb 2020-06-30 17:16:09.000000000 +0200
@@ -33,7 +33,7 @@
Yast2::SystemService, name: "cups", description: "CUPS", start: true, stop: true,
state: "active", substate: "running", changed?: false, start_mode: :on_boot,
save: nil, refresh: nil, errors: {}, found?: true, action: nil,
- keywords: ["cups.service", "cups.socket"]
+ keywords: ["cups.service", "cups.socket"], default_start_mode?: false
)
end
@@ -41,12 +41,20 @@
instance_double(
Yast2::SystemService, name: "dbus", changed?: true, start_mode: nil, active?: true,
running?: true, refresh: nil, save: nil, errors: {}, found?: true, action: nil,
- keywords: ["dbus.service"]
+ keywords: ["dbus.service"], default_start_mode?: false
+ )
+ end
+
+ let(:sshd) do
+ instance_double(
+ Yast2::SystemService, name: "sshd", changed?: false, start_mode: nil, active?: true,
+ running?: true, refresh: nil, save: nil, errors: {}, found?: true, action: nil,
+ keywords: ["sshd.service"], default_start_mode?: true
)
end
let(:services) do
- { "cups" => cups, "dbus" => dbus }
+ { "cups" => cups, "dbus" => dbus, "sshd" => sshd }
end
let(:loader) do
@@ -294,13 +302,27 @@
end
describe "#export" do
- before do
- allow(cups).to receive(:start_mode)
- allow(dbus).to receive(:start_mode)
- end
-
let(:exported_services) { subject.export }
+ context "on compact mode" do
+ let(:exported_services) { subject.export(target: :compact) }
+
+ context "when all services are using the preset start mode" do
+ before do
+ allow(dbus).to receive(:default_start_mode?).and_return(true)
+ allow(cups).to receive(:default_start_mode?).and_return(true)
+ end
+
+ it "does not return any list" do
+ expect(exported_services).to eq({})
+ end
+ end
+
+ it "exports the service which start mode is not the preset" do
+ expect(exported_services).to include("enable" => ["cups"])
+ end
+ end
+
context "when service is proposed to be started on boot" do
before do
allow(Yast::ServicesProposal).to receive(:enabled_services).and_return(["sshd"])
@@ -320,7 +342,6 @@
exported = subject.export
expect(exported["on_demand"]).to include("dbus")
expect(exported["enable"]).to_not include("dbus")
- expect(exported["disable"]).to_not include("dbus")
end
end
@@ -345,8 +366,8 @@
end
it "exports the service as disabled" do
- expect(exported_services["enable"]).to_not include("cups")
expect(exported_services["disable"]).to include("cups")
+ expect(exported_services["enable"]).to be_nil
end
end
@@ -357,7 +378,7 @@
it "exports the service as enable" do
expect(exported_services["enable"]).to include("cups")
- expect(exported_services["disable"]).to_not include("cups")
+ expect(exported_services["disable"]).to be_nil
end
end
@@ -368,8 +389,8 @@
it "exports the service to be started on demand" do
expect(exported_services["on_demand"]).to include("cups")
- expect(exported_services["enable"]).to_not include("cups")
- expect(exported_services["disable"]).to_not include("cups")
+ expect(exported_services["enable"]).to be_nil
+ expect(exported_services["disable"]).to be_nil
end
end
1
0
Hello community,
here is the log from the commit of package yast2-printer for openSUSE:Factory checked in at 2020-07-01 14:26:05
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-printer (Old)
and /work/SRC/openSUSE:Factory/.yast2-printer.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-printer"
Wed Jul 1 14:26:05 2020 rev:147 rq:817905 version:4.3.1
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-printer/yast2-printer.changes 2020-05-15 23:50:14.141303543 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-printer.new.3060/yast2-printer.changes 2020-07-01 14:26:11.998675462 +0200
@@ -1,0 +2,7 @@
+Tue Jun 30 13:55:10 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- AutoYaST: do not export printer settings if CUPS is disabled
+ (bsc#1172749).
+- 4.3.1
+
+-------------------------------------------------------------------
Old:
----
yast2-printer-4.3.0.tar.bz2
New:
----
yast2-printer-4.3.1.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-printer.spec ++++++
--- /var/tmp/diff_new_pack.2x6AOV/_old 2020-07-01 14:26:12.958678439 +0200
+++ /var/tmp/diff_new_pack.2x6AOV/_new 2020-07-01 14:26:12.958678439 +0200
@@ -17,7 +17,7 @@
Name: yast2-printer
-Version: 4.3.0
+Version: 4.3.1
Release: 0
Summary: YaST2 - Printer Configuration
License: GPL-2.0-only
++++++ yast2-printer-4.3.0.tar.bz2 -> yast2-printer-4.3.1.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/package/yast2-printer.changes new/yast2-printer-4.3.1/package/yast2-printer.changes
--- old/yast2-printer-4.3.0/package/yast2-printer.changes 2020-05-12 16:52:10.000000000 +0200
+++ new/yast2-printer-4.3.1/package/yast2-printer.changes 2020-06-30 16:34:10.000000000 +0200
@@ -1,4 +1,11 @@
-------------------------------------------------------------------
+Tue Jun 30 13:55:10 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- AutoYaST: do not export printer settings if CUPS is disabled
+ (bsc#1172749).
+- 4.3.1
+
+-------------------------------------------------------------------
Tue May 12 14:32:46 UTC 2020 - josef Reidinger <jreidinger@localhost>
- Autoyast schema: Allow optional types for string and map objects
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/package/yast2-printer.spec new/yast2-printer-4.3.1/package/yast2-printer.spec
--- old/yast2-printer-4.3.0/package/yast2-printer.spec 2020-05-12 16:52:10.000000000 +0200
+++ new/yast2-printer-4.3.1/package/yast2-printer.spec 2020-06-30 16:34:10.000000000 +0200
@@ -17,7 +17,7 @@
Name: yast2-printer
-Version: 4.3.0
+Version: 4.3.1
Release: 0
Summary: YaST2 - Printer Configuration
License: GPL-2.0-only
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/src/clients/printer_auto.rb new/yast2-printer-4.3.1/src/clients/printer_auto.rb
--- old/yast2-printer-4.3.0/src/clients/printer_auto.rb 2020-05-12 16:52:10.000000000 +0200
+++ new/yast2-printer-4.3.1/src/clients/printer_auto.rb 2020-06-30 16:34:10.000000000 +0200
@@ -183,15 +183,20 @@
# on another system from AutoYaST when AutoYaST on the other system
# calls the above Import function.
elsif @func == "Export"
- # what else could be exported instead in case of errors:
- @ret = {
- "cupsd_conf_content" => {
- "file_contents" => ReadFileContent("/etc/cups/cupsd.conf")
- },
- "client_conf_content" => {
- "file_contents" => ReadFileContent("/etc/cups/client.conf")
- }
- }
+ @ret = {}
+
+ if Printer.enabled?
+ # what else could be exported instead in case of errors:
+ @ret.merge!(
+ "cupsd_conf_content" => {
+ "file_contents" => ReadFileContent("/etc/cups/cupsd.conf")
+ },
+ "client_conf_content" => {
+ "file_contents" => ReadFileContent("/etc/cups/client.conf")
+ }
+ )
+ end
+
# Return packages needed to be installed and removed during
# Autoinstallation to ensure it has all needed software installed.
# @return map with 2 lists of strings $["install":[],"remove":[]]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/src/modules/Printer.rb new/yast2-printer-4.3.1/src/modules/Printer.rb
--- old/yast2-printer-4.3.0/src/modules/Printer.rb 2020-05-12 16:52:10.000000000 +0200
+++ new/yast2-printer-4.3.1/src/modules/Printer.rb 2020-06-30 16:34:10.000000000 +0200
@@ -29,6 +29,7 @@
require "shellwords"
require "yast"
+require "yast2/system_service"
module Yast
class PrinterClass < Module
@@ -2378,6 +2379,13 @@
true
end
+ # Determine whether the printer service ('cups') is enabled
+ # @return [Boolean] true if the service is enabled; false otherwise
+ def enabled?
+ service = Yast2::SystemService.find("cups")
+ !!service && service.start_mode != :manual
+ end
+
publish :function => :Modified, :type => "boolean ()"
publish :variable => :modified, :type => "boolean"
publish :variable => :AbortFunction, :type => "boolean ()"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/test/printer_auto_test.rb new/yast2-printer-4.3.1/test/printer_auto_test.rb
--- old/yast2-printer-4.3.0/test/printer_auto_test.rb 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-printer-4.3.1/test/printer_auto_test.rb 2020-06-30 16:34:10.000000000 +0200
@@ -0,0 +1,66 @@
+# Copyright (c) [2020] SUSE LLC
+#
+# 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 SUSE LLC.
+#
+# To contact SUSE LLC about this file by physical or electronic mail, you may
+# find current contact information at www.suse.com.
+
+require_relative "./test_helper"
+require_relative "../src/clients/printer_auto"
+
+describe Yast::PrinterAutoClient do
+ describe "#main" do
+ let(:args) { ["Export"] }
+
+ before do
+ allow(Yast::WFM).to receive(:Args) { |i = nil| i ? args[i] : args }
+ allow(subject).to receive(:ReadFileContent).with(/cupsd.conf/)
+ .and_return("cupsd.conf content")
+ allow(subject).to receive(:ReadFileContent).with(/client.conf/)
+ .and_return("client.conf content")
+ end
+
+ describe "Export" do
+ let(:enabled?) { true }
+
+ before do
+ allow(Yast::Printer).to receive(:enabled?).and_return(enabled?)
+ end
+
+ context "when the 'cups' service is enabled" do
+ let(:enabled) { true }
+
+ it "returns the content of CUPS configuration files" do
+ expect(subject.main).to include(
+ "cupsd_conf_content" => {
+ "file_contents" => "cupsd.conf content"
+ },
+ "client_conf_content" => {
+ "file_contents" => "client.conf content"
+ }
+ )
+ end
+ end
+
+ context "when the 'cups' service is disabled" do
+ let(:enabled?) { false }
+
+ it "returns an empty hash" do
+ expect(subject.main).to eq({})
+ end
+ end
+ end
+ end
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/test/printer_test.rb new/yast2-printer-4.3.1/test/printer_test.rb
--- old/yast2-printer-4.3.0/test/printer_test.rb 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-printer-4.3.1/test/printer_test.rb 2020-06-30 16:34:10.000000000 +0200
@@ -0,0 +1,64 @@
+# Copyright (c) [2020] SUSE LLC
+#
+# 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 SUSE LLC.
+#
+# To contact SUSE LLC about this file by physical or electronic mail, you may
+# find current contact information at www.suse.com.
+
+require_relative "./test_helper"
+
+Yast.import "Printer"
+
+describe Yast::Printer do
+ describe "#enabled?" do
+ let(:service) { instance_double(Yast2::SystemService, start_mode: start_mode) }
+
+ before do
+ allow(Yast2::SystemService).to receive(:find).with("cups").and_return(service)
+ end
+
+ context "if cups is started on boot" do
+ let(:start_mode) { :on_boot }
+
+ it "returns true" do
+ expect(subject.enabled?).to eq(true)
+ end
+ end
+
+ context "if cups is started on demand" do
+ let(:start_mode) { :on_demand }
+
+ it "returns true" do
+ expect(subject.enabled?).to eq(true)
+ end
+ end
+
+ context "if cups is disabled" do
+ let(:start_mode) { :manual }
+
+ it "returns false" do
+ expect(subject.enabled?).to eq(false)
+ end
+ end
+
+ context "if cups service does not exist" do
+ let(:service) { nil }
+
+ it "returns false" do
+ expect(subject.enabled?).to eq(false)
+ end
+ end
+ end
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-printer-4.3.0/test/test_helper.rb new/yast2-printer-4.3.1/test/test_helper.rb
--- old/yast2-printer-4.3.0/test/test_helper.rb 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-printer-4.3.1/test/test_helper.rb 2020-06-30 16:34:10.000000000 +0200
@@ -0,0 +1,44 @@
+# Copyright (c) [2020] SUSE LLC
+#
+# 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 SUSE LLC.
+#
+# To contact SUSE LLC about this file by physical or electronic mail, you may
+# find current contact information at www.suse.com.
+
+srcdir = File.expand_path("../../src", __FILE__)
+y2dirs = ENV.fetch("Y2DIR", "").split(":")
+ENV["Y2DIR"] = y2dirs.unshift(srcdir).join(":")
+
+require "yast"
+
+if ENV["COVERAGE"]
+ require "simplecov"
+ SimpleCov.start do
+ add_filter "/test/"
+ end
+
+ # track all ruby files under src
+ src_location = File.expand_path("../../src", __FILE__)
+ SimpleCov.track_files("#{src_location}/{module,lib}/**/*.rb")
+
+ # use coveralls for on-line code coverage reporting at Travis CI
+ if ENV["TRAVIS"]
+ require "coveralls"
+ SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
+ SimpleCov::Formatter::HTMLFormatter,
+ Coveralls::SimpleCov::Formatter
+ ]
+ end
+end
1
0
Hello community,
here is the log from the commit of package libstorage-ng for openSUSE:Factory checked in at 2020-07-01 14:26:02
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/libstorage-ng (Old)
and /work/SRC/openSUSE:Factory/.libstorage-ng.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libstorage-ng"
Wed Jul 1 14:26:02 2020 rev:87 rq:817872 version:4.3.32
Changes:
--------
--- /work/SRC/openSUSE:Factory/libstorage-ng/libstorage-ng.changes 2020-06-27 23:21:55.629693443 +0200
+++ /work/SRC/openSUSE:Factory/.libstorage-ng.new.3060/libstorage-ng.changes 2020-07-01 14:26:08.342664124 +0200
@@ -1,0 +2,34 @@
+Tue Jun 30 12:38:47 UTC 2020 - aschnell(a)suse.com
+
+- merge gh#openSUSE/libstorage-ng#753
+- Fixes for %_libexecdir changing to /usr/libexec
+- 4.3.32
+
+--------------------------------------------------------------------
+Mon Jun 29 15:04:21 UTC 2020 - aschnell(a)suse.com
+
+- merge gh#openSUSE/libstorage-ng#758
+- extended integration test
+- added integration test
+- added const
+- coding style
+- minor code and test improvements
+- 4.3.31
+
+--------------------------------------------------------------------
+Mon Jun 29 13:54:13 UTC 2020 - aschnell(a)suse.com
+
+- merge gh#openSUSE/libstorage-ng#757
+- also add a UsedFeature for pmem devices
+- 4.3.30
+
+--------------------------------------------------------------------
+Mon Jun 29 12:41:11 UTC 2020 - aschnell(a)suse.com
+
+- merge gh#openSUSE/libstorage-ng#756
+- merge gh#openSUSE/libstorage-ng#754
+- added UsedFeature for NVMe disks (for bsc#1172866)
+- Bsc1172866
+- 4.3.29
+
+--------------------------------------------------------------------
Old:
----
libstorage-ng-4.3.28.tar.xz
New:
----
libstorage-ng-4.3.32.tar.xz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ libstorage-ng.spec ++++++
--- /var/tmp/diff_new_pack.VEMjAv/_old 2020-07-01 14:26:09.114666518 +0200
+++ /var/tmp/diff_new_pack.VEMjAv/_new 2020-07-01 14:26:09.118666530 +0200
@@ -18,7 +18,7 @@
%define libname %{name}1
Name: libstorage-ng
-Version: 4.3.28
+Version: 4.3.32
Release: 0
Summary: Library for storage management
License: GPL-2.0-only
@@ -206,13 +206,13 @@
%files utils
%defattr(-,root,root)
-%dir %{_libexecdir}/libstorage-ng
-%{_libexecdir}/libstorage-ng/utils
+%dir %{_prefix}/lib/libstorage-ng
+%{_prefix}/lib/libstorage-ng/utils
%files integration-tests
%defattr(-,root,root)
%{python3_sitelib}/storageitu.py*
-%dir %{_libexecdir}/libstorage-ng
-%{_libexecdir}/libstorage-ng/integration-tests
+%dir %{_prefix}/lib/libstorage-ng
+%{_prefix}/lib/libstorage-ng/integration-tests
%changelog
++++++ libstorage-ng-4.3.28.tar.xz -> libstorage-ng-4.3.32.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/LIBVERSION new/libstorage-ng-4.3.32/LIBVERSION
--- old/libstorage-ng-4.3.28/LIBVERSION 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/LIBVERSION 2020-06-30 14:38:47.000000000 +0200
@@ -1 +1 @@
-1.39.0
+1.41.0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/VERSION new/libstorage-ng-4.3.32/VERSION
--- old/libstorage-ng-4.3.28/VERSION 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/VERSION 2020-06-30 14:38:47.000000000 +0200
@@ -1 +1 @@
-4.3.28
+4.3.32
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-dmsetup-info.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-dmsetup-info.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-dmsetup-info.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-dmsetup-info.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_cmddmsetupinfo(SystemInfo& system_info)
+test_cmd_dmsetup_info(SystemInfo& system_info)
{
try
{
- const CmdDmsetupInfo& cmddmsetupinfo = system_info.getCmdDmsetupInfo();
+ const CmdDmsetupInfo& cmd_dmsetup_info = system_info.getCmdDmsetupInfo();
cout << "CmdDmsetupInfo success" << endl;
- cout << cmddmsetupinfo << endl;
+ cout << cmd_dmsetup_info << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_cmddmsetupinfo(system_info);
+ test_cmd_dmsetup_info(system_info);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-dmsetup-table.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-dmsetup-table.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-dmsetup-table.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-dmsetup-table.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_cmddmsetuptable(SystemInfo& system_info)
+test_cmd_dmsetup_table(SystemInfo& system_info)
{
try
{
- const CmdDmsetupTable& cmddmsetuptable = system_info.getCmdDmsetupTable();
+ const CmdDmsetupTable& cmd_dmsetup_table = system_info.getCmdDmsetupTable();
cout << "CmdDmsetupTable success" << endl;
- cout << cmddmsetuptable << endl;
+ cout << cmd_dmsetup_table << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_cmddmsetuptable(system_info);
+ test_cmd_dmsetup_table(system_info);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-udevadm-info.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-udevadm-info.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-cmd-udevadm-info.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-cmd-udevadm-info.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,7 +8,7 @@
void
-test_udevadminfo(SystemInfo& system_info, const string& file)
+test_udevadm_info(SystemInfo& system_info, const string& file)
{
try
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_udevadminfo(system_info, "/dev/sda1");
+ test_udevadm_info(system_info, "/dev/sda1");
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdadm-detail.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdadm-detail.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdadm-detail.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdadm-detail.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_mdadmdetail(SystemInfo& system_info, const string& device)
+test_mdadm_detail(SystemInfo& system_info, const string& device)
{
try
{
- const MdadmDetail& mdadmdetail = system_info.getMdadmDetail(device);
+ const MdadmDetail& mdadm_detail = system_info.getMdadmDetail(device);
cout << "MdadmDetail success" << endl;
- cout << mdadmdetail << endl;
+ cout << mdadm_detail << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_mdadmdetail(system_info, "/dev/md127");
+ test_mdadm_detail(system_info, "/dev/md127");
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdadm-examine.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdadm-examine.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdadm-examine.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdadm-examine.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_mdadmexamine(SystemInfo& system_info, const vector<string>& devices)
+test_mdadm_examine(SystemInfo& system_info, const vector<string>& devices)
{
try
{
- const MdadmExamine& mdadmexamine = system_info.getMdadmExamine(devices);
+ const MdadmExamine& mdadm_examine = system_info.getMdadmExamine(devices);
cout << "MdadmExamine success" << endl;
- cout << mdadmexamine << endl;
+ cout << mdadm_examine << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_mdadmexamine(system_info, { "/dev/sda", "/dev/sdb" });
+ test_mdadm_examine(system_info, { "/dev/sda", "/dev/sdb" });
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdlinks.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdlinks.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-mdlinks.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-mdlinks.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_mdlinks(SystemInfo& system_info)
+test_md_links(SystemInfo& system_info)
{
try
{
- const MdLinks& mdlinks = system_info.getMdLinks();
+ const MdLinks& md_links = system_info.getMdLinks();
cout << "MdLinks success" << endl;
- cout << mdlinks << endl;
+ cout << md_links << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_mdlinks(system_info);
+ test_md_links(system_info);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-proc-mdstat.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-proc-mdstat.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-proc-mdstat.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-proc-mdstat.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_procmdstat(SystemInfo& system_info)
+test_proc_mdstat(SystemInfo& system_info)
{
try
{
- const ProcMdstat& procmdstat = system_info.getProcMdstat();
+ const ProcMdstat& proc_mdstat = system_info.getProcMdstat();
cout << "ProcMdstat success" << endl;
- cout << procmdstat << endl;
+ cout << proc_mdstat << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_procmdstat(system_info);
+ test_proc_mdstat(system_info);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/examples/SystemInfo/test-proc-mounts.cc new/libstorage-ng-4.3.32/examples/SystemInfo/test-proc-mounts.cc
--- old/libstorage-ng-4.3.28/examples/SystemInfo/test-proc-mounts.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/examples/SystemInfo/test-proc-mounts.cc 2020-06-30 14:38:47.000000000 +0200
@@ -8,13 +8,13 @@
void
-test_procmounts(SystemInfo& system_info)
+test_proc_mounts(SystemInfo& system_info)
{
try
{
- const ProcMounts& procmounts = system_info.getProcMounts();
+ const ProcMounts& proc_mounts = system_info.getProcMounts();
cout << "ProcMounts success" << endl;
- cout << procmounts << endl;
+ cout << proc_mounts << endl;
}
catch (const exception& e)
{
@@ -30,5 +30,5 @@
SystemInfo system_info;
- test_procmounts(system_info);
+ test_proc_mounts(system_info);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/integration-tests/misc/probe.py new/libstorage-ng-4.3.32/integration-tests/misc/probe.py
--- old/libstorage-ng-4.3.28/integration-tests/misc/probe.py 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/integration-tests/misc/probe.py 2020-06-30 14:38:47.000000000 +0200
@@ -62,5 +62,10 @@
print(probed)
-probed.save("devicegraph.xml")
+used_features = probed.used_features()
+for i in range(64):
+ if used_features & 1 << i:
+ print(i, '', end='')
+print()
+probed.save("devicegraph.xml")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/integration-tests/pools/create-raid1.py new/libstorage-ng-4.3.32/integration-tests/pools/create-raid1.py
--- old/libstorage-ng-4.3.28/integration-tests/pools/create-raid1.py 1970-01-01 01:00:00.000000000 +0100
+++ new/libstorage-ng-4.3.32/integration-tests/pools/create-raid1.py 2020-06-30 14:38:47.000000000 +0200
@@ -0,0 +1,38 @@
+#!/usr/bin/python3
+
+# requirements: at least two HDDs with free space
+
+
+from storage import *
+from storageitu import *
+
+
+set_logger(get_logfile_logger())
+
+environment = Environment(False)
+
+storage = Storage(environment)
+storage.probe()
+
+storage.generate_pools(storage.get_probed())
+
+pool = storage.get_pool("HDDs (512 B)")
+
+staging = storage.get_staging()
+
+try:
+ devices = pool.create_partitions(staging, 2, 2 * GiB)
+except PoolOutOfSpace as exception:
+ print(exception.what())
+ exit(1)
+
+md = Md.create(staging, Md.find_free_numeric_name(staging))
+md.set_md_level(MdLevel_RAID1)
+
+for device in devices:
+ md.add_device(device)
+ device.set_id(ID_RAID)
+
+print(staging)
+
+commit(storage)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/libstorage-ng.spec.in new/libstorage-ng-4.3.32/libstorage-ng.spec.in
--- old/libstorage-ng-4.3.28/libstorage-ng.spec.in 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/libstorage-ng.spec.in 2020-06-30 14:38:47.000000000 +0200
@@ -206,13 +206,13 @@
%files utils
%defattr(-,root,root)
-%dir %{_libexecdir}/libstorage-ng
-%{_libexecdir}/libstorage-ng/utils
+%dir %{_prefix}/lib/libstorage-ng
+%{_prefix}/lib/libstorage-ng/utils
%files integration-tests
%defattr(-,root,root)
%{python3_sitelib}/storageitu.py*
-%dir %{_libexecdir}/libstorage-ng
-%{_libexecdir}/libstorage-ng/integration-tests
+%dir %{_prefix}/lib/libstorage-ng
+%{_prefix}/lib/libstorage-ng/integration-tests
%changelog
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Devices/Disk.cc new/libstorage-ng-4.3.32/storage/Devices/Disk.cc
--- old/libstorage-ng-4.3.28/storage/Devices/Disk.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Devices/Disk.cc 2020-06-30 14:38:47.000000000 +0200
@@ -1,6 +1,6 @@
/*
* Copyright (c) [2014-2015] Novell, Inc.
- * Copyright (c) [2016-2019] SUSE LLC
+ * Copyright (c) [2016-2020] SUSE LLC
*
* All Rights Reserved.
*
@@ -145,6 +145,20 @@
}
+ bool
+ Disk::is_pmem() const
+ {
+ return get_impl().is_pmem();
+ }
+
+
+ bool
+ Disk::is_nvme() const
+ {
+ return get_impl().is_nvme();
+ }
+
+
vector<Disk*>
Disk::get_all(Devicegraph* devicegraph)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Devices/Disk.h new/libstorage-ng-4.3.32/storage/Devices/Disk.h
--- old/libstorage-ng-4.3.28/storage/Devices/Disk.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Devices/Disk.h 2020-06-30 14:38:47.000000000 +0200
@@ -125,6 +125,16 @@
ZoneModel get_zone_model() const;
/**
+ * Return whether the disk is an PMEM device.
+ */
+ bool is_pmem() const;
+
+ /**
+ * Return whether the disk is an NVMe device.
+ */
+ bool is_nvme() const;
+
+ /**
* Find a Disk by its name. Only the name returned by get_name() is
* considered.
*
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Devices/DiskImpl.cc new/libstorage-ng-4.3.32/storage/Devices/DiskImpl.cc
--- old/libstorage-ng-4.3.28/storage/Devices/DiskImpl.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Devices/DiskImpl.cc 2020-06-30 14:38:47.000000000 +0200
@@ -127,6 +127,20 @@
}
+ bool
+ Disk::Impl::is_pmem() const
+ {
+ return boost::starts_with(get_name(), DEV_DIR "/pmem");
+ }
+
+
+ bool
+ Disk::Impl::is_nvme() const
+ {
+ return boost::starts_with(get_name(), DEV_DIR "/nvme");
+ }
+
+
void
Disk::Impl::probe_disks(Prober& prober)
{
@@ -180,6 +194,12 @@
default: break;
}
+ if (is_pmem())
+ ret |= UF_PMEM;
+
+ if (is_nvme())
+ ret |= UF_NVME;
+
return ret | Partitionable::Impl::used_features();
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Devices/DiskImpl.h new/libstorage-ng-4.3.32/storage/Devices/DiskImpl.h
--- old/libstorage-ng-4.3.28/storage/Devices/DiskImpl.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Devices/DiskImpl.h 2020-06-30 14:38:47.000000000 +0200
@@ -1,6 +1,6 @@
/*
* Copyright (c) [2014-2015] Novell, Inc.
- * Copyright (c) [2016-2019] SUSE LLC
+ * Copyright (c) [2016-2020] SUSE LLC
*
* All Rights Reserved.
*
@@ -81,6 +81,9 @@
ZoneModel get_zone_model() const { return zone_model; }
void set_zone_model(ZoneModel zone_model) { Impl::zone_model = zone_model; }
+ bool is_pmem() const;
+ bool is_nvme() const;
+
static void probe_disks(Prober& prober);
virtual void probe_pass_1a(Prober& prober) override;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/UsedFeatures.h new/libstorage-ng-4.3.32/storage/UsedFeatures.h
--- old/libstorage-ng-4.3.28/storage/UsedFeatures.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/UsedFeatures.h 2020-06-30 14:38:47.000000000 +0200
@@ -61,6 +61,8 @@
UF_FCOE = 1 << 18,
UF_FC = 1 << 19,
UF_DASD = 1 << 20,
+ UF_PMEM = 1 << 29,
+ UF_NVME = 1 << 28,
UF_QUOTA = 1 << 21,
UF_SNAPSHOTS = 1 << 22
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Utils/AsciiFile.cc new/libstorage-ng-4.3.32/storage/Utils/AsciiFile.cc
--- old/libstorage-ng-4.3.28/storage/Utils/AsciiFile.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Utils/AsciiFile.cc 2020-06-30 14:38:47.000000000 +0200
@@ -96,7 +96,7 @@
void
- AsciiFile::save()
+ AsciiFile::save() const
{
if (Mockup::get_mode() == Mockup::Mode::PLAYBACK)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Utils/AsciiFile.h new/libstorage-ng-4.3.32/storage/Utils/AsciiFile.h
--- old/libstorage-ng-4.3.28/storage/Utils/AsciiFile.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Utils/AsciiFile.h 2020-06-30 14:38:47.000000000 +0200
@@ -48,7 +48,7 @@
/**
* @throw IOException
*/
- void save();
+ void save() const;
void log_content() const;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Utils/LinesIterator.cc new/libstorage-ng-4.3.32/storage/Utils/LinesIterator.cc
--- old/libstorage-ng-4.3.28/storage/Utils/LinesIterator.cc 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Utils/LinesIterator.cc 2020-06-30 14:38:47.000000000 +0200
@@ -28,7 +28,7 @@
{
const string&
- LinesIterator::line()
+ LinesIterator::line() const
{
if (it == lines.end())
ST_THROW(Exception("end of lines"));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Utils/LinesIterator.h new/libstorage-ng-4.3.32/storage/Utils/LinesIterator.h
--- old/libstorage-ng-4.3.28/storage/Utils/LinesIterator.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Utils/LinesIterator.h 2020-06-30 14:38:47.000000000 +0200
@@ -44,7 +44,7 @@
bool at_end() const { return it == lines.end(); }
- const string& line();
+ const string& line() const;
const string& pop_line();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libstorage-ng-4.3.28/storage/Utils/Text.h new/libstorage-ng-4.3.32/storage/Utils/Text.h
--- old/libstorage-ng-4.3.28/storage/Utils/Text.h 2020-06-22 10:23:32.000000000 +0200
+++ new/libstorage-ng-4.3.32/storage/Utils/Text.h 2020-06-30 14:38:47.000000000 +0200
@@ -47,7 +47,7 @@
Text(const char* native, const char* translated) : native(native), translated(translated) {}
Text(const string& native, const string& translated) : native(native), translated(translated) {}
- bool empty() { return native.empty(); }
+ bool empty() const { return native.empty(); }
void clear();
1
0
Hello community,
here is the log from the commit of package yast2-users for openSUSE:Factory checked in at 2020-07-01 14:25:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-users (Old)
and /work/SRC/openSUSE:Factory/.yast2-users.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-users"
Wed Jul 1 14:25:57 2020 rev:232 rq:817857 version:4.3.3
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-users/yast2-users.changes 2020-06-10 00:36:22.409069470 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-users.new.3060/yast2-users.changes 2020-07-01 14:26:05.574655540 +0200
@@ -1,0 +2,8 @@
+Mon Jun 29 15:28:01 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- Honor the 'target' argument when cloning the system. If it is
+ set to 'compact', a reduced list of users and groups is generated
+ (bsc#1172749).
+- 4.3.3
+
+-------------------------------------------------------------------
Old:
----
yast2-users-4.3.2.tar.bz2
New:
----
yast2-users-4.3.3.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-users.spec ++++++
--- /var/tmp/diff_new_pack.0imsrC/_old 2020-07-01 14:26:06.350657946 +0200
+++ /var/tmp/diff_new_pack.0imsrC/_new 2020-07-01 14:26:06.350657946 +0200
@@ -17,7 +17,7 @@
Name: yast2-users
-Version: 4.3.2
+Version: 4.3.3
Release: 0
Summary: YaST2 - User and Group Configuration
License: GPL-2.0-only
@@ -32,8 +32,8 @@
BuildRequires: libtool
BuildRequires: perl-Digest-SHA1
BuildRequires: update-desktop-files
-# CLI readonly
-BuildRequires: yast2 >= 4.2.57
+# 'target' argument for Installation::AutoClient#export method
+BuildRequires: yast2 >= 4.3.10
BuildRequires: yast2-core-devel
BuildRequires: yast2-devtools >= 4.2.2
BuildRequires: yast2-perl-bindings
@@ -57,8 +57,8 @@
# this forces using yast2-ldap with correct LDAP object names (fate#303596)
Requires: yast2-ldap >= 3.1.2
-# CLI readonly
-Requires: yast2 >= 4.2.57
+# 'target' argument for Installation::AutoClient#export method
+Requires: yast2 >= 4.3.10
# cryptsha256, cryptsha516
Requires: yast2-core >= 2.21.0
++++++ yast2-users-4.3.2.tar.bz2 -> yast2-users-4.3.3.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/package/yast2-users.changes new/yast2-users-4.3.3/package/yast2-users.changes
--- old/yast2-users-4.3.2/package/yast2-users.changes 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/package/yast2-users.changes 2020-06-30 13:07:33.000000000 +0200
@@ -1,4 +1,12 @@
-------------------------------------------------------------------
+Mon Jun 29 15:28:01 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- Honor the 'target' argument when cloning the system. If it is
+ set to 'compact', a reduced list of users and groups is generated
+ (bsc#1172749).
+- 4.3.3
+
+-------------------------------------------------------------------
Wed May 27 11:55:44 UTC 2020 - David Diaz <dgonzalez(a)suse.com>
- Dropped legacy testsuite (related to bsc#1138668).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/package/yast2-users.spec new/yast2-users-4.3.3/package/yast2-users.spec
--- old/yast2-users-4.3.2/package/yast2-users.spec 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/package/yast2-users.spec 2020-06-30 13:07:33.000000000 +0200
@@ -17,7 +17,7 @@
Name: yast2-users
-Version: 4.3.2
+Version: 4.3.3
Release: 0
Summary: YaST2 - User and Group Configuration
License: GPL-2.0-only
@@ -32,8 +32,8 @@
BuildRequires: libtool
BuildRequires: perl-Digest-SHA1
BuildRequires: update-desktop-files
-# CLI readonly
-BuildRequires: yast2 >= 4.2.57
+# 'target' argument for Installation::AutoClient#export method
+BuildRequires: yast2 >= 4.3.10
BuildRequires: yast2-core-devel
BuildRequires: yast2-devtools >= 4.2.2
BuildRequires: yast2-perl-bindings
@@ -57,8 +57,8 @@
# this forces using yast2-ldap with correct LDAP object names (fate#303596)
Requires: yast2-ldap >= 3.1.2
-# CLI readonly
-Requires: yast2 >= 4.2.57
+# 'target' argument for Installation::AutoClient#export method
+Requires: yast2 >= 4.3.10
# cryptsha256, cryptsha516
Requires: yast2-core >= 2.21.0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/Makefile.am new/yast2-users-4.3.3/src/Makefile.am
--- old/yast2-users-4.3.2/src/Makefile.am 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/src/Makefile.am 2020-06-30 13:07:33.000000000 +0200
@@ -38,6 +38,7 @@
ylibclientdir = @ylibdir@/users/clients
ylibclient_DATA = \
+ lib/users/clients/auto.rb \
lib/users/clients/users_finish.rb
yncludedir = @yncludedir@/users
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/clients/users_auto.rb new/yast2-users-4.3.3/src/clients/users_auto.rb
--- old/yast2-users-4.3.2/src/clients/users_auto.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/src/clients/users_auto.rb 2020-06-30 13:07:33.000000000 +0200
@@ -19,167 +19,5 @@
# current contact information at www.novell.com.
# ------------------------------------------------------------------------------
-# File:
-# users_auto.ycp
-#
-# Package:
-# Configuration of Users
-#
-# Summary:
-# Client for autoinstallation
-#
-# Authors:
-# Anas Nashif <nashif(a)suse.de>
-#
-# $Id$
-#
-# This is a client for autoinstallation. It takes its arguments,
-# goes through the configuration and return the setting.
-# Does not do any changes to the configuration.
-
-Yast.import "Report"
-
-module Yast
- class UsersAutoClient < Client
-
- def main
- Yast.import "UI"
- textdomain "users"
- Yast.import "Mode"
- Yast.import "Users"
- Yast.import "UsersSimple"
- Yast.import "Wizard"
-
- Yast.include self, "users/wizards.rb"
-
- @ret = nil
- @func = ""
- @param = {}
- # Check arguments
- if Ops.greater_than(Builtins.size(WFM.Args), 0) &&
- Ops.is_string?(WFM.Args(0))
- @func = Convert.to_string(WFM.Args(0))
- if Ops.greater_than(Builtins.size(WFM.Args), 1) &&
- Ops.is_map?(WFM.Args(1))
- @param = Convert.convert(
- WFM.Args(1),
- :from => "any",
- :to => "map <string, any>"
- )
- end
- end
- Builtins.y2debug("func=%1", @func)
- Builtins.y2debug("param=%1", @param)
-
-
- @users = [
- {
- "username" => "my_user",
- "user_password" => "passw",
- "encrypted" => false,
- # "uid":501,
- "gid" => 100,
- "password_settings" => { "expire" => "" },
- "grouplist" => "audio"
- },
- {
- "username" => "daemon",
- "user_password" => "pass",
- "encrypted" => false
- },
- { "username" => "root", "uidNumber" => 0, "user_password" => "pass" }
- ]
-
- # param = $["users": users];
-
- if @func == "Import"
- check_users(@param["users"] || [])
- @ret = Users.Import(@param)
- # create a summary
- elsif @func == "Summary"
- @ret = Users.Summary
- elsif @func == "Reset"
- Users.Import({})
- @ret = {}
- elsif @func == "Packages"
- @ret = {}
- elsif @func == "Change"
- @start_dialog = "summary" #look to users.ycp for possible values
- Wizard.CreateDialog
- Wizard.SetDesktopIcon("org.opensuse.yast.Users")
- @ret = AutoSequence(@start_dialog)
- Wizard.CloseDialog
- elsif @func == "Export"
- if Stage.initial
- # Importing all users/groups from the UI if we are
- # in the installation workflow
- Users.SetExportAll(true)
- setup_all_users
- end
-
- @ret = Users.Export
-
- if Stage.initial
- #Setting root password in the return value. We are in the inst_sys.
- #The root password has not been written but is only available in
- #UserSimple model. We have to set it manually.
- root = @ret["users"].find { |u| u["uid"] == "0" }
- root["user_password"] = Users.CryptPassword(UsersSimple.GetRootPassword, "system") if root
- end
- Users.SetExportAll(false)
- elsif @func == "Read"
- Yast.import "Progress"
- Users.SetExportAll(true)
- @progress_orig = Progress.set(false)
- @ret = Users.Read == ""
- Progress.set(@progress_orig)
- elsif @func == "Write"
- # NOTE: this code is not executed during autoinstallation (instead, the
- # users_finish is used).
- Yast.import "Progress"
- Users.SetWriteOnly(true)
- @progress_orig = Progress.set(false)
- @ret = Users.Write == ""
- Progress.set(@progress_orig)
- # Return if configuration was changed
- # return boolean
- elsif @func == "GetModified"
- @ret = Users.Modified
- # Set all modified flags
- # return boolean
- elsif @func == "SetModified"
- Users.SetModified(true)
- @ret = true
- else
- Builtins.y2error("unknown function: %1", @func)
- @ret = false
- end
-
- Builtins.y2debug("ret=%1", @ret)
- Builtins.y2milestone("users auto finished")
- Builtins.y2milestone("----------------------------------------")
-
- deep_copy(@ret)
- end
-
- private
-
- # Checking double user entries
- # (double username or UID)
- # @param [Array] users to check
- def check_users(users)
- if users.size > users.uniq { |u| u["username"]}.size
- Report.Error(_("Found users in profile with equal <username>."))
- end
- # Do not check users without defined UID. (bnc#996823)
- check_users = users.dup
- check_users.reject! { |u| !u.key?("uid")}
- if check_users.size > check_users.uniq { |u| u["uid"]}.size
- Report.Error(_("Found users in profile with equal <uid>."))
- end
- end
-
- end
-end
-
-Yast::UsersAutoClient.new.main
+require "users/clients/auto"
+Y2Users::Clients::Auto.new.run
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/lib/users/clients/auto.rb new/yast2-users-4.3.3/src/lib/users/clients/auto.rb
--- old/yast2-users-4.3.2/src/lib/users/clients/auto.rb 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-users-4.3.3/src/lib/users/clients/auto.rb 2020-06-30 13:07:33.000000000 +0200
@@ -0,0 +1,111 @@
+# Copyright (c) [2020] SUSE LLC
+#
+# 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 SUSE LLC.
+#
+# To contact SUSE LLC about this file by physical or electronic mail, you may
+# find current contact information at www.suse.com.
+
+require "yast"
+require "installation/auto_client"
+
+Yast.import "Users"
+Yast.import "UsersSimple"
+Yast.import "Mode"
+Yast.import "Progress"
+Yast.import "Report"
+Yast.import "Stage"
+Yast.import "Wizard"
+
+module Y2Users
+ module Clients
+ # AutoYaST users client
+ class Auto < ::Installation::AutoClient
+ def initialize
+ textdomain "users"
+
+ Yast.include self, "users/wizards.rb"
+ end
+
+ protected
+
+ def import(param)
+ check_users(param["users"] || [])
+ Yast::Users.Import(param)
+ end
+
+ def summary
+ Yast::Users.Summary
+ end
+
+ def change
+ Yast::Wizard.CreateDialog
+ Yast::Wizard.SetDesktopIcon("org.opensuse.yast.Users")
+ ret = AutoSequence("summary")
+ Yast::Wizard.CloseDialog
+ ret
+ end
+
+ def export(target:)
+ Yast::Users.Export(target.to_s)
+ end
+
+ def read
+ Yast::Users.SetExportAll(true)
+ progress_orig = Yast::Progress.set(false)
+ ret = Yast::Users.Read == ""
+ Yast::Progress.set(progress_orig)
+ ret
+ end
+
+ # @note This code is not executed during autoinstallation (instead, the
+ # users_finish is used). However, it is used when running ayast_setup.
+ #
+ # @return [Boolean] true if configuration was changed; false otherwise.
+ def write
+ Yast::Users.SetWriteOnly(true)
+ progress_orig = Yast::Progress.set(false)
+ ret = Yast::Users.Write == ""
+ Yast::Progress.set(progress_orig)
+ ret
+ end
+
+ def modified?
+ Yast::Users.Modified
+ end
+
+ def modified
+ Yast::Users.SetModified(true)
+ true
+ end
+
+ private
+
+ # Checking double user entries
+ # (double username or UID)
+ # @param [Array] users to check
+ def check_users(users)
+ if users.size > users.uniq { |u| u["username"] }.size
+ Yast::Report.Error(_("Found users in profile with equal <username>."))
+ end
+ # Do not check users without defined UID. (bnc#996823)
+ check_users = users.dup
+ check_users.reject! { |u| !u.key?("uid") }
+ if check_users.size > check_users.uniq { |u| u["uid"] }.size
+ Yast::Report.Error(_("Found users in profile with equal <uid>."))
+ end
+ end
+ end
+ end
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/lib/users/dialogs/inst_user_first.rb new/yast2-users-4.3.3/src/lib/users/dialogs/inst_user_first.rb
--- old/yast2-users-4.3.2/src/lib/users/dialogs/inst_user_first.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/src/lib/users/dialogs/inst_user_first.rb 2020-06-30 13:07:33.000000000 +0200
@@ -200,8 +200,8 @@
help += _(
"<p>\nA previous Linux installation with local users has been detected.\n" \
"The information there can be used to create users in the system being installed.\n" \
- "Use the <b>Choose Users</b> button to select some users. Their basic information will\n" \
- "be imported.\n</p>\n"
+ "Use the <b>Choose Users</b> button to select some users. Their basic information will" \
+ "\nbe imported.\n</p>\n"
)
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/lib/users/proposal.rb new/yast2-users-4.3.3/src/lib/users/proposal.rb
--- old/yast2-users-4.3.2/src/lib/users/proposal.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/src/lib/users/proposal.rb 2020-06-30 13:07:33.000000000 +0200
@@ -66,7 +66,7 @@
when "users--encryption"
client = "users_encryption_method"
else
- raise "Unknown action id: #{param['chosen_id']}"
+ raise "Unknown action id: #{param["chosen_id"]}"
end
result = WFM.CallFunction(client, [args])
@@ -87,7 +87,8 @@
# menu button label
{ "id" => "users--root", "title" => _("&Root Password") },
# menu button label
- { "id" => "users--encryption", "title" => _("Password &Encryption Type") }]
+ { "id" => "users--encryption", "title" => _("Password &Encryption Type") }
+ ]
id = "users"
end
@@ -104,8 +105,8 @@
def users_ay
export = Users.Export()
ret = _("Number of defined users/groups:")
- ret += "<ul>\n<li>" + format(_("Users: %d"), export["users"].count()) + "</li>\n"
- ret += "<li>" + format(_("Groups: %d"), export["groups"].count()) + "</li></ul>"
+ ret += "<ul>\n<li>" + format(_("Users: %d"), export["users"].count) + "</li>\n"
+ ret += "<li>" + format(_("Groups: %d"), export["groups"].count) + "</li></ul>"
ret
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/src/modules/Users.pm new/yast2-users-4.3.3/src/modules/Users.pm
--- old/yast2-users-4.3.2/src/modules/Users.pm 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/src/modules/Users.pm 2020-06-30 13:07:33.000000000 +0200
@@ -6564,32 +6564,38 @@
# (For use by autoinstallation.)
# @return map Dumped settings (later acceptable by Import ())
BEGIN { $TYPEINFO{Export} = ["function",
- ["map", "string", "any"]];
+ ["map", "string", "any"], "string"];
}
sub Export {
my $self = shift;
+ my $target = shift;
+ $target = "default" if not defined $target;
+ my $export_system = ($target ne "compact");
my @exported_users = ();
# local users when modified
if (defined $users{"local"}) {
- foreach my $user (values %{$users{"local"}}) {
- if ($export_all || defined $user->{"modified"}) {
- push @exported_users, $self->ExportUser ($user);
- }
- }
+ foreach my $user (values %{$users{"local"}}) {
+ if ($export_all || defined $user->{"modified"}) {
+ push @exported_users, $self->ExportUser ($user);
+ }
+ }
}
# modified system users:
- if (defined $users{"system"}) {
- foreach my $user (values %{$users{"system"}}) {
- if ($export_all || defined $user->{"modified"}) {
- push @exported_users, $self->ExportUser ($user);
- }
- }
+ if (defined($users{"system"})) {
+ foreach my $user (values %{$users{"system"}}) {
+ if ($export_all || defined $user->{"modified"}) {
+ if ($export_system || $user->{"uid"} eq "root") {
+ push @exported_users, $self->ExportUser ($user);
+ }
+ }
+ }
}
my @exported_groups = ();
# modified local system groups:
+
if (defined $groups{"local"}) {
foreach my $group (values %{$groups{"local"}}) {
if ($export_all || defined $group->{"modified"}) {
@@ -6599,7 +6605,7 @@
}
# modified system groups:
- if (defined $groups{"system"}) {
+ if ($export_system && defined($groups{"system"})) {
foreach my $group (values %{$groups{"system"}}) {
if ($export_all || defined $group->{"modified"}) {
push @exported_groups, $self->ExportGroup ($group);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/Makefile.am new/yast2-users-4.3.3/test/Makefile.am
--- old/yast2-users-4.3.2/test/Makefile.am 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/test/Makefile.am 2020-06-30 13:07:33.000000000 +0200
@@ -6,6 +6,7 @@
lib/users/users_database_test.rb \
lib/users/leaf_blk_device_test.rb \
lib/users/ssh_public_key_test.rb \
+ lib/users/clients/auto_test.rb \
lib/users/dialogs/inst_root_first_test.rb \
lib/users/dialogs/inst_user_first_test.rb \
lib/users/widgets/inst_root_first_test.rb \
@@ -13,7 +14,6 @@
dialogs_test.rb \
ssh_authorized_keys_test.rb \
users_test.rb \
- users_auto_test.rb \
users_finish_test.rb \
users_simple_test.rb \
widgets_test.rb
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/dialogs_test.rb new/yast2-users-4.3.3/test/dialogs_test.rb
--- old/yast2-users-4.3.2/test/dialogs_test.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/test/dialogs_test.rb 2020-06-30 13:07:33.000000000 +0200
@@ -1,6 +1,6 @@
require_relative "./test_helper"
-require "yast2/execute";
+require "yast2/execute"
Yast.import "UI"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/lib/users/clients/auto_test.rb new/yast2-users-4.3.3/test/lib/users/clients/auto_test.rb
--- old/yast2-users-4.3.2/test/lib/users/clients/auto_test.rb 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-users-4.3.3/test/lib/users/clients/auto_test.rb 2020-06-30 13:07:33.000000000 +0200
@@ -0,0 +1,120 @@
+#!/usr/bin/env rspec
+
+require_relative "../../../test_helper"
+require "yaml"
+require "users/clients/auto"
+Yast.import "Report"
+
+describe Y2Users::Clients::Auto do
+ let(:mode) { "autoinstallation" }
+ let(:args) { [func] }
+
+ before do
+ allow(Yast).to receive(:import).and_call_original
+ allow(Yast).to receive(:import).with("Ldap")
+ allow(Yast).to receive(:import).with("LdapPopup")
+ allow(Yast::Mode).to receive(:mode).and_return(mode)
+ allow(Yast::WFM).to receive(:Args).and_return(args)
+ end
+
+ describe "#run" do
+ context "Import" do
+ let(:func) { "Import" }
+ let(:args) { [func, users] }
+
+ context "when double users have been given in the profile" do
+ let(:users) { YAML.load_file(FIXTURES_PATH.join("users_error.yml")) }
+
+ it "report error" do
+ expect(Yast::Report).to receive(:Error)
+ .with(_("Found users in profile with equal <username>."))
+ expect(Yast::Report).to receive(:Error)
+ .with(_("Found users in profile with equal <uid>."))
+ expect(subject.run).to eq(true)
+ end
+ end
+
+ context "when users without any UID are defined in the profile" do
+ let(:users) { YAML.load_file(FIXTURES_PATH.join("users_no_error.yml")) }
+
+ it "will not be checked for double UIDs" do
+ expect(Yast::Report).not_to receive(:Error)
+ .with(_("Found users in profile with equal <username>."))
+ expect(Yast::Report).not_to receive(:Error)
+ .with(_("Found users in profile with equal <uid>."))
+ expect(subject.run).to eq(true)
+ end
+ end
+ end
+
+ context "Change" do
+ let(:func) { "Change" }
+
+ it "returns the 'summary' autosequence result" do
+ expect(subject).to receive(:AutoSequence).and_return(:next)
+ expect(subject.run).to eq(:next)
+ end
+ end
+
+ context "Summary" do
+ let(:func) { "Summary" }
+
+ before do
+ allow(Yast::Users).to receive(:Summary).and_return("summary")
+ end
+
+ it "returns the users summary" do
+ expect(subject.run).to eq("summary")
+ end
+ end
+
+ context "Export" do
+ let(:func) { "Export" }
+ let(:args) { [func] }
+
+ let(:local_users) { double("local_users") }
+ let(:all_users) { double("all_users") }
+
+ before do
+ allow(Yast::WFM).to receive(:Args).and_return(args)
+ allow(Yast::Users).to receive(:Export).with("default")
+ .and_return(all_users)
+ allow(Yast::Users).to receive(:Export).with("compact")
+ .and_return(local_users)
+ end
+
+ it "exports all users and groups" do
+ expect(subject.run).to eq(all_users)
+ end
+
+ context "when 'compact' export is wanted" do
+ let(:args) { [func, "target" => "compact"] }
+
+ it "it exports only local users and groups" do
+ expect(subject.run).to eq(local_users)
+ end
+ end
+ end
+
+ context "Modified" do
+ let(:func) { "GetModified" }
+
+ before do
+ allow(Yast::Users).to receive(:Modified).and_return(true)
+ end
+
+ it "returns whether the data in Users module has been modified" do
+ expect(subject.run).to eq(true)
+ end
+ end
+
+ context "SetModified" do
+ let(:func) { "SetModified" }
+
+ it "sets the Users module as modified" do
+ expect(Yast::Users).to receive(:SetModified).with(true)
+ subject.run
+ end
+ end
+ end
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/users_auto_test.rb new/yast2-users-4.3.3/test/users_auto_test.rb
--- old/yast2-users-4.3.2/test/users_auto_test.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/test/users_auto_test.rb 1970-01-01 01:00:00.000000000 +0100
@@ -1,58 +0,0 @@
-#!/usr/bin/env rspec
-
-require_relative "test_helper"
-require "yaml"
-
-describe "Yast::UsersAutoClient" do
- Yast.import "WFM"
- Yast.import "Users"
- Yast.import "Users"
- Yast.import "Report"
-
- subject { Yast::UsersAutoClient.new }
- let(:mode) { "autoinstallation" }
-
- before do
- allow(Yast).to receive(:import).and_call_original
- allow(Yast).to receive(:import).with("Ldap")
- allow(Yast).to receive(:import).with("LdapPopup")
-
- allow(Yast::Mode).to receive(:mode).and_return(mode)
-
- # this actually executes the client 8-O
- require_relative "../src/clients/users_auto"
- end
-
- describe "#AutoYaST" do
- context "Import" do
- before do
- allow(Yast::WFM).to receive(:Args).with(no_args).and_return([func, users])
- allow(Yast::WFM).to receive(:Args).with(0).and_return(func)
- allow(Yast::WFM).to receive(:Args).with(1).and_return(users)
- end
-
- let(:func) { "Import" }
-
- context "when double users have been given in the profile" do
- let(:users) { YAML.load_file(FIXTURES_PATH.join("users_error.yml")) }
- it "report error" do
- expect(Yast::Report).to receive(:Error)
- .with(_("Found users in profile with equal <username>."))
- expect(Yast::Report).to receive(:Error)
- .with(_("Found users in profile with equal <uid>."))
- expect(subject.main).to eq(true)
- end
- end
- context "when users without any UID are defined in the profile" do
- let(:users) { YAML.load_file(FIXTURES_PATH.join("users_no_error.yml")) }
- it "will not be checked for double UIDs" do
- expect(Yast::Report).not_to receive(:Error)
- .with(_("Found users in profile with equal <username>."))
- expect(Yast::Report).not_to receive(:Error)
- .with(_("Found users in profile with equal <uid>."))
- expect(subject.main).to eq(true)
- end
- end
- end
- end
-end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/users_simple_test.rb new/yast2-users-4.3.3/test/users_simple_test.rb
--- old/yast2-users-4.3.2/test/users_simple_test.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/test/users_simple_test.rb 2020-06-30 13:07:33.000000000 +0200
@@ -70,7 +70,8 @@
end
it "returns non-empty string for invalid username" do
- expect(users.CheckUsernameContents("abc; touch > /tmp/hacker.was.here; echo abc", "ldap")).to_not be_empty
+ expect(users.CheckUsernameContents("abc; touch > /tmp/hacker.was.here; echo abc", "ldap"))
+ .to_not be_empty
end
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-users-4.3.2/test/users_test.rb new/yast2-users-4.3.3/test/users_test.rb
--- old/yast2-users-4.3.2/test/users_test.rb 2020-05-27 14:37:36.000000000 +0200
+++ new/yast2-users-4.3.3/test/users_test.rb 2020-06-30 13:07:33.000000000 +0200
@@ -45,4 +45,71 @@
end
end
end
+
+ describe "#Export" do
+ let(:root_user) { { "username" => "root", "uid" => "0" } }
+ let(:local_user) { { "username" => "user1", "uid" => "1000" } }
+ let(:system_user) { { "username" => "messagebus", "uid" => "499" } }
+
+ let(:local_group) { { "groupname" => "devops", "gid" => "1000" } }
+ let(:users_group) { { "groupname" => "users", "gid" => "100" } }
+ let(:system_group) { { "groupname" => "messagebus", "gid" => "480" } }
+
+ before do
+ Yast::Users.Import(
+ "users" => [root_user, local_user, system_user],
+ "groups" => [users_group, local_group, system_group],
+ "login_settings" => { "autologin_user" => "root", "password_less_login" => true },
+ "user_defaults" => { "group" => "100", "home" => "/srv/Users" }
+ )
+ end
+
+ it "exports users" do
+ exported = subject.Export
+ expect(exported["users"]).to contain_exactly(
+ a_hash_including(root_user),
+ a_hash_including(local_user),
+ a_hash_including(system_user)
+ )
+ end
+
+ it "exports groups" do
+ exported = subject.Export
+ expect(exported["groups"]).to contain_exactly(
+ a_hash_including(users_group),
+ a_hash_including(local_group),
+ a_hash_including(system_group)
+ )
+ end
+
+ it "export login settings" do
+ exported = subject.Export
+ expect(exported["login_settings"]).to eq(
+ "autologin_user" => "root", "password_less_login" => true
+ )
+ end
+
+ it "exports user defaults" do
+ exported = subject.Export
+ expect(exported["user_defaults"]).to include("home" => "/srv/Users")
+ end
+
+ context "when 'compact' target is required" do
+ it "exports 'root' and local users" do
+ exported = subject.Export("compact")
+ expect(exported["users"]).to contain_exactly(
+ a_hash_including(root_user),
+ a_hash_including(local_user)
+ )
+ end
+
+ it "exports 'users' and local groups" do
+ exported = subject.Export("compact")
+ expect(exported["groups"]).to contain_exactly(
+ a_hash_including(users_group),
+ a_hash_including(local_group)
+ )
+ end
+ end
+ end
end
1
0
Hello community,
here is the log from the commit of package yast2 for openSUSE:Factory checked in at 2020-07-01 14:25:51
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2 (Old)
and /work/SRC/openSUSE:Factory/.yast2.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2"
Wed Jul 1 14:25:51 2020 rev:486 rq:817856 version:4.3.12
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2/yast2.changes 2020-06-27 23:21:58.157701754 +0200
+++ /work/SRC/openSUSE:Factory/.yast2.new.3060/yast2.changes 2020-07-01 14:26:02.202645082 +0200
@@ -1,0 +2,20 @@
+Mon Jun 29 15:26:44 UTC 2020 - schubi(a)suse.de
+- Products: Do not solve dependencies while checking libzypp
+ connection (bsc#1170322).
+- 4.3.12
+
+-------------------------------------------------------------------
+Mon Jun 29 14:26:44 UTC 2020 - José Iván López González <jlopez(a)suse.com>
+
+- Avoid failure when downloading release notes from an inoperative
+ proxy (bsc#1173447).
+- 4.3.11
+
+-------------------------------------------------------------------
+Fri Jun 26 15:00:17 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- AutoClient#export method can receive a hash as an argument
+ (bsc#1171356).
+- 4.3.10
+
+-------------------------------------------------------------------
Old:
----
yast2-4.3.9.tar.bz2
New:
----
yast2-4.3.12.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2.spec ++++++
--- /var/tmp/diff_new_pack.gWMUJt/_old 2020-07-01 14:26:02.942647377 +0200
+++ /var/tmp/diff_new_pack.gWMUJt/_new 2020-07-01 14:26:02.946647389 +0200
@@ -1,7 +1,7 @@
#
# spec file for package yast2
#
-# Copyright (c) 2020 SUSE LLC
+# 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
@@ -12,17 +12,17 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
-# Please submit bugfixes or comments via https://bugs.opensuse.org/
+# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: yast2
-Version: 4.3.9
+Version: 4.3.12
Release: 0
Summary: YaST2 Main Package
License: GPL-2.0-only
Group: System/YaST
-URL: https://github.com/yast/yast-yast2
+Url: https://github.com/yast/yast-yast2
Source0: %{name}-%{version}.tar.bz2
Source1: yast2-rpmlintrc
++++++ yast2-4.3.9.tar.bz2 -> yast2-4.3.12.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/library/general/src/lib/installation/auto_client.rb new/yast2-4.3.12/library/general/src/lib/installation/auto_client.rb
--- old/yast2-4.3.9/library/general/src/lib/installation/auto_client.rb 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/library/general/src/lib/installation/auto_client.rb 2020-06-30 13:01:18.000000000 +0200
@@ -61,7 +61,10 @@
when "Import"
import(param)
when "Export"
- export
+ target = param["target"] if param.is_a?(Hash)
+ target ||= "default"
+ m = method(:export)
+ m.arity.zero? ? export : export(target: target.to_sym)
when "Summary"
summary
when "Reset"
@@ -99,9 +102,11 @@
#
# The profile is a Hash or an Array according to the configuration item
# `X-SuSE-YaST-AutoInstDataType`
+ # @param target [Symbol] Control how much information should be exported
+ # (e.g., :default or :compact).
# @return [Hash, Array] profile data
- def export
- raise NotImplementedError, "Calling abstract method 'export'"
+ def export(target:)
+ raise NotImplementedError, "Calling abstract method 'export' with target '#{target}'"
end
# Provide a brief summary of configuration.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/library/general/test/auto_client_test.rb new/yast2-4.3.12/library/general/test/auto_client_test.rb
--- old/yast2-4.3.9/library/general/test/auto_client_test.rb 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/library/general/test/auto_client_test.rb 2020-06-30 13:01:18.000000000 +0200
@@ -9,11 +9,21 @@
args.empty? ? "import" : args
end
- ["export", "summary", "reset", "change", "write", "packages", "read", "modified?", "modified"].each do |m|
+ def export(target:)
+ target
+ end
+
+ ["summary", "reset", "change", "write", "packages", "read", "modified?", "modified"].each do |m|
define_method(m.to_sym) { m }
end
end
+class ExportTestAuto < ::Installation::AutoClient
+ def export
+ "export"
+ end
+end
+
describe ::Installation::AutoClient do
subject { ::TestAuto }
describe ".run" do
@@ -45,11 +55,29 @@
context "first client argument is Export" do
before do
- allow(Yast::WFM).to receive(:Args).and_return(["Export", {}])
+ allow(Yast::WFM).to receive(:Args).and_return(["Export"])
end
it "dispatch call to abstract method export" do
- expect(subject.run).to eq "export"
+ expect(subject.run).to eq(:default)
+ end
+
+ context "when 'target' argument is given an accepted by export method" do
+ before do
+ allow(Yast::WFM).to receive(:Args).and_return(["Export", { "target" => "compact" }])
+ end
+
+ it "dispatch call to abstract method export with 'target' argument" do
+ expect(subject.run).to eq(:compact)
+ end
+ end
+
+ context "when #export does not receive any argument" do
+ subject { ::ExportTestAuto }
+
+ it "dispatch call to abstract method export with no arguments" do
+ expect(subject.run).to eq "export"
+ end
end
it "raise NotImplementedError exception if abstract method not defined" do
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/library/packages/src/lib/y2packager/release_notes_fetchers/url.rb new/yast2-4.3.12/library/packages/src/lib/y2packager/release_notes_fetchers/url.rb
--- old/yast2-4.3.9/library/packages/src/lib/y2packager/release_notes_fetchers/url.rb 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/library/packages/src/lib/y2packager/release_notes_fetchers/url.rb 2020-06-30 13:01:18.000000000 +0200
@@ -256,13 +256,15 @@
return @curl_proxy_args if @curl_proxy_args
@curl_proxy_args = ""
- # proxy should be set by inst_install_inf if set via Linuxrc
+
+ # Proxy should be set by inst_install_inf if set via Linuxrc
Yast::Proxy.Read
- # Test if proxy works
return @curl_proxy_args unless Yast::Proxy.enabled
- # it is enough to test http proxy, release notes are downloaded via http
+ # Test if proxy works
+ #
+ # It is enough to test http proxy, release notes are downloaded via http
proxy_ret = Yast::Proxy.RunTestProxy(
Yast::Proxy.http,
"",
@@ -272,13 +274,15 @@
)
http_ret = proxy_ret.fetch("HTTP", {})
- if http_ret.fetch("tested", true) == true && http_ret.fetch("exit", 1) == 0
- user_pass = (Yast::Proxy.user != "") ? "#{Yast::Proxy.user}:#{Yast::Proxy.pass}" : ""
- proxy = "--proxy #{Yast::Proxy.http}"
- proxy << " --proxy-user '#{user_pass}'" unless user_pass.empty?
- end
+ proxy_ok = http_ret.fetch("tested", true) == true && http_ret.fetch("exit", 1) == 0
+
+ return @curl_proxy_args unless proxy_ok
+
+ user_pass = (Yast::Proxy.user != "") ? "#{Yast::Proxy.user}:#{Yast::Proxy.pass}" : ""
+ @curl_proxy_args = "--proxy #{Yast::Proxy.http}"
+ @curl_proxy_args << " --proxy-user '#{user_pass}'" unless user_pass.empty?
- @curl_proxy_args = proxy
+ @curl_proxy_args
end
# Release notes index for the given product
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/library/packages/src/modules/Product.rb new/yast2-4.3.12/library/packages/src/modules/Product.rb
--- old/yast2-4.3.9/library/packages/src/modules/Product.rb 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/library/packages/src/modules/Product.rb 2020-06-30 13:01:18.000000000 +0200
@@ -188,7 +188,6 @@
# Ensures that we can load data from libzypp
# @return [Boolean] false if libzypp lock cannot be obtained, otherwise true
- # (solver errors are ignored, see bnc#886588)
def load_zypp
if !PackageLock.Check
Builtins.y2error("Packager is locked, can't read product info!")
@@ -201,9 +200,6 @@
PackageSystem.EnsureSourceInit unless Stage.initial
end
- Pkg.PkgSolve(true)
-
- # ignore solver errors
true
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/library/packages/test/y2packager/release_notes_fetchers/url_test.rb new/yast2-4.3.12/library/packages/test/y2packager/release_notes_fetchers/url_test.rb
--- old/yast2-4.3.9/library/packages/test/y2packager/release_notes_fetchers/url_test.rb 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/library/packages/test/y2packager/release_notes_fetchers/url_test.rb 2020-06-30 13:01:18.000000000 +0200
@@ -226,36 +226,57 @@
allow(Yast::Proxy).to receive(:http).twice.and_return("http://proxy.example.com")
allow(Yast::Proxy).to receive(:user).and_return(proxy_user)
allow(Yast::Proxy).to receive(:pass).and_return(proxy_pass)
- test = {
- "HTTP" => {
- "tested" => true,
- "exit" => 0
- }
- }
- allow(Yast::Proxy).to receive(:RunTestProxy).and_return(test)
+ allow(Yast::Proxy).to receive(:RunTestProxy).and_return(test_result)
end
- context "and no user or password are specified" do
- let(:proxy_user) { "" }
- let(:proxy_pass) { "" }
+ let(:proxy_user) { "" }
+ let(:proxy_pass) { "" }
- it "uses an unauthenticated proxy" do
- expect(Yast::SCR).to receive(:Execute) do |_path, cmd|
- expect(cmd).to include("--proxy http://proxy.example.com")
- expect(cmd).to_not include("--proxy-user")
+ context "and the proxy is working" do
+ let(:test_result) do
+ {
+ "HTTP" => {
+ "tested" => true,
+ "exit" => 0
+ }
+ }
+ end
+
+ context "and no user or password are specified" do
+ let(:proxy_user) { "" }
+ let(:proxy_pass) { "" }
+
+ it "uses an unauthenticated proxy" do
+ expect(Yast::SCR).to receive(:Execute) do |_path, cmd|
+ expect(cmd).to include("--proxy http://proxy.example.com")
+ expect(cmd).to_not include("--proxy-user")
+ end
+
+ fetcher.release_notes(prefs)
end
+ end
- fetcher.release_notes(prefs)
+ context "and user and password are specified" do
+ let(:proxy_user) { "baggins" }
+ let(:proxy_pass) { "thief" }
+
+ it "uses an authenticated proxy" do
+ expect(Yast::SCR).to receive(:Execute) do |_path, cmd|
+ expect(cmd).to include("--proxy http://proxy.example.com --proxy-user 'baggins:thief'")
+ end
+
+ fetcher.release_notes(prefs)
+ end
end
end
- context "and user and password are specified" do
- let(:proxy_user) { "baggins" }
- let(:proxy_pass) { "thief" }
+ context "when the proxy is not working" do
+ let(:test_result) { {} }
- it "uses an authenticated proxy" do
+ it "does not use any specific proxy" do
expect(Yast::SCR).to receive(:Execute) do |_path, cmd|
- expect(cmd).to include("--proxy http://proxy.example.com --proxy-user 'baggins:thief'")
+ expect(cmd).to_not match(/--proxy/)
+ expect(cmd).to_not match(/--proxy-user/)
end
fetcher.release_notes(prefs)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/package/yast2.changes new/yast2-4.3.12/package/yast2.changes
--- old/yast2-4.3.9/package/yast2.changes 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/package/yast2.changes 2020-06-30 13:01:18.000000000 +0200
@@ -1,4 +1,24 @@
-------------------------------------------------------------------
+Mon Jun 29 15:26:44 UTC 2020 - schubi(a)suse.de
+- Products: Do not solve dependencies while checking libzypp
+ connection (bsc#1170322).
+- 4.3.12
+
+-------------------------------------------------------------------
+Mon Jun 29 14:26:44 UTC 2020 - José Iván López González <jlopez(a)suse.com>
+
+- Avoid failure when downloading release notes from an inoperative
+ proxy (bsc#1173447).
+- 4.3.11
+
+-------------------------------------------------------------------
+Fri Jun 26 15:00:17 UTC 2020 - Imobach Gonzalez Sosa <igonzalezsosa(a)suse.com>
+
+- AutoClient#export method can receive a hash as an argument
+ (bsc#1171356).
+- 4.3.10
+
+-------------------------------------------------------------------
Sun Jun 21 20:01:42 UTC 2020 - Knut Anderssen <kandersen(a)suse.com>
- Add a method to change the selection of the network backend to be
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-4.3.9/package/yast2.spec new/yast2-4.3.12/package/yast2.spec
--- old/yast2-4.3.9/package/yast2.spec 2020-06-22 09:07:29.000000000 +0200
+++ new/yast2-4.3.12/package/yast2.spec 2020-06-30 13:01:18.000000000 +0200
@@ -17,7 +17,7 @@
Name: yast2
-Version: 4.3.9
+Version: 4.3.12
Release: 0
Summary: YaST2 Main Package
License: GPL-2.0-only
1
0
Hello community,
here is the log from the commit of package yast2-storage-ng for openSUSE:Factory checked in at 2020-07-01 14:25:48
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-storage-ng (Old)
and /work/SRC/openSUSE:Factory/.yast2-storage-ng.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-storage-ng"
Wed Jul 1 14:25:48 2020 rev:85 rq:817828 version:4.3.10
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-storage-ng/yast2-storage-ng.changes 2020-06-27 23:22:18.549768798 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-storage-ng.new.3060/yast2-storage-ng.changes 2020-07-01 14:25:54.658621686 +0200
@@ -1,0 +2,6 @@
+Tue Jun 30 09:18:15 CEST 2020 - aschnell(a)suse.com
+
+- install nvme-cli if NVMe devices are present (bsc#1172866)
+- 4.3.10
+
+-------------------------------------------------------------------
Old:
----
yast2-storage-ng-4.3.9.tar.bz2
New:
----
yast2-storage-ng-4.3.10.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-storage-ng.spec ++++++
--- /var/tmp/diff_new_pack.617YoL/_old 2020-07-01 14:25:56.934628745 +0200
+++ /var/tmp/diff_new_pack.617YoL/_new 2020-07-01 14:25:56.938628757 +0200
@@ -17,7 +17,7 @@
Name: yast2-storage-ng
-Version: 4.3.9
+Version: 4.3.10
Release: 0
Summary: YaST2 - Storage Configuration
License: GPL-2.0-only OR GPL-3.0-only
@@ -26,8 +26,8 @@
Source: %{name}-%{version}.tar.bz2
-# RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS
-BuildRequires: libstorage-ng-ruby >= 4.3.21
+# UF_PMEM and UF_NVME
+BuildRequires: libstorage-ng-ruby >= 4.3.30
BuildRequires: update-desktop-files
# AutoYaST issue handling
BuildRequires: yast2 >= 4.3.2
@@ -48,8 +48,8 @@
# findutils for xargs
Requires: findutils
-# RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS
-Requires: libstorage-ng-ruby >= 4.3.21
+# UF_PMEM and UF_NVME
+Requires: libstorage-ng-ruby >= 4.3.30
# Updated Xen detection
Requires: yast2 >= 4.3.6
# Y2Packager::Repository
++++++ yast2-storage-ng-4.3.9.tar.bz2 -> yast2-storage-ng-4.3.10.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-storage-ng-4.3.9/package/yast2-storage-ng.changes new/yast2-storage-ng-4.3.10/package/yast2-storage-ng.changes
--- old/yast2-storage-ng-4.3.9/package/yast2-storage-ng.changes 2020-06-26 16:06:40.000000000 +0200
+++ new/yast2-storage-ng-4.3.10/package/yast2-storage-ng.changes 2020-06-30 11:25:32.000000000 +0200
@@ -1,4 +1,10 @@
-------------------------------------------------------------------
+Tue Jun 30 09:18:15 CEST 2020 - aschnell(a)suse.com
+
+- install nvme-cli if NVMe devices are present (bsc#1172866)
+- 4.3.10
+
+-------------------------------------------------------------------
Fri Jun 26 14:02:34 UTC 2020 - Ancor Gonzalez Sosa <ancor(a)suse.com>
- Ensure consistent removal of LVM snapshots when the origin LV
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-storage-ng-4.3.9/package/yast2-storage-ng.spec new/yast2-storage-ng-4.3.10/package/yast2-storage-ng.spec
--- old/yast2-storage-ng-4.3.9/package/yast2-storage-ng.spec 2020-06-26 16:06:40.000000000 +0200
+++ new/yast2-storage-ng-4.3.10/package/yast2-storage-ng.spec 2020-06-30 11:25:32.000000000 +0200
@@ -16,7 +16,7 @@
#
Name: yast2-storage-ng
-Version: 4.3.9
+Version: 4.3.10
Release: 0
Summary: YaST2 - Storage Configuration
License: GPL-2.0-only OR GPL-3.0-only
@@ -25,8 +25,8 @@
Source: %{name}-%{version}.tar.bz2
-# RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS
-BuildRequires: libstorage-ng-ruby >= 4.3.21
+# UF_PMEM and UF_NVME
+BuildRequires: libstorage-ng-ruby >= 4.3.30
BuildRequires: update-desktop-files
# AutoYaST issue handling
BuildRequires: yast2 >= 4.3.2
@@ -47,8 +47,8 @@
# findutils for xargs
Requires: findutils
-# RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS
-Requires: libstorage-ng-ruby >= 4.3.21
+# UF_PMEM and UF_NVME
+Requires: libstorage-ng-ruby >= 4.3.30
# Updated Xen detection
Requires: yast2 >= 4.3.6
# Y2Packager::Repository
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-storage-ng-4.3.9/src/lib/y2storage/storage_feature.rb new/yast2-storage-ng-4.3.10/src/lib/y2storage/storage_feature.rb
--- old/yast2-storage-ng-4.3.9/src/lib/y2storage/storage_feature.rb 2020-06-26 16:06:40.000000000 +0200
+++ new/yast2-storage-ng-4.3.10/src/lib/y2storage/storage_feature.rb 2020-06-30 11:25:32.000000000 +0200
@@ -91,6 +91,8 @@
UF_FCOE: "fcoe-utils",
UF_FC: [],
UF_DASD: [],
+ UF_PMEM: [],
+ UF_NVME: "nvme-cli",
# Other
UF_QUOTA: "quota",
1
0
Hello community,
here is the log from the commit of package yast2-trans for openSUSE:Factory checked in at 2020-07-01 14:25:44
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-trans (Old)
and /work/SRC/openSUSE:Factory/.yast2-trans.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-trans"
Wed Jul 1 14:25:44 2020 rev:178 rq:817565 version:84.87.20200627.7af6bd201f
Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-trans/yast2-trans.changes 2020-06-27 23:21:51.689680489 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-trans.new.3060/yast2-trans.changes 2020-07-01 14:25:47.958600908 +0200
@@ -1,0 +2,13 @@
+Mon Jun 29 05:12:57 UTC 2020 - git(a)opensuse.org
+
+- Update to version 84.87.20200627.7af6bd201f:
+ * New POT for text domain 'storage'.
+ * New POT for text domain 'autoinst'.
+ * New POT for text domain 'country'.
+ * New POT for text domain 'control'.
+ * New POT for text domain 'installation'.
+ * New POT for text domain 'network'.
+ * New POT for text domain 'gtk'.
+ * New POT for text domain 'base'.
+
+-------------------------------------------------------------------
Old:
----
yast2-trans-84.87.20200621.6aa3ebb0e6.tar.xz
New:
----
yast2-trans-84.87.20200627.7af6bd201f.tar.xz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-trans.spec ++++++
--- /var/tmp/diff_new_pack.Md3JQY/_old 2020-07-01 14:25:49.934607036 +0200
+++ /var/tmp/diff_new_pack.Md3JQY/_new 2020-07-01 14:25:49.938607048 +0200
@@ -17,7 +17,7 @@
Name: yast2-trans
-Version: 84.87.20200621.6aa3ebb0e6
+Version: 84.87.20200627.7af6bd201f
Release: 0
Summary: YaST2 - Translation Container Package
License: GPL-2.0-or-later
++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.Md3JQY/_old 2020-07-01 14:25:50.030607334 +0200
+++ /var/tmp/diff_new_pack.Md3JQY/_new 2020-07-01 14:25:50.030607334 +0200
@@ -1,4 +1,4 @@
<servicedata>
<service name="tar_scm">
<param name="url">git://github.com/yast/yast-translations.git</param>
- <param name="changesrevision">6aa3ebb0e626a95791f489965f845168262675ba</param></service></servicedata>
\ No newline at end of file
+ <param name="changesrevision">7af6bd201ff8b8839c6bc40fc749db4041060fd2</param></service></servicedata>
\ No newline at end of file
++++++ yast2-trans-84.87.20200621.6aa3ebb0e6.tar.xz -> yast2-trans-84.87.20200627.7af6bd201f.tar.xz ++++++
/work/SRC/openSUSE:Factory/yast2-trans/yast2-trans-84.87.20200621.6aa3ebb0e6.tar.xz /work/SRC/openSUSE:Factory/.yast2-trans.new.3060/yast2-trans-84.87.20200627.7af6bd201f.tar.xz differ: char 26, line 1
1
0
Hello community,
here is the log from the commit of package steam for openSUSE:Factory:NonFree checked in at 2020-07-01 14:24:50
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory:NonFree/steam (Old)
and /work/SRC/openSUSE:Factory:NonFree/.steam.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "steam"
Wed Jul 1 14:24:50 2020 rev:24 rq:817400 version:1.0.0.64
Changes:
--------
--- /work/SRC/openSUSE:Factory:NonFree/steam/steam.changes 2020-06-15 20:26:01.433441744 +0200
+++ /work/SRC/openSUSE:Factory:NonFree/.steam.new.3060/steam.changes 2020-07-01 14:24:51.846426890 +0200
@@ -1,0 +2,29 @@
+Wed Jun 17 13:50:16 UTC 2020 - Callum Farmer <callumjfarmer13(a)gmail.com>
+
+- Update to version 1.0.0.63
+ * Update steam-devices subproject up to 2020-06-05
+ - Add HORIPAD for Nintendo Switch (thanks, @BrokenGale)
+ (Fixes: steam-for-linux#6944, steam-devices#7)
+ - Add ASTRO C40 controller (thanks, @exhumer2)
+ (Fixes: steam-devices#5)
+ - Add PowerA Nintendo Switch Controller (thanks, @blazingkin)
+ (Fixes: steam-devices#6)
+ - Add a workaround for PowerA Wireless Controller
+ (thanks, Andrey Smirnov) (Fixes: steam-devices#9; T21767)
+ * debian/steam-launcher.postinst: Notify udevd to reload its rules.
+ This means the steam-devices rules should take effect immediately,
+ instead of being deferred until after the next reboot. (T19535)
+ * bin_steam.sh: Don't overwrite steam.desktop if it's a symlink.
+ In a pre-configured distro like SteamOS, ~/Desktop/steam.desktop
+ might already be a symlink to /usr/share/applications/steam.desktop,
+ in which case overwriting it is pointless. (T21633)
+- steam-devices supplements steam
+- Update to version 1.0.0.64
+ * steam.list: Download updates via https (T21740)
+ In older versions of apt (lower than 1.6) we need to install
+ apt-transport-https to use https repositories, so do that.
+ * steam.list: Switch the suite from precise to stable
+ (Fixes: steam-for-linux#4436)
+ * steam.list: Add commented-out apt sources for the beta launcher
+
+-------------------------------------------------------------------
Old:
----
steam_1.0.0.62.tar.gz
New:
----
steam_1.0.0.64.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ steam.spec ++++++
--- /var/tmp/diff_new_pack.9masJM/_old 2020-07-01 14:24:52.678429470 +0200
+++ /var/tmp/diff_new_pack.9masJM/_new 2020-07-01 14:24:52.678429470 +0200
@@ -17,7 +17,7 @@
Name: steam
-Version: 1.0.0.62
+Version: 1.0.0.64
Release: 0
Summary: Installer for Valve's digital software distribution service
# "Limited Installation License"
@@ -32,7 +32,7 @@
# PATCH-FIX-OPENSUSE steam-path-fix.patch bnc#1025841
Patch1: steam-path-fix.patch
BuildRequires: hicolor-icon-theme
-BuildRequires: shared-mime-info
+BuildRequires: pkgconfig(shared-mime-info)
BuildRequires: update-desktop-files
BuildRequires: fdupes
BuildRequires: pkgconfig(udev)
@@ -134,6 +134,7 @@
Obsoletes: steam-vr < %{version}
Provides: steam-controller = %{version}
Provides: steam-vr = %{version}
+Supplements: steam = %{version}
Requires: steam = %{version}
%if 0%{?suse_version} >= 1330
Requires(pre): group(games)
@@ -149,9 +150,7 @@
%prep
-%setup -q -n steam-launcher
-%patch0 -p1
-%patch1 -p1
+%autosetup -n steam-launcher -p1
%build
@@ -161,7 +160,7 @@
# TODO: Patch it so it works with zypper or at least does not invoke apt-get.
rm %{buildroot}%{_bindir}/steamdeps
-rm %{buildroot}/usr/lib/steam/bin_steamdeps.py
+rm %{buildroot}%{_prefix}/lib/steam/bin_steamdeps.py
mkdir -p %{buildroot}%{_udevrulesdir}
cp subprojects/steam-devices/60-steam-input.rules %{buildroot}%{_udevrulesdir}/60-steam-input.rules
@@ -207,8 +206,8 @@
%dir %{_datadir}/appdata/
%{_datadir}/appdata/%{name}.appdata.xml
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/%{name}
-/usr/lib/steam/bin_steam.sh
-/usr/lib/steam/steam.desktop
+%{_prefix}/lib/steam/bin_steam.sh
+%{_prefix}/lib/steam/steam.desktop
%files devices
%license subprojects/steam-devices/LICENSE
++++++ steam_1.0.0.62.tar.gz -> steam_1.0.0.64.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/bin_steam.sh new/steam-launcher/bin_steam.sh
--- old/steam-launcher/bin_steam.sh 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/bin_steam.sh 2020-06-24 12:36:09.000000000 +0200
@@ -14,7 +14,7 @@
bootstrapscript="$(readlink -f "$STEAMSCRIPT")"
bootstrapdir="$(dirname "$bootstrapscript")"
-export STEAMSCRIPT_VERSION=1.0.0.61+deb1
+export STEAMSCRIPT_VERSION=1.0.0.64
# Set up domain for script localization
export TEXTDOMAIN=steam
@@ -118,18 +118,21 @@
DESKTOP_DIR="${XDG_DESKTOP_DIR:-$HOME/Desktop}"
if [ -d "$DESKTOP_DIR" ] && [ "x$bootstrapdir" = "x/usr/lib/$STEAMPACKAGE" ]; then
- cp "$bootstrapdir/$STEAMPACKAGE.desktop" "$DESKTOP_DIR"
- # Older .desktop implementations used the execute bits as
- # a marker for a .desktop being safe to treat as a shortcut
- chmod a+x "$DESKTOP_DIR/$STEAMPACKAGE.desktop"
- if command -v gio >/dev/null; then
- # Making it executable is not enough in recent
- # (Ubuntu 20.04) versions of
- # https://gitlab.gnome.org/World/ShellExtensions/desktop-icons
- gio set --type=string "$DESKTOP_DIR/$STEAMPACKAGE.desktop" metadata::trusted true || :
- # Generate an inotify event so the desktop
- # implementation reloads it
- touch "$DESKTOP_DIR/$STEAMPACKAGE.desktop"
+ # There might be a symlink in place already, in such case we do nothing
+ if [ ! -L "$DESKTOP_DIR/$STEAMPACKAGE.desktop" ]; then
+ cp "$bootstrapdir/$STEAMPACKAGE.desktop" "$DESKTOP_DIR"
+ # Older .desktop implementations used the execute bits as
+ # a marker for a .desktop being safe to treat as a shortcut
+ chmod a+x "$DESKTOP_DIR/$STEAMPACKAGE.desktop"
+ if command -v gio >/dev/null; then
+ # Making it executable is not enough in recent
+ # (Ubuntu 20.04) versions of
+ # https://gitlab.gnome.org/World/ShellExtensions/desktop-icons
+ gio set --type=string "$DESKTOP_DIR/$STEAMPACKAGE.desktop" metadata::trusted true || :
+ # Generate an inotify event so the desktop
+ # implementation reloads it
+ touch "$DESKTOP_DIR/$STEAMPACKAGE.desktop"
+ fi
fi
fi
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/bin_steamdeps.py new/steam-launcher/bin_steamdeps.py
--- old/steam-launcher/bin_steamdeps.py 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/bin_steamdeps.py 2020-06-24 12:36:09.000000000 +0200
@@ -1,10 +1,10 @@
#!/usr/bin/env python3
"""
- This script handles installing system dependencies for games using the
- Steam runtime. It is intended to be customized by other distributions
- to "do the right thing"
+ This script handles installing system dependencies for games using the
+ Steam runtime. It is intended to be customized by other distributions
+ to "do the right thing"
- Usage: steamdeps dependencies.txt
+ Usage: steamdeps dependencies.txt
"""
import os
@@ -14,232 +14,256 @@
import sys
import tempfile
+try:
+ import apt
+except ImportError:
+ sys.stderr.write("Couldn't import apt, please install python3-apt or "
+ "update steamdeps for your distribution.\n")
+ sys.exit(3)
+
# This is the set of supported Steam runtime environments
-SUPPORTED_STEAM_RUNTIME = [ '1' ]
+SUPPORTED_STEAM_RUNTIME = ['1']
# This is the set of supported dependency formats
-SUPPORTED_STEAM_DEPENDENCY_VERSION = [ '1' ]
+SUPPORTED_STEAM_DEPENDENCY_VERSION = ['1']
-###
+_arch = None
+
+
+#
# Get the current package architecture
# This may be different than the actual architecture for the case of i386
# chroot environments on amd64 hosts.
-_arch = None
-def getArch():
- """
- Get the current architecture
- """
- global _arch
-
- if ( _arch is None ):
- _arch = subprocess.check_output(['dpkg', '--print-architecture']).decode("utf-8").strip()
- return _arch
+#
+def get_arch():
+ """
+ Get the current architecture
+ """
+ global _arch
+
+ if _arch is None:
+ _arch = subprocess.check_output(
+ ['dpkg', '--print-architecture']).decode("utf-8").strip()
+ return _arch
###
-def getFullPackageName( name ):
- """
- Get the full name of a package, qualified by architecture
- """
- if ( name.find(":") < 0 ):
- return name + ":" + getArch()
- else:
- return name
+def get_full_package_name(name):
+ """
+ Get the full name of a package, qualified by architecture
+ """
+ if name.find(":") < 0:
+ return name + ":" + get_arch()
+ else:
+ return name
#
-# Check to see if another package Provides this package
# N.B. Version checks are not supported on virtual packages
#
-def isProvided(pkgname):
- try:
- process = subprocess.Popen( ['apt-cache', 'showpkg', pkgname], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
- pattern = re.compile( r'^Reverse Provides\:')
- providers = {}
- for line in process.stdout:
- if re.match(pattern,line):
- for provider in process.stdout:
- (name, version) = provider.split()
- providers[name] = version
- for provider in providers.keys():
- if hasPackage(provider):
- return True
- return False
- except:
- return False
- return False
+def is_provided(pkgname):
+ """
+ Check to see if another package Provides this package
+ """
+ cache = apt.Cache()
+ pkgs = cache.get_providing_packages(pkgname)
+ for pkg in pkgs:
+ if pkg.is_installed:
+ return True
+ return False
###
class Package:
- """
- Package definition class
- """
- def __init__(self, name, versionConditions):
- self.name = name
- self.versionConditions = versionConditions
- self.installed = None
-
- def setInstalled(self, version):
- self.installed = version
-
-
- def isAvailable(self):
- if ( self.installed is None ):
- # check to see if another package is providing this virtual package
- return isProvided(self.name)
-
- for (op, version) in self.versionConditions:
- if ( subprocess.call( ['dpkg', '--compare-versions', self.installed, op, version] ) != 0 ):
- return False
-
- return True
-
- def __str__(self):
- text = self.name
- for (op, version) in self.versionConditions:
- text += " (%s %s)" % (op, version)
- return text
-
-
-###
-def hasPackage( package ):
- process = subprocess.Popen( ['dpkg', '-l', package], stdout=subprocess.PIPE, stderr=subprocess.PIPE )
- installed_pattern = re.compile( r"^\Si\s+([^\s]+)\s+([^\s]+)" )
- for line in process.stdout:
- line = line.decode( "utf-8" ).strip()
- match = re.match( installed_pattern, line )
- if ( match is None ):
- continue
-
- return True
- return False
+ """
+ Package definition class
+ """
+
+ def __init__(self, name, version_conditions):
+ self.name = name
+ self.version_conditions = version_conditions
+ self.installed = None
+
+ def set_installed(self, version):
+ self.installed = version
+
+ def is_available(self):
+ if self.installed is None:
+ # check to see if another package is providing this virtual package
+ return is_provided(self.name)
+
+ for (op, version) in self.version_conditions:
+ if subprocess.call(['dpkg', '--compare-versions', self.installed,
+ op, version]) != 0:
+ return False
+
+ return True
+
+ def __str__(self):
+ text = self.name
+ for (op, version) in self.version_conditions:
+ text += " (%s %s)" % (op, version)
+ return text
def is_glvnd():
- try:
- with subprocess.Popen(
- ['apt-cache', 'pkgnames', 'libgl1'],
- stdout=subprocess.PIPE,
- ) as process:
- for line in process.stdout:
- line = line.decode('utf-8').strip()
-
- if line == 'libgl1':
- return True
- return False
- except Exception:
- return False
-
-
-def remapPackage( name ):
- if name in (
- 'python-apt',
- ):
- # Steam claims it needs python-apt, but it doesn't really
- return None
-
- # Ubuntu 12.04.2, 12.04.3, and 12.04.4 introduce new X stacks which require
- # different sets of incompatible glx packages depending on which X
- # is currently installed.
-
- for lts in ('quantal', 'raring', 'saucy', 'trusty'):
- if hasPackage('xserver-xorg-core-lts-' + lts):
- if name in (
- 'libgl1-mesa-glx',
- 'libgl1-mesa-dri',
- ):
- return name + '-lts-' + lts
-
- if name == 'libgl1-mesa-glx':
- if is_glvnd():
- return 'libgl1'
+ try:
+ with subprocess.Popen(['apt-cache', 'pkgnames', 'libgl1'],
+ stdout=subprocess.PIPE,) as process:
+ for line in process.stdout:
+ line = line.decode('utf-8').strip()
+
+ if line == 'libgl1':
+ return True
+ return False
+ except (OSError, FileNotFoundError):
+ return False
+
+
+def remap_package(name):
+ if name in (
+ 'python-apt',
+ ):
+ # Steam claims it needs python-apt, but it doesn't really
+ return None
+
+ # Ubuntu 12.04.2, 12.04.3, and 12.04.4 introduce new X stacks which require
+ # different sets of incompatible glx packages depending on which X
+ # is currently installed.
+
+ cache = apt.Cache()
+ for lts in ('quantal', 'raring', 'saucy', 'trusty', 'xenial'):
+ xserver = 'xserver-xorg-core-lts-' + lts
+ if xserver in cache and cache[xserver].is_installed:
+ if name in (
+ 'libgl1-mesa-glx',
+ 'libgl1-mesa-dri',
+ ):
+ return name + '-lts-' + lts
+
+ if name == 'libgl1-mesa-glx':
+ if is_glvnd():
+ return 'libgl1'
- return name
+ return name
###
-def createPackage( description ):
- """
- Create a package object based on a description.
- This can return None if the package isn't meaningful on this platform.
- """
- # Look for architecture conditions, e.g. foo [i386]
- match = re.match( r"(.*) \[([^\]]+)\]", description )
- if match is not None:
- description = match.group(1).strip()
- condition = match.group(2)
- if ( condition[0] == '!' ):
- if ( getArch() == condition[1:] ):
- return None
- else:
- if ( getArch() != condition ):
- return None
-
- # Look for version requirements, e.g. foo (>= 1.0)
- versionConditions = []
- while True:
- match = re.search( r"\s*\(\s*([<>=]+)\s*([\w\-\.:]+)\s*\)\s*", description )
- if ( match is None ):
- break
-
- versionConditions.append( ( match.group(1), match.group(2) ) )
- description = description[:match.start()] + description[match.end():]
-
- description = description.strip()
-
- if ':' in description:
- name, multiarch = description.rsplit(':', 1)
- else:
- name = description
- multiarch = None
-
- name = remapPackage(name)
-
- if name is None:
- return None
- elif multiarch is not None:
- description = name + ':' + multiarch
+def create_package(description):
+ """
+ Create a package object based on a description.
+ This can return None if the package isn't meaningful on this platform.
+ """
+ # Look for architecture conditions, e.g. foo [i386]
+ match = re.match(r"(.*) \[([^\]]+)\]", description)
+ if match is not None:
+ description = match.group(1).strip()
+ condition = match.group(2)
+ if condition[0] == '!':
+ if get_arch() == condition[1:]:
+ return None
+ else:
+ if get_arch() != condition:
+ return None
+
+ # Look for version requirements, e.g. foo (>= 1.0)
+ version_conditions = []
+ while True:
+ match = re.search(r"\s*\(\s*([<>=]+)\s*([\w\-.:]+)\s*\)\s*",
+ description)
+ if match is None:
+ break
+
+ version_conditions.append((match.group(1), match.group(2)))
+ description = description[:match.start()] + description[match.end():]
+
+ description = description.strip()
+
+ if ':' in description:
+ name, multiarch = description.rsplit(':', 1)
+ else:
+ name = description
+ multiarch = None
+
+ name = remap_package(name)
+
+ if name is None:
+ return None
+ elif multiarch is not None:
+ description = name + ':' + multiarch
- return Package( description, versionConditions )
-
+ return Package(description, version_conditions)
###
-def getTerminalCommandLine( title ):
- """
- Function to find a useful terminal like xterm or compatible
- """
- if ( "DISPLAY" in os.environ ):
- programs = [
- ( "gnome-terminal", ["gnome-terminal", "--disable-factory", "-t", title, "-e"] ),
- ( "konsole", ["konsole", "--nofork", "-p", "tabtitle="+title, "-e"] ),
- ( "xterm", ["xterm", "-bg", "#383635", "-fg", "#d1cfcd", "-T", title, "-e"] ),
- ( "x-terminal-emulator", ["x-terminal-emulator", "-T", title, "-e"] ),
- ]
- for (program, commandLine) in programs:
- if ( subprocess.call( ['which', program], stdout=subprocess.PIPE ) == 0 ):
- return commandLine
+def get_terminal_command_line(title):
+ """
+ Function to find a useful terminal like xterm or compatible
+ """
+ if "DISPLAY" in os.environ:
+ gnome_wait_option = None
+ try:
+ # Use the new '--wait' option if available
+ terminal_out = subprocess.check_output(
+ ["gnome-terminal", "--help-terminal-options"]).decode("utf-8")
+ if "--wait" in terminal_out:
+ gnome_wait_option = "--wait"
+ else:
+ # If the old '--disable-factory' is supported we use it
+ terminal_out = subprocess.check_output(
+ ["gnome-terminal", "--help"]).decode("utf-8")
+ if "--disable-factory" in terminal_out:
+ gnome_wait_option = "--disable-factory"
+
+ if gnome_wait_option is not None:
+ # If 'gnome-terminal' with the right options is available, we
+ # just use it
+ return ["gnome-terminal", gnome_wait_option, "-t", title, "--"]
+ except FileNotFoundError:
+ pass
+
+ programs = [
+ ("konsole",
+ ["konsole", "--nofork", "-p", "tabtitle=" + title, "-e"]),
+ ("xterm",
+ ["xterm", "-bg", "#383635", "-fg", "#d1cfcd", "-T", title, "-e"]),
+ ("x-terminal-emulator",
+ ["x-terminal-emulator", "-T", title, "-e"]),
+ # If we reach this point either 'gnome-terminal' is not available
+ # or the current version is too old for the new '--wait' option.
+ # Anyway we can't know for sure if '--disable-factory' option
+ # is supported until we try it because, for example,
+ # on Ubuntu 16.04 '--disable-factory' is available but it doesn't
+ # show up with '--help'. Leave this 'gnome-terminal' test as the
+ # last resort because it's highly likely to fail.
+ ("gnome-terminal",
+ ["gnome-terminal", "--disable-factory", "-t", title, "--"]),
+ ]
+ for (program, commandLine) in programs:
+ if subprocess.call(['which', program],
+ stdout=subprocess.PIPE) == 0:
+ return commandLine
- # Fallback if no GUI terminal program is available
- return ['/bin/sh']
+ # Fallback if no GUI terminal program is available
+ return ['/bin/sh']
###
-def updatePackages( packages ):
- """
- Function to install or update package dependencies
- Ideally we would call some sort of system UI that users were familiar with to do this, but nothing that exists yet does what we need.
- """
-
- packageList = " ".join( [ package.name for package in packages ] )
-
- # Create a temporary file to hold the installation completion status
- (fd, statusFile) = tempfile.mkstemp()
- os.close( fd )
-
- # Create a script to run, in a secure way
- (fd, scriptFile) = tempfile.mkstemp()
- script = """#!/bin/sh
+def update_packages(packages):
+ """
+ Function to install or update package dependencies
+ Ideally we would call some sort of system UI that users were familiar with
+ to do this, but nothing that exists yet does what we need.
+ """
+
+ package_list = " ".join([package.name for package in packages])
+
+ # Create a temporary file to hold the installation completion status
+ (fd, status_file) = tempfile.mkstemp()
+ os.close(fd)
+
+ # Create a script to run, in a secure way
+ (fd, script_file) = tempfile.mkstemp()
+ script = """#!/bin/sh
check_sudo()
{
# If your host file is misconfigured in certain circumstances this
@@ -251,7 +275,8 @@
cat <<__EOF__
sudo timed out, your hostname may be missing from /etc/hosts.
-See https://support.steampowered.com/kb_article.php?ref=7493-ADXN-9620 for more details.
+See https://support.steampowered.com/kb_article.php?ref=7493-ADXN-9620
+for more details.
__EOF__
return 1
else
@@ -260,13 +285,14 @@
}
cat <<__EOF__
-Steam needs to install these additional packages:
- %s
+Steam needs to install these additional packages:
+ %s
__EOF__
check_sudo
# Check to make sure 64-bit systems can get 32-bit packages
-if [ "$(dpkg --print-architecture)" = "amd64" ] && ! dpkg --print-foreign-architectures | grep i386 >/dev/null; then
+if [ "$(dpkg --print-architecture)" = "amd64" ] && \
+ ! dpkg --print-foreign-architectures | grep i386 >/dev/null; then
sudo dpkg --add-architecture i386
fi
@@ -279,178 +305,190 @@
echo $? >%s
echo -n "Press return to continue: "
read line
-""" % ( ", ".join( [ package.name for package in packages ] ), packageList, statusFile )
- os.write( fd, script.encode("utf-8") )
- os.close( fd )
- os.chmod( scriptFile, (stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR) )
-
- try:
- subprocess.call( getTerminalCommandLine( "Package Install" ) + [scriptFile] )
- except KeyboardInterrupt:
- pass
- os.unlink( scriptFile )
-
- # Read the status out of the file, since if we ran the script in a
- # terminal the process status will be whether the terminal started
- try:
- status = int( open( statusFile ).read() )
- except ValueError:
- # The status wasn't written to the file
- status = 255
+""" % (", ".join([package.name for package in packages]), package_list,
+ status_file)
+ os.write(fd, script.encode("utf-8"))
+ os.close(fd)
+ os.chmod(script_file, (stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR))
+
+ try:
+ subprocess.call(
+ get_terminal_command_line("Package Install") + [script_file])
+ except KeyboardInterrupt:
+ pass
+ os.unlink(script_file)
+
+ # Read the status out of the file, since if we ran the script in a
+ # terminal the process status will be whether the terminal started
+ try:
+ status = int(open(status_file).read())
+ except ValueError:
+ # The status wasn't written to the file
+ status = 255
- os.unlink( statusFile )
+ os.unlink(status_file)
- return status
+ return status
###
-def checkConfig( config ):
- if ( "STEAM_RUNTIME" not in config ):
- sys.stderr.write( "Missing STEAM_RUNTIME definition in %s\n" % sys.argv[1] )
- return False
-
- if ( config["STEAM_RUNTIME"] not in SUPPORTED_STEAM_RUNTIME ):
- sys.stderr.write( "Unsupported Steam runtime: %s\n" % config["STEAM_RUNTIME"] )
- return False
-
- if ( "STEAM_DEPENDENCY_VERSION" not in config ):
- sys.stderr.write( "Missing STEAM_DEPENDENCY_VERSION definition in %s\n" % sys.argv[1] )
- return False
-
- if ( config["STEAM_DEPENDENCY_VERSION"] not in SUPPORTED_STEAM_DEPENDENCY_VERSION ):
- sys.stderr.write( "Unsupported dependency version: %s\n" % config["STEAM_DEPENDENCY_VERSION"] )
- return False
-
- # Make sure we can use dpkg on this system.
- try:
- subprocess.call( ['dpkg', '--version'], stdout=subprocess.PIPE )
- except:
- sys.stderr.write( "Couldn't find dpkg, please update steamdeps for your distribution.\n" )
- return False
+def check_config(config):
+ if "STEAM_RUNTIME" not in config:
+ sys.stderr.write(
+ "Missing STEAM_RUNTIME definition in %s\n" % sys.argv[1])
+ return False
+
+ if config["STEAM_RUNTIME"] not in SUPPORTED_STEAM_RUNTIME:
+ sys.stderr.write(
+ "Unsupported Steam runtime: %s\n" % config["STEAM_RUNTIME"])
+ return False
+
+ if "STEAM_DEPENDENCY_VERSION" not in config:
+ sys.stderr.write(
+ "Missing STEAM_DEPENDENCY_VERSION definition in %s\n" % sys.argv[
+ 1])
+ return False
+
+ if config["STEAM_DEPENDENCY_VERSION"]\
+ not in SUPPORTED_STEAM_DEPENDENCY_VERSION:
+ sys.stderr.write("Unsupported dependency version: %s\n" % config[
+ "STEAM_DEPENDENCY_VERSION"])
+ return False
+
+ # Make sure we can use dpkg on this system.
+ try:
+ subprocess.call(['dpkg', '--version'], stdout=subprocess.PIPE)
+ except FileNotFoundError:
+ sys.stderr.write("Couldn't find dpkg, please update steamdeps for "
+ "your distribution.\n")
+ return False
- return True
+ return True
###
def main():
- config = {}
+ config = {}
- # Check the command line arguments
- if ( len(sys.argv) < 2 ):
- sys.stderr.write( "Usage: %s dependencies.txt\n" % sys.argv[0] )
- return 1
-
- # Make sure we can open the file
- try:
- fp = open(sys.argv[1])
- except Exception as e:
- sys.stderr.write( "Couldn't open file: %s\n" % (e) )
- return 2
-
- # Look for configuration variables
- config_pattern = re.compile( r"(\w+)\s*=\s*(\w+)" )
- for line in fp:
- line = line.strip()
- if ( line == "" or line[0] == '#' ):
- continue
-
- match = re.match(config_pattern, line)
- if ( match is not None ):
- config[match.group(1)] = match.group(2)
-
- # Check to make sure we have a valid config
- if ( not checkConfig( config ) ):
- return 3
-
- # Seek back to the beginning of the file
- fp.seek(0)
-
- # Load the package dependency information
- packages = {}
- dependencies = []
- lineNumber = 0
- for line in fp:
- ++lineNumber
- line = line.strip()
- if ( line == "" or line[0] == '#' ):
- continue
-
- match = re.match( config_pattern, line )
- if ( match is not None ):
- continue
-
- row = []
- for section in line.split( "|" ):
- package = createPackage( section )
- if ( package is None ):
- continue
-
- packages[ package.name ] = package
- row.append( package )
-
- dependencies.append( row )
-
- if getArch() == 'amd64':
- for synthetic in (
- 'libc6',
- 'libgl1-mesa-dri',
- 'libgl1-mesa-glx',
- ):
- package = createPackage(synthetic + ':amd64')
- if package is not None:
- packages[package.name] = package
- dependencies.append([package])
-
- # Print package dependency information for debug
- """
- for row in dependencies:
- print " | ".join( [ str(package) for package in row ] )
- """
-
- # Get the installed package versions
- # Make sure COLUMNS isn't set, or dpkg will truncate its output
- if ( "COLUMNS" in os.environ ):
- del os.environ[ "COLUMNS" ]
-
- process = subprocess.Popen( ['dpkg', '-l'] + list( packages.keys() ), stdout=subprocess.PIPE, stderr=subprocess.PIPE )
- installed_pattern = re.compile( r"^\Si\s+([^\s]+)\s+([^\s]+)" )
- for line in process.stdout:
- line = line.decode( "utf-8" ).strip()
- match = re.match( installed_pattern, line )
- if ( match is None ):
- continue
-
- name = match.group(1)
- if ( name not in packages ):
- name = getFullPackageName( name )
- packages[ name ].setInstalled( match.group(2) )
-
- # See which ones need to be installed
- needed = []
- for row in dependencies:
- if ( len(row) == 0 ):
- continue
-
- satisfied = False
- for dep in row:
- if ( dep.isAvailable() ):
- satisfied = True
- break
- if ( not satisfied ):
- needed.append( row[0] )
-
- # If we have anything to install, do it!
- if ( len(needed) > 0 ):
- for package in needed:
- if package.installed:
- print("Package %s is installed with version '%s' but doesn't match requirements: %s" % (package.name, package.installed, package), file=sys.stderr)
- else:
- print("Package %s needs to be installed" % package.name, file=sys.stderr)
-
- return updatePackages( needed )
- else:
- return 0
+ # Check the command line arguments
+ if len(sys.argv) < 2:
+ sys.stderr.write("Usage: %s dependencies.txt\n" % sys.argv[0])
+ return 1
+
+ # Make sure we can open the file
+ try:
+ fp = open(sys.argv[1])
+ except Exception as e:
+ sys.stderr.write("Couldn't open file: %s\n" % e)
+ return 2
+
+ # Look for configuration variables
+ config_pattern = re.compile(r"(\w+)\s*=\s*(\w+)")
+ for line in fp:
+ line = line.strip()
+ if line == "" or line[0] == '#':
+ continue
+
+ match = re.match(config_pattern, line)
+ if match is not None:
+ config[match.group(1)] = match.group(2)
+
+ # Check to make sure we have a valid config
+ if not check_config(config):
+ return 3
+
+ # Seek back to the beginning of the file
+ fp.seek(0)
+
+ # Load the package dependency information
+ packages = {}
+ dependencies = []
+ for line in fp:
+ line = line.strip()
+ if line == "" or line[0] == '#':
+ continue
+
+ match = re.match(config_pattern, line)
+ if match is not None:
+ continue
+
+ row = []
+ for section in line.split("|"):
+ package = create_package(section)
+ if package is None:
+ continue
+
+ packages[package.name] = package
+ row.append(package)
+
+ dependencies.append(row)
+
+ if get_arch() == 'amd64':
+ for synthetic in (
+ 'libc6',
+ 'libgl1-mesa-dri',
+ 'libgl1-mesa-glx',
+ ):
+ package = create_package(synthetic + ':amd64')
+ if package is not None:
+ packages[package.name] = package
+ dependencies.append([package])
+
+ # Print package dependency information for debug
+ """
+ for row in dependencies:
+ print " | ".join( [ str(package) for package in row ] )
+ """
+
+ # Get the installed package versions
+ # Make sure COLUMNS isn't set, or dpkg will truncate its output
+ if "COLUMNS" in os.environ:
+ del os.environ["COLUMNS"]
+
+ process = subprocess.Popen(['dpkg', '-l'] + list(packages.keys()),
+ stdout=subprocess.PIPE, stderr=subprocess.PIPE)
+ installed_pattern = re.compile(r"^\Si\s+([^\s]+)\s+([^\s]+)")
+ for line in process.stdout:
+ line = line.decode("utf-8").strip()
+ match = re.match(installed_pattern, line)
+ if match is None:
+ continue
+
+ name = match.group(1)
+ if name not in packages:
+ name = get_full_package_name(name)
+ packages[name].set_installed(match.group(2))
+
+ # See which ones need to be installed
+ needed = []
+ for row in dependencies:
+ if len(row) == 0:
+ continue
+
+ satisfied = False
+ for dep in row:
+ if dep.is_available():
+ satisfied = True
+ break
+ if not satisfied:
+ needed.append(row[0])
+
+ # If we have anything to install, do it!
+ if len(needed) > 0:
+ for package in needed:
+ if package.installed:
+ print("Package %s is installed with version '%s' but doesn't "
+ "match requirements: %s" % (
+ package.name, package.installed, package),
+ file=sys.stderr)
+ else:
+ print("Package %s needs to be installed" % package.name,
+ file=sys.stderr)
+
+ return update_packages(needed)
+ else:
+ return 0
if __name__ == "__main__":
- sys.exit(main())
+ sys.exit(main())
Binary files old/steam-launcher/bootstraplinux_ubuntu12_32.tar.xz and new/steam-launcher/bootstraplinux_ubuntu12_32.tar.xz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/client-versions.json new/steam-launcher/client-versions.json
--- old/steam-launcher/client-versions.json 2020-03-19 18:14:14.000000000 +0100
+++ new/steam-launcher/client-versions.json 2020-06-24 12:36:49.000000000 +0200
@@ -1,4 +1,4 @@
{
- "client_version": "1581460722",
- "runtime_version": "0.20200204.0"
+ "client_version": "1591251555",
+ "runtime_version": "0.20200505.0"
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/debian/changelog new/steam-launcher/debian/changelog
--- old/steam-launcher/debian/changelog 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/debian/changelog 2020-06-24 12:36:09.000000000 +0200
@@ -1,3 +1,69 @@
+steam (1:1.0.0.64) beta; urgency=medium
+
+ [ Simon McVittie ]
+ * steamdeps: Recognise xenial as a LTS HWE stack.
+ Ubuntu 14.04.6 LTS comes with a backported Ubuntu 16.04.x graphics stack,
+ so we need to install libgl1-mesa-glx-lts-xenial and other xenial-derived
+ packages instead of the original Ubuntu 14.04.0 versions. (T21844)
+ * Remove Recommends: jockey-common.
+ According to steam-for-linux#6634, this was the "Additional Drivers"
+ module in older Ubuntu, which is no longer present in any supported
+ Ubuntu release. Thanks to @BryanQuigley
+
+ [ Ludovico de Nittis ]
+ * steam.list: Download updates via https (T21740)
+ In older versions of apt (lower than 1.6) we need to install
+ apt-transport-https to use https repositories, so do that.
+ * steam.list: Switch the suite from precise to stable
+ (Fixes: steam-for-linux#4436)
+ * steam.list: Add commented-out apt sources for the beta launcher
+ * bin_steamdeps: use python-apt for "is_provided" check.
+ `apt-cache showpkg` output was intended to be human readable.
+ In the apt version shipped with Ubuntu 20.04 they added additional
+ information to the "Reverse Provides" field, and that could break our
+ parsing.
+ Instead, using python-apt, is safer and we will be able to avoid these
+ kind of problems in the future.
+ (T21880)
+ * bin_steamdeps: use --wait option for gnome-terminal if it is available.
+ The --disable-factory option is no longer available upstream and in
+ Debian, although Ubuntu patches it back in. (T22095)
+ * bin_steamdeps: remove deprecated '-e' option in gnome-terminal
+
+ -- Simon McVittie <smcv(a)collabora.com> Wed, 24 Jun 2020 11:21:03 +0100
+
+steam (1:1.0.0.63) beta; urgency=medium
+
+ [ Ludovico de Nittis ]
+ * debian/steam-launcher.postinst: Notify udevd to reload its rules.
+ This means the steam-devices rules should take effect immediately,
+ instead of being deferred until after the next reboot. (T19535)
+ * bin_steamdeps.py: Remove unused, misleading lineNumber variable
+ * bin_steamdeps.py: Conform to PEP-8
+
+ [ Arnaud Rebillout ]
+ * bin_steam.sh: Don't overwrite steam.desktop if it's a symlink.
+ In a pre-configured distro like SteamOS, ~/Desktop/steam.desktop
+ might already be a symlink to /usr/share/applications/steam.desktop,
+ in which case overwriting it is pointless. (T21633)
+
+ [ Simon McVittie ]
+ * Update steam-devices subproject up to 2020-06-05
+ - Add HORIPAD for Nintendo Switch (thanks, @BrokenGale)
+ (Fixes: steam-for-linux#6944, steam-devices#7)
+ - Add ASTRO C40 controller (thanks, @exhumer2)
+ (Fixes: steam-devices#5)
+ - Add PowerA Nintendo Switch Controller (thanks, @blazingkin)
+ (Fixes: steam-devices#6)
+ - Add a workaround for PowerA Wireless Controller
+ (thanks, Andrey Smirnov) (Fixes: steam-devices#9; T21767)
+ * Update python-vdf subproject to version 3.3
+ * Bootstrap using updated Steam client:
+ - Client timestamp 1591251555 (2020-06-04)
+ - Steam Runtime version 0.20200505.0
+
+ -- Simon McVittie <smcv(a)collabora.com> Tue, 09 Jun 2020 11:32:58 +0100
+
steam (1:1.0.0.62) beta; urgency=medium
* build: Adapt for newer Steam Runtime builds.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/debian/control new/steam-launcher/debian/control
--- old/steam-launcher/debian/control 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/debian/control 2020-06-24 12:36:09.000000000 +0200
@@ -16,18 +16,18 @@
Breaks: steam64
Depends: ${misc:Depends},
${python3:Depends},
- apt,
+ apt (>= 1.6) | apt-transport-https,
ca-certificates,
curl,
file,
libc6 (>= 2.15),
libnss3 (>= 2:3.26),
python3,
+ python3-apt,
xterm | gnome-terminal | konsole | x-terminal-emulator,
xz-utils,
zenity
-Recommends: jockey-common,
- sudo,
+Recommends: sudo,
xdg-utils | steamos-base-files,
Description: Launcher for the Steam software distribution service
Steam is a software distribution service with an online store, automated
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/debian/steam-launcher.postinst new/steam-launcher/debian/steam-launcher.postinst
--- old/steam-launcher/debian/steam-launcher.postinst 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/debian/steam-launcher.postinst 2020-06-24 12:36:09.000000000 +0200
@@ -3,6 +3,14 @@
#
# see: dh_installdeb(1)
+# Trigger an update to let our new udev rules be immediately effective without
+# requiring a system reboot.
+# Usually `--reload-rules` is unnecessary, but it doesn't do any harm.
+udevadm control --reload-rules || true
+udevadm trigger --action=change --sysname-match=uinput || true
+udevadm trigger --action=change --subsystem-match=usb --attr-match=idVendor=28de || true
+udevadm trigger --action=change --subsystem-match=hidraw || true
+
# popup update notification for the user to run Steam and complete the per-user install
PACKAGE=steam
UPDATENOTIFIERDIR=/var/lib/update-notifier/user.d
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/steam.list new/steam-launcher/steam.list
--- old/steam-launcher/steam.list 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/steam.list 2020-06-24 12:36:09.000000000 +0200
@@ -1,2 +1,6 @@
-deb [arch=amd64,i386] http://repo.steampowered.com/steam/ precise steam
-deb-src [arch=amd64,i386] http://repo.steampowered.com/steam/ precise steam
+deb [arch=amd64,i386] https://repo.steampowered.com/steam/ stable steam
+deb-src [arch=amd64,i386] https://repo.steampowered.com/steam/ stable steam
+
+# Uncomment these lines to try the beta version of the Steam launcher
+#deb [arch=amd64,i386] https://repo.steampowered.com/steam/ beta steam
+#deb-src [arch=amd64,i386] https://repo.steampowered.com/steam/ beta steam
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/.scrutinizer.yml new/steam-launcher/subprojects/python-vdf/.scrutinizer.yml
--- old/steam-launcher/subprojects/python-vdf/.scrutinizer.yml 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/.scrutinizer.yml 2020-06-24 12:36:09.000000000 +0200
@@ -1,11 +1,17 @@
-checks:
- python:
- code_rating: true
- duplicate_code: true
filter:
excluded_paths:
- 'tests/*'
- 'vdf2json/*'
tools:
external_code_coverage:
- runs: 9
+ timeout: 200
+ runs: 8
+
+build:
+ nodes:
+ analysis:
+ tests:
+ override:
+ - command: py-scrutinizer-run
+ idle_timeout: 300
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/.travis.yml new/steam-launcher/subprojects/python-vdf/.travis.yml
--- old/steam-launcher/subprojects/python-vdf/.travis.yml 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/.travis.yml 2020-06-24 12:36:09.000000000 +0200
@@ -1,23 +1,24 @@
language: python
-python:
- - "2.7"
- - "3.4"
- - "3.5"
- - "3.6"
- - "nightly"
- - "pypy"
- - "pypy3"
-matrix:
+os: linux
+
+jobs:
include:
+ - python: 2.7
+ - python: 3.4
+ - python: 3.5
+ - python: 3.6
- python: 3.7
- dist: xenial
- sudo: true
+ - python: 3.8
+ - python: "pypy"
+ - python: "pypy3"
install:
- - make init
- - pip install coveralls==1.1
+ - pip install -r requirements.txt
+ - pip install coveralls
- pip install scrutinizer-ocular
+before_script:
+ - rm -f .coverage vdf/*.pyc tests/*.pyc
script:
- make test
+ - PYTHONHASHSEED=0 python -m pytest --cov=vdf tests
after_success:
- coveralls
- ocular --data-file ".coverage"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/requirements.txt new/steam-launcher/subprojects/python-vdf/requirements.txt
--- old/steam-launcher/subprojects/python-vdf/requirements.txt 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/requirements.txt 2020-06-24 12:36:09.000000000 +0200
@@ -1,3 +1,3 @@
mock
-pytest==3.3.0
-pytest-cov==2.6.0
+pytest
+pytest-cov
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/tests/test_binary_vdf.py new/steam-launcher/subprojects/python-vdf/tests/test_binary_vdf.py
--- old/steam-launcher/subprojects/python-vdf/tests/test_binary_vdf.py 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/tests/test_binary_vdf.py 2020-06-24 12:36:09.000000000 +0200
@@ -2,6 +2,7 @@
import unittest
import vdf
+from io import BytesIO
from collections import OrderedDict
u = str if sys.version_info >= (3,) else unicode
@@ -48,16 +49,34 @@
def test_loads_empty(self):
self.assertEqual(vdf.binary_loads(b''), {})
+ self.assertEqual(vdf.binary_load(BytesIO(b'')), {})
def test_dumps_empty(self):
self.assertEqual(vdf.binary_dumps({}), b'')
+ buf = BytesIO()
+ vdf.binary_dump({}, buf)
+
+ self.assertEqual(buf.getvalue(), b'')
+
def test_dumps_unicode(self):
self.assertEqual(vdf.binary_dumps({u('a'): u('b')}), b'\x01a\x00b\x00\x08')
def test_dumps_unicode_alternative(self):
self.assertEqual(vdf.binary_dumps({u('a'): u('b')}, alt_format=True), b'\x01a\x00b\x00\x0b')
+ def test_dump_params_invalid(self):
+ with self.assertRaises(TypeError):
+ vdf.binary_dump([], BytesIO())
+ with self.assertRaises(TypeError):
+ vdf.binary_dump({}, b'aaaa')
+
+ def test_dumps_params_invalid(self):
+ with self.assertRaises(TypeError):
+ vdf.binary_dumps([])
+ with self.assertRaises(TypeError):
+ vdf.binary_dumps(b'aaaa')
+
def test_dumps_key_invalid_type(self):
with self.assertRaises(TypeError):
vdf.binary_dumps({1:1})
@@ -74,6 +93,24 @@
with self.assertRaises(SyntaxError):
vdf.binary_loads(b'\x00a\x00\x00b\x00\x08\x08', alt_format=True)
+ def test_load_params_invalid(self):
+ with self.assertRaises(TypeError):
+ vdf.binary_load(b'aaaa')
+ with self.assertRaises(TypeError):
+ vdf.binary_load(1234)
+ with self.assertRaises(TypeError):
+ vdf.binary_load(BytesIO(b'aaaa'), b'bbbb')
+
+ def test_loads_params_invalid(self):
+ with self.assertRaises(TypeError):
+ vdf.binary_loads([])
+ with self.assertRaises(TypeError):
+ vdf.binary_loads(11111)
+ with self.assertRaises(TypeError):
+ vdf.binary_loads(BytesIO())
+ with self.assertRaises(TypeError):
+ vdf.binary_load(b'', b'bbbb')
+
def test_loads_unbalanced_nesting(self):
with self.assertRaises(SyntaxError):
vdf.binary_loads(b'\x00a\x00\x00b\x00\x08')
@@ -108,6 +145,27 @@
self.assertEqual(vdf.binary_loads(test, merge_duplicate_keys=False), result)
+ def test_raise_on_remaining(self):
+ # default binary_loads is to raise
+ with self.assertRaises(SyntaxError):
+ vdf.binary_loads(b'\x01key\x00value\x00\x08' + b'aaaa')
+
+ # do not raise
+ self.assertEqual(vdf.binary_loads(b'\x01key\x00value\x00\x08' + b'aaaa', raise_on_remaining=False), {'key': 'value'})
+
+ def test_raise_on_remaining_with_file(self):
+ buf = BytesIO(b'\x01key\x00value\x00\x08' + b'aaaa')
+
+ # binary_load doesn't raise by default
+ self.assertEqual(vdf.binary_load(buf), {'key': 'value'})
+ self.assertEqual(buf.read(), b'aaaa')
+
+ # raise when extra data remains
+ buf.seek(0)
+ with self.assertRaises(SyntaxError):
+ vdf.binary_load(buf, raise_on_remaining=True)
+ self.assertEqual(buf.read(), b'aaaa')
+
def test_vbkv_loads_empty(self):
with self.assertRaises(ValueError):
vdf.vbkv_loads(b'')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/tests/test_vdf.py new/steam-launcher/subprojects/python-vdf/tests/test_vdf.py
--- old/steam-launcher/subprojects/python-vdf/tests/test_vdf.py 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/tests/test_vdf.py 2020-06-24 12:36:09.000000000 +0200
@@ -84,6 +84,17 @@
def tearDown(self):
self.f.close()
+ def test_dump_params_invalid(self):
+ # pretty/escaped only accept bool
+ with self.assertRaises(TypeError):
+ vdf.dump({'a': 1}, StringIO(), pretty=1)
+ with self.assertRaises(TypeError):
+ vdf.dumps({'a': 1}, pretty=1)
+ with self.assertRaises(TypeError):
+ vdf.dump({'a': 1}, StringIO(), escaped=1)
+ with self.assertRaises(TypeError):
+ vdf.dumps({'a': 1}, escaped=1)
+
def test_routine_dumps_asserts(self):
for x in [5, 5.5, 1.0j, True, None, (), {}, lambda: 0, sys.stdin, self.f]:
for y in [5, 5.5, 1.0j, None, [], (), {}, lambda: 0, sys.stdin, self.f]:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/python-vdf/vdf/__init__.py new/steam-launcher/subprojects/python-vdf/vdf/__init__.py
--- old/steam-launcher/subprojects/python-vdf/vdf/__init__.py 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/python-vdf/vdf/__init__.py 2020-06-24 12:36:09.000000000 +0200
@@ -1,14 +1,21 @@
"""
Module for deserializing/serializing to and from VDF
"""
-__version__ = "3.2"
+__version__ = "3.3"
__author__ = "Rossen Georgiev"
import re
import sys
import struct
from binascii import crc32
+from io import BytesIO
from io import StringIO as unicodeIO
+
+try:
+ from collections.abc import Mapping
+except:
+ from collections import Mapping
+
from vdf.vdict import VDFDict
# Py2 & Py3 compatibility
@@ -71,7 +78,7 @@
same key into one instead of overwriting. You can se this to ``False`` if you are
using ``VDFDict`` and need to preserve the duplicates.
"""
- if not issubclass(mapper, dict):
+ if not issubclass(mapper, Mapping):
raise TypeError("Expected mapper to be subclass of dict, got %s" % type(mapper))
if not hasattr(fp, 'readline'):
raise TypeError("Expected fp to be a file-like object supporting line iteration")
@@ -195,7 +202,7 @@
"""
Serialize ``obj`` to a VDF formatted ``str``.
"""
- if not isinstance(obj, dict):
+ if not isinstance(obj, Mapping):
raise TypeError("Expected data to be an instance of``dict``")
if not isinstance(pretty, bool):
raise TypeError("Expected pretty to be of type bool")
@@ -210,7 +217,7 @@
Serialize ``obj`` as a VDF formatted stream to ``fp`` (a
``.write()``-supporting file-like object).
"""
- if not isinstance(obj, dict):
+ if not isinstance(obj, Mapping):
raise TypeError("Expected data to be an instance of``dict``")
if not hasattr(fp, 'write'):
raise TypeError("Expected fp to have write() method")
@@ -234,7 +241,7 @@
if escaped and isinstance(key, string_type):
key = _escape(key)
- if isinstance(value, dict):
+ if isinstance(value, Mapping):
yield '%s"%s"\n%s{\n' % (line_indent, key, line_indent)
for chunk in _dump_gen(value, pretty, escaped, level+1):
yield chunk
@@ -275,9 +282,9 @@
BIN_INT64 = b'\x0A'
BIN_END_ALT = b'\x0B'
-def binary_loads(s, mapper=dict, merge_duplicate_keys=True, alt_format=False):
+def binary_loads(b, mapper=dict, merge_duplicate_keys=True, alt_format=False, raise_on_remaining=True):
"""
- Deserialize ``s`` (``bytes`` containing a VDF in "binary form")
+ Deserialize ``b`` (``bytes`` containing a VDF in "binary form")
to a Python object.
``mapper`` specifies the Python object used after deserializetion. ``dict` is
@@ -288,9 +295,27 @@
same key into one instead of overwriting. You can se this to ``False`` if you are
using ``VDFDict`` and need to preserve the duplicates.
"""
- if not isinstance(s, bytes):
- raise TypeError("Expected s to be bytes, got %s" % type(s))
- if not issubclass(mapper, dict):
+ if not isinstance(b, bytes):
+ raise TypeError("Expected s to be bytes, got %s" % type(b))
+
+ return binary_load(BytesIO(b), mapper, merge_duplicate_keys, alt_format, raise_on_remaining)
+
+def binary_load(fp, mapper=dict, merge_duplicate_keys=True, alt_format=False, raise_on_remaining=False):
+ """
+ Deserialize ``fp`` (a ``.read()``-supporting file-like object containing
+ binary VDF) to a Python object.
+
+ ``mapper`` specifies the Python object used after deserializetion. ``dict` is
+ used by default. Alternatively, ``collections.OrderedDict`` can be used if you
+ wish to preserve key order. Or any object that acts like a ``dict``.
+
+ ``merge_duplicate_keys`` when ``True`` will merge multiple KeyValue lists with the
+ same key into one instead of overwriting. You can se this to ``False`` if you are
+ using ``VDFDict`` and need to preserve the duplicates.
+ """
+ if not hasattr(fp, 'read') or not hasattr(fp, 'tell') or not hasattr(fp, 'seek'):
+ raise TypeError("Expected fp to be a file-like object with tell()/seek() and read() returning bytes")
+ if not issubclass(mapper, Mapping):
raise TypeError("Expected mapper to be subclass of dict, got %s" % type(mapper))
# helpers
@@ -299,17 +324,29 @@
int64 = struct.Struct('<q')
float32 = struct.Struct('<f')
- def read_string(s, idx, wide=False):
+ def read_string(fp, wide=False):
+ buf, end = b'', -1
+ offset = fp.tell()
+
+ # locate string end
+ while end == -1:
+ chunk = fp.read(64)
+
+ if chunk == b'':
+ raise SyntaxError("Unterminated cstring (offset: %d)" % offset)
+
+ buf += chunk
+ end = buf.find(b'\x00\x00' if wide else b'\x00')
+
if wide:
- end = s.find(b'\x00\x00', idx)
- if (end - idx) % 2 != 0:
- end += 1
- else:
- end = s.find(b'\x00', idx)
+ end += end % 2
+
+ # rewind fp
+ fp.seek(end - len(buf) + (2 if wide else 1), 1)
+
+ # decode string
+ result = buf[:end]
- if end == -1:
- raise SyntaxError("Unterminated cstring (offset: %d)" % idx)
- result = s[idx:end]
if wide:
result = result.decode('utf-16')
elif bytes is not str:
@@ -319,23 +356,20 @@
result.decode('ascii')
except:
result = result.decode('utf-8', 'replace')
- return result, end + (2 if wide else 1)
+
+ return result
stack = [mapper()]
- idx = 0
CURRENT_BIN_END = BIN_END if not alt_format else BIN_END_ALT
- while len(s) > idx:
- t = s[idx:idx+1]
- idx += 1
-
+ for t in iter(lambda: fp.read(1), b''):
if t == CURRENT_BIN_END:
if len(stack) > 1:
stack.pop()
continue
break
- key, idx = read_string(s, idx)
+ key = read_string(fp)
if t == BIN_NONE:
if merge_duplicate_keys and key in stack[-1]:
@@ -345,11 +379,11 @@
stack[-1][key] = _m
stack.append(_m)
elif t == BIN_STRING:
- stack[-1][key], idx = read_string(s, idx)
+ stack[-1][key] = read_string(fp)
elif t == BIN_WIDESTRING:
- stack[-1][key], idx = read_string(s, idx, wide=True)
+ stack[-1][key] = read_string(fp, wide=True)
elif t in (BIN_INT32, BIN_POINTER, BIN_COLOR):
- val = int32.unpack_from(s, idx)[0]
+ val = int32.unpack(fp.read(int32.size))[0]
if t == BIN_POINTER:
val = POINTER(val)
@@ -357,21 +391,20 @@
val = COLOR(val)
stack[-1][key] = val
- idx += int32.size
elif t == BIN_UINT64:
- stack[-1][key] = UINT_64(uint64.unpack_from(s, idx)[0])
- idx += uint64.size
+ stack[-1][key] = UINT_64(uint64.unpack(fp.read(int64.size))[0])
elif t == BIN_INT64:
- stack[-1][key] = INT_64(int64.unpack_from(s, idx)[0])
- idx += int64.size
+ stack[-1][key] = INT_64(int64.unpack(fp.read(int64.size))[0])
elif t == BIN_FLOAT32:
- stack[-1][key] = float32.unpack_from(s, idx)[0]
- idx += float32.size
+ stack[-1][key] = float32.unpack(fp.read(float32.size))[0]
else:
- raise SyntaxError("Unknown data type at offset %d: %s" % (idx-1, repr(t)))
+ raise SyntaxError("Unknown data type at offset %d: %s" % (fp.tell() - 1, repr(t)))
- if len(s) != idx or len(stack) != 1:
- raise SyntaxError("Binary VDF ended at offset %d, but length is %d" % (idx, len(s)))
+ if len(stack) != 1:
+ raise SyntaxError("Reached EOF, but Binary VDF is incomplete")
+ if raise_on_remaining and fp.read(1) != b'':
+ fp.seek(-1, 1)
+ raise SyntaxError("Binary VDF ended at offset %d, but there is more data remaining" % (fp.tell() - 1))
return stack.pop()
@@ -379,7 +412,21 @@
"""
Serialize ``obj`` to a binary VDF formatted ``bytes``.
"""
- return b''.join(_binary_dump_gen(obj, alt_format=alt_format))
+ buf = BytesIO()
+ binary_dump(obj, buf, alt_format)
+ return buf.getvalue()
+
+def binary_dump(obj, fp, alt_format=False):
+ """
+ Serialize ``obj`` to a binary VDF formatted ``bytes`` and write it to ``fp`` filelike object
+ """
+ if not isinstance(obj, Mapping):
+ raise TypeError("Expected obj to be type of Mapping")
+ if not hasattr(fp, 'write'):
+ raise TypeError("Expected fp to have write() method")
+
+ for chunk in _binary_dump_gen(obj, alt_format=alt_format):
+ fp.write(chunk)
def _binary_dump_gen(obj, level=0, alt_format=False):
if level == 0 and len(obj) == 0:
@@ -396,7 +443,7 @@
else:
raise TypeError("dict keys must be of type str, got %s" % type(key))
- if isinstance(value, dict):
+ if isinstance(value, Mapping):
yield BIN_NONE + key + BIN_NONE
for chunk in _binary_dump_gen(value, level+1, alt_format=alt_format):
yield chunk
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/subprojects/steam-devices/60-steam-input.rules new/steam-launcher/subprojects/steam-devices/60-steam-input.rules
--- old/steam-launcher/subprojects/steam-devices/60-steam-input.rules 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/subprojects/steam-devices/60-steam-input.rules 2020-06-24 12:36:09.000000000 +0200
@@ -31,6 +31,16 @@
# Nintendo Switch Pro Controller over bluetooth hidraw
KERNEL=="hidraw*", KERNELS=="*057E:2009*", MODE="0660", TAG+="uaccess"
+# PowerA Wired Controller for Nintendo Switch
+KERNEL=="hidraw*", ATTRS{idVendor}=="20d6", ATTRS{idProduct}=="a711", MODE="0660", TAG+="uaccess"
+
+# PowerA Wireless Controller for Nintendo Switch we have to use
+# ATTRS{name} since VID/PID are reported as zeros. We use /bin/sh
+# instead of udevadm directly becuase we need to use '*' glob at the
+# end of "hidraw" name since we don't know the index it'd have.
+#
+KERNEL=="input*", ATTRS{name}=="Lic Pro Controller", RUN{program}+="/bin/sh -c \"udevadm test-builtin uaccess /sys/%p/../../hidraw/hidraw*\""
+
# Nacon PS4 Revolution Pro Controller
KERNEL=="hidraw*", ATTRS{idVendor}=="146b", ATTRS{idProduct}=="0d01", MODE="0660", TAG+="uaccess"
@@ -61,6 +71,9 @@
# HORIPAD 4 FPS Plus
KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d", ATTRS{idProduct}=="0066", MODE="0660", TAG+="uaccess"
+# HORIPAD for Nintendo Switch
+KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d", ATTRS{idProduct}=="00c1", MODE="0660", TAG+="uaccess"
+
# Armor Armor 3 Pad PS4
KERNEL=="hidraw*", ATTRS{idVendor}=="0c12", ATTRS{idProduct}=="0e10", MODE="0660", TAG+="uaccess"
@@ -75,3 +88,6 @@
# NVIDIA Shield Controller (2017 - NVIDIA_Controller_v01.04 over bluetooth hidraw)
KERNEL=="hidraw*", KERNELS=="*0955:7214*", MODE="0660", TAG+="uaccess"
+
+# Astro C40
+KERNEL=="hidraw*", ATTRS{idVendor}=="9886", ATTRS{idProduct}=="0025", MODE="0660", TAG+="uaccess"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/steam-launcher/tests/pycodestyle.sh new/steam-launcher/tests/pycodestyle.sh
--- old/steam-launcher/tests/pycodestyle.sh 2020-03-19 18:13:39.000000000 +0100
+++ new/steam-launcher/tests/pycodestyle.sh 2020-06-24 12:36:09.000000000 +0200
@@ -23,13 +23,7 @@
echo "not ok 1 # TODO $PYCODESTYLE issues reported"
fi
-# bin_steamdeps.py has unusual whitespace so for now we ignore:
-# E117 over-indented
-# W191 indentation contains tabs
-# E201, E202 whitespace around operators
-# E501 long lines
if "${PYCODESTYLE}" \
- --ignore=E117,W191,E201,E202,E501 \
./*.py \
>&2; then
echo "ok 2 - $PYCODESTYLE reported no issues"
1
0
Hello community,
here is the log from the commit of package unrar for openSUSE:Factory:NonFree checked in at 2020-07-01 14:24:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory:NonFree/unrar (Old)
and /work/SRC/openSUSE:Factory:NonFree/.unrar.new.3060 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "unrar"
Wed Jul 1 14:24:49 2020 rev:89 rq:817640 version:5.9.4
Changes:
--------
--- /work/SRC/openSUSE:Factory:NonFree/unrar/unrar.changes 2020-06-10 01:01:50.409050699 +0200
+++ /work/SRC/openSUSE:Factory:NonFree/.unrar.new.3060/unrar.changes 2020-07-01 14:24:50.642423156 +0200
@@ -1,0 +2,6 @@
+Mon Jun 29 08:11:52 UTC 2020 - Ismail Dönmez <idonmez(a)suse.com>
+
+- Update to version 5.9.4
+ * Based on WinRAR version 5.91 final
+
+-------------------------------------------------------------------
Old:
----
unrarsrc-5.9.3.tar.gz
New:
----
unrarsrc-5.9.4.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ unrar.spec ++++++
--- /var/tmp/diff_new_pack.WzwiuP/_old 2020-07-01 14:24:51.518425873 +0200
+++ /var/tmp/diff_new_pack.WzwiuP/_new 2020-07-01 14:24:51.522425886 +0200
@@ -18,10 +18,10 @@
# majorversion should match the major version number.
%define majorversion 5
-%define libsuffix 5_9_3
+%define libsuffix 5_9_4
Name: unrar
-Version: 5.9.3
+Version: 5.9.4
Release: 0
Summary: A program to extract, test, and view RAR archives
License: NonFree
++++++ unrarsrc-5.9.3.tar.gz -> unrarsrc-5.9.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/unrar/dll.rc new/unrar/dll.rc
--- old/unrar/dll.rc 2020-06-04 20:22:24.000000000 +0200
+++ new/unrar/dll.rc 2020-06-25 12:35:32.000000000 +0200
@@ -2,8 +2,8 @@
#include <commctrl.h>
VS_VERSION_INFO VERSIONINFO
-FILEVERSION 5, 91, 1, 3449
-PRODUCTVERSION 5, 91, 1, 3449
+FILEVERSION 5, 91, 100, 3470
+PRODUCTVERSION 5, 91, 100, 3470
FILEOS VOS__WINDOWS32
FILETYPE VFT_APP
{
@@ -14,8 +14,8 @@
VALUE "CompanyName", "Alexander Roshal\0"
VALUE "ProductName", "RAR decompression library\0"
VALUE "FileDescription", "RAR decompression library\0"
- VALUE "FileVersion", "5.91.1\0"
- VALUE "ProductVersion", "5.91.1\0"
+ VALUE "FileVersion", "5.91.0\0"
+ VALUE "ProductVersion", "5.91.0\0"
VALUE "LegalCopyright", "Copyright � Alexander Roshal 1993-2020\0"
VALUE "OriginalFilename", "Unrar.dll\0"
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/unrar/version.hpp new/unrar/version.hpp
--- old/unrar/version.hpp 2020-06-04 20:26:44.000000000 +0200
+++ new/unrar/version.hpp 2020-06-25 12:40:39.000000000 +0200
@@ -1,6 +1,6 @@
#define RARVER_MAJOR 5
#define RARVER_MINOR 91
-#define RARVER_BETA 1
-#define RARVER_DAY 4
+#define RARVER_BETA 0
+#define RARVER_DAY 25
#define RARVER_MONTH 6
#define RARVER_YEAR 2020
1
0