Hello community,
here is the log from the commit of package python3-susepubliccloudinfo for
openSUSE:Factory checked in at 2018-08-27 13:47:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-susepubliccloudinfo (Old)
and /work/SRC/openSUSE:Factory/.python3-susepubliccloudinfo.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-susepubliccloudinfo"
Mon Aug 27 13:47:57 2018 rev:3 rq:628568 version:1.0.4
Changes:
--------
---
/work/SRC/openSUSE:Factory/python3-susepubliccloudinfo/python3-susepubliccloudinfo.changes
2018-01-29 14:57:58.817056846 +0100
+++
/work/SRC/openSUSE:Factory/.python3-susepubliccloudinfo.new/python3-susepubliccloudinfo.changes
2018-08-27 13:47:58.768434286 +0200
@@ -1,0 +2,12 @@
+Fri Aug 3 09:22:06 UTC 2018 - [email protected]
+
+- Update to version 1.0.4 (bsc#1103684)
+ + Avoid traceback on improper query options
+
+-------------------------------------------------------------------
+Wed Apr 11 21:13:10 UTC 2018 - [email protected]
+
+- Update to version 1.0.3 (bsc#1089196)
+ + Make request implementation to access pint server usable as library
+
+-------------------------------------------------------------------
Old:
----
susepubliccloudinfo-1.0.2.tar.bz2
New:
----
susepubliccloudinfo-1.0.4.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-susepubliccloudinfo.spec ++++++
--- /var/tmp/diff_new_pack.s1FDUa/_old 2018-08-27 13:47:59.552435403 +0200
+++ /var/tmp/diff_new_pack.s1FDUa/_new 2018-08-27 13:47:59.556435409 +0200
@@ -18,10 +18,10 @@
%define upstream_name susepubliccloudinfo
Name: python3-susepubliccloudinfo
-Version: 1.0.2
+Version: 1.0.4
Release: 0
Summary: Query SUSE Public Cloud Info Service
-License: GPL-3.0+
+License: GPL-3.0-or-later
Group: System/Management
Url: https://github.com/SUSE/Enceladus
Source0: %{upstream_name}-%{version}.tar.bz2
++++++ susepubliccloudinfo-1.0.2.tar.bz2 -> susepubliccloudinfo-1.0.4.tar.bz2
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/susepubliccloudinfo-1.0.2/bin/awscsvgen
new/susepubliccloudinfo-1.0.4/bin/awscsvgen
--- old/susepubliccloudinfo-1.0.2/bin/awscsvgen 2018-01-19 16:50:56.931949502
+0100
+++ new/susepubliccloudinfo-1.0.4/bin/awscsvgen 2018-08-03 11:17:04.824547271
+0200
@@ -1,6 +1,6 @@
-#!/usr/bin/python
+#!/usr/bin/python3
#
-# Copyright (c) 2015 SUSE Linux GmbH. All rights reserved.
+# Copyright (c) 2018 SUSE Linux GmbH. All rights reserved.
#
# This file is part of susePublicCloudInfoClient
#
@@ -45,9 +45,6 @@
from docopt import docopt
from lxml import etree
-import boto
-import boto.ec2
-
import susepubliccloudinfoclient.infoserverrequests as ifsrequest
import susepubliccloudinfoclient.version as version
@@ -81,36 +78,31 @@
region,
name_filter)
-ec2_regions = boto.ec2.regions()
-image_info = etree.fromstring(image_data)
-region_data = {}
-for region in ec2_regions:
- region_data[region.name] = []
-
-for image in image_info.findall('image'):
- region_data[image.get('region')].append(image)
-
print('ami-name,ami-id,region,arch,virt-typ,backing-store')
-for region in ec2_regions:
- for image in region_data[region.name]:
- name = image.get('name')
- if virt_type and virt_type not in name:
- continue
- if 'hvm' in name:
- virt_type = 'hvm'
- else:
- virt_type = 'pv'
- if 'x86_64' in name:
- arch = 'x86_64'
- else:
- arch = 'i386'
- if 'ssd' in name:
- backing_store = 'gp2'
- else:
- backing_store = 'standard'
- print('%s,%s,%s,%s,%s,%s' % (name,
- image.get('id'),
- region.name,
- arch,
- virt_type,
- backing_store))
+for entry in image_data.split('\n'):
+ image_info = entry.strip()
+ if not image_info.startswith('<image '):
+ continue
+ image = etree.fromstring(image_info)
+ name = image.get('name')
+ region = image.get('region')
+ if virt_type and virt_type not in name:
+ continue
+ if 'hvm' in name:
+ virt_type = 'hvm'
+ else:
+ virt_type = 'pv'
+ if 'x86_64' in name:
+ arch = 'x86_64'
+ else:
+ arch = 'i386'
+ if 'ssd' in name:
+ backing_store = 'gp2'
+ else:
+ backing_store = 'standard'
+ print('%s,%s,%s,%s,%s,%s' % (name,
+ image.get('id'),
+ region,
+ arch,
+ virt_type,
+ backing_store))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/susepubliccloudinfo-1.0.2/bin/pint
new/susepubliccloudinfo-1.0.4/bin/pint
--- old/susepubliccloudinfo-1.0.2/bin/pint 2018-01-19 16:50:56.931949502
+0100
+++ new/susepubliccloudinfo-1.0.4/bin/pint 2018-08-03 11:17:04.824547271
+0200
@@ -1,6 +1,6 @@
-#!/usr/bin/python
+#!/usr/bin/python3
#
-# Copyright (c) 2015 SUSE Linux GmbH. All rights reserved.
+# Copyright (c) 2018 SUSE Linux GmbH. All rights reserved.
#
# This file is part of susePublicCloudInfoClient
#
@@ -52,6 +52,8 @@
Show program version
"""
+import sys
+
from docopt import docopt
import susepubliccloudinfoclient.infoserverrequests as ifsrequest
@@ -91,17 +93,20 @@
if command_args['--region']:
region = command_args['--region']
-if command_args['images']:
- print(ifsrequest.get_image_data(
- framework,
- image_state,
- output_format,
- region,
- command_args['--filter']).decode())
-else:
- print(ifsrequest.get_server_data(
- framework,
- server_type,
- output_format,
- region,
- command_args['--filter']).decode())
+try:
+ if command_args['images']:
+ print(ifsrequest.get_image_data(
+ framework,
+ image_state,
+ output_format,
+ region,
+ command_args['--filter']))
+ else:
+ print(ifsrequest.get_server_data(
+ framework,
+ server_type,
+ output_format,
+ region,
+ command_args['--filter']))
+except Exception:
+ sys.exit(1)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/susepubliccloudinfo-1.0.2/lib/susepubliccloudinfoclient/infoserverrequests.py
new/susepubliccloudinfo-1.0.4/lib/susepubliccloudinfoclient/infoserverrequests.py
---
old/susepubliccloudinfo-1.0.2/lib/susepubliccloudinfoclient/infoserverrequests.py
2018-01-19 16:50:56.935949416 +0100
+++
new/susepubliccloudinfo-1.0.4/lib/susepubliccloudinfoclient/infoserverrequests.py
2018-08-03 11:17:04.824547271 +0200
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2015 SUSE Linux GmbH. All rights reserved.
+# Copyright (c) 2018 SUSE Linux GmbH. All rights reserved.
#
# This file is part of susePublicCloudInfoClient
#
@@ -268,7 +268,7 @@
root,
xml_declaration=True,
encoding='UTF-8',
- pretty_print=True)
+ pretty_print=True).decode()
def __warn(str, out=sys.stdout):
@@ -277,7 +277,7 @@
def __error(str, out=sys.stderr):
out.write("Error: %s\n" % str)
- sys.exit(1)
+ raise LookupError(str)
def __process(url, info_type, command_arg_filter, result_format):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/susepubliccloudinfo-1.0.2/lib/susepubliccloudinfoclient/version.py
new/susepubliccloudinfo-1.0.4/lib/susepubliccloudinfoclient/version.py
--- old/susepubliccloudinfo-1.0.2/lib/susepubliccloudinfoclient/version.py
2018-01-19 16:50:56.935949416 +0100
+++ new/susepubliccloudinfo-1.0.4/lib/susepubliccloudinfoclient/version.py
2018-08-03 11:17:04.824547271 +0200
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2015 SUSE Linux GmbH. All rights reserved.
+# Copyright (c) 2018 SUSE Linux GmbH. All rights reserved.
#
# This file is part of susePublicCloudInfoClient
#
@@ -17,4 +17,4 @@
# along with susePublicCloudInfoClient. If not, see
# <http://www.gnu.org/licenses/>.
#
-VERSION = '1.0.2'
+VERSION = '1.0.4'