Hello community,
here is the log from the commit of package python-azure-storage-common for
openSUSE:Factory checked in at 2019-10-10 14:33:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-azure-storage-common (Old)
and /work/SRC/openSUSE:Factory/.python-azure-storage-common.new.2352 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-azure-storage-common"
Thu Oct 10 14:33:58 2019 rev:4 rq:735799 version:2.1.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-azure-storage-common/python-azure-storage-common.changes
2019-05-14 13:40:56.296331629 +0200
+++
/work/SRC/openSUSE:Factory/.python-azure-storage-common.new.2352/python-azure-storage-common.changes
2019-10-10 14:33:59.648115738 +0200
@@ -1,0 +2,11 @@
+Fri Oct 4 12:21:50 UTC 2019 - John Paul Adrian Glaubitz
<[email protected]>
+
+- New upstream release
+ + Version 2.1.0
+ + For detailed information about changes see the
+ HISTORY.txt file provided with this package
+- Drop patch to support older versions of setuptools as
+ SLE-12 is now shipping with a recent enough version
+ + asc_drop-extras-require.patch
+
+-------------------------------------------------------------------
Old:
----
asc_drop-extras-require.patch
azure-storage-common-1.4.0.tar.gz
New:
----
azure-storage-common-2.1.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-azure-storage-common.spec ++++++
--- /var/tmp/diff_new_pack.ZMfnpL/_old 2019-10-10 14:34:00.380114032 +0200
+++ /var/tmp/diff_new_pack.ZMfnpL/_new 2019-10-10 14:34:00.380114032 +0200
@@ -18,7 +18,7 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-azure-storage-common
-Version: 1.4.0
+Version: 2.1.0
Release: 0
Summary: Microsoft Azure Storage Common Client Library for Python
License: MIT
@@ -26,7 +26,6 @@
Url: https://github.com/Azure/azure-sdk-for-python
Source:
https://files.pythonhosted.org/packages/source/a/azure-storage-common/azure-storage-common-%{version}.tar.gz
Source1: LICENSE.txt
-Patch1: asc_drop-extras-require.patch
BuildRequires: %{python_module azure-nspkg >= 3.0.0}
BuildRequires: %{python_module azure-storage-nspkg >= 3.0.0}
BuildRequires: %{python_module setuptools}
@@ -53,7 +52,6 @@
%prep
%setup -q -n azure-storage-common-%{version}
-%patch1 -p1
%build
install -m 644 %{SOURCE1} %{_builddir}/azure-storage-common-%{version}
++++++ azure-storage-common-1.4.0.tar.gz -> azure-storage-common-2.1.0.tar.gz
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/azure-storage-common-1.4.0/PKG-INFO
new/azure-storage-common-2.1.0/PKG-INFO
--- old/azure-storage-common-1.4.0/PKG-INFO 2018-11-10 03:01:25.000000000
+0100
+++ new/azure-storage-common-2.1.0/PKG-INFO 2019-08-02 06:12:48.000000000
+0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: azure-storage-common
-Version: 1.4.0
+Version: 2.1.0
Summary: Microsoft Azure Storage Common Client Library for Python
Home-page: https://github.com/Azure/azure-storage-python
Author: Microsoft Corporation
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/_auth.py
new/azure-storage-common-2.1.0/azure/storage/common/_auth.py
--- old/azure-storage-common-1.4.0/azure/storage/common/_auth.py
2018-11-10 00:24:09.000000000 +0100
+++ new/azure-storage-common-2.1.0/azure/storage/common/_auth.py
2019-07-29 21:18:27.000000000 +0200
@@ -74,8 +74,6 @@
# Doing so will clarify/locate the source of problem
raise _wrap_exception(ex, AzureSigningError)
-
-class _StorageSharedKeyAuthentication(_StorageSharedKeyAuthentication):
def sign_request(self, request):
string_to_sign = \
self._get_verb(request) + \
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/_constants.py
new/azure-storage-common-2.1.0/azure/storage/common/_constants.py
--- old/azure-storage-common-1.4.0/azure/storage/common/_constants.py
2018-11-10 00:24:52.000000000 +0100
+++ new/azure-storage-common-2.1.0/azure/storage/common/_constants.py
2019-08-02 06:02:22.000000000 +0200
@@ -7,7 +7,7 @@
import sys
__author__ = 'Microsoft Corp. <[email protected]>'
-__version__ = '1.4.0'
+__version__ = '2.1.0'
# UserAgent string sample: 'Azure-Storage/0.37.0-0.38.0 (Python CPython 3.4.2;
Windows 8)'
# First version(0.37.0) is the common package, and the second version(0.38.0)
is the service package
@@ -17,7 +17,7 @@
platform.release())
# default values for common package, in case it is used directly
-DEFAULT_X_MS_VERSION = '2018-03-28'
+DEFAULT_X_MS_VERSION = '2019-02-02'
DEFAULT_USER_AGENT_STRING = '{}None {}'.format(USER_AGENT_STRING_PREFIX,
USER_AGENT_STRING_SUFFIX)
# Live ServiceClient URLs
@@ -49,3 +49,4 @@
_AUTHORIZATION_HEADER_NAME = 'Authorization'
_COPY_SOURCE_HEADER_NAME = 'x-ms-copy-source'
_REDACTED_VALUE = 'REDACTED'
+_CLIENT_REQUEST_ID_HEADER_NAME = 'x-ms-client-request-id'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/_deserialization.py
new/azure-storage-common-2.1.0/azure/storage/common/_deserialization.py
--- old/azure-storage-common-1.4.0/azure/storage/common/_deserialization.py
2018-09-10 23:24:14.000000000 +0200
+++ new/azure-storage-common-2.1.0/azure/storage/common/_deserialization.py
2019-07-29 21:41:49.000000000 +0200
@@ -64,6 +64,7 @@
'x-ms-archive-status': (None, 'rehydration_status', _to_str),
'x-ms-share-quota': (None, 'quota', _to_int),
'x-ms-server-encrypted': (None, 'server_encrypted', _bool),
+ 'x-ms-encryption-key-sha256': (None, 'encryption_key_sha256', _to_str),
'x-ms-creation-time': (None, 'creation_time', parser.parse),
'content-type': ('content_settings', 'content_type', _to_str),
'cache-control': ('content_settings', 'cache_control', _to_str),
@@ -83,6 +84,13 @@
'x-ms-copy-status-description': ('copy', 'status_description', _to_str),
'x-ms-has-immutability-policy': (None, 'has_immutability_policy', _bool),
'x-ms-has-legal-hold': (None, 'has_legal_hold', _bool),
+ 'x-ms-file-attributes': ('smb_properties', 'ntfs_attributes', _to_str),
+ 'x-ms-file-creation-time': ('smb_properties', 'creation_time',
parser.parse, True),
+ 'x-ms-file-last-write-time': ('smb_properties', 'last_write_time',
parser.parse, True),
+ 'x-ms-file-change-time': ('smb_properties', 'change_time', parser.parse,
True),
+ 'x-ms-file-permission-key': ('smb_properties', 'permission_key', _to_str),
+ 'x-ms-file-id': ('smb_properties', 'file_id', _to_str),
+ 'x-ms-file-parent-id': ('smb_properties', 'parent_id', _to_str),
}
@@ -119,7 +127,11 @@
setattr(props, info[1], info[2](value))
else:
attr = getattr(props, info[0])
- setattr(attr, info[1], info[2](value))
+ # if info[3] is True, time zones in parsed strings are ignored
and a naive :class:`datetime` object
+ # will be returned.
+ ignoretz = info[3] if len(info) > 3 else False
+ header_value = info[2](value, ignoretz=ignoretz) if info[2] is
parser.parse else info[2](value)
+ setattr(attr, info[1], header_value)
if hasattr(props, 'blob_type') and props.blob_type == 'PageBlob' and
hasattr(props, 'blob_tier') and props.blob_tier is not None:
props.blob_tier = _to_upper_str(props.blob_tier)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/_error.py
new/azure-storage-common-2.1.0/azure/storage/common/_error.py
--- old/azure-storage-common-1.4.0/azure/storage/common/_error.py
2018-10-23 23:30:56.000000000 +0200
+++ new/azure-storage-common-2.1.0/azure/storage/common/_error.py
2019-06-07 09:59:17.000000000 +0200
@@ -183,6 +183,16 @@
raise ValueError(_ERROR_UNSUPPORTED_METHOD_FOR_ENCRYPTION)
+def _validate_user_delegation_key(user_delegation_key):
+ _validate_not_none('user_delegation_key.signed_oid',
user_delegation_key.signed_oid)
+ _validate_not_none('user_delegation_key.signed_tid',
user_delegation_key.signed_tid)
+ _validate_not_none('user_delegation_key.signed_start',
user_delegation_key.signed_start)
+ _validate_not_none('user_delegation_key.signed_expiry',
user_delegation_key.signed_expiry)
+ _validate_not_none('user_delegation_key.signed_version',
user_delegation_key.signed_version)
+ _validate_not_none('user_delegation_key.signed_service',
user_delegation_key.signed_service)
+ _validate_not_none('user_delegation_key.value', user_delegation_key.value)
+
+
# wraps a given exception with the desired exception type
def _wrap_exception(ex, desired_type):
msg = ""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/_serialization.py
new/azure-storage-common-2.1.0/azure/storage/common/_serialization.py
--- old/azure-storage-common-1.4.0/azure/storage/common/_serialization.py
2018-09-10 23:24:14.000000000 +0200
+++ new/azure-storage-common-2.1.0/azure/storage/common/_serialization.py
2019-07-29 21:41:49.000000000 +0200
@@ -34,6 +34,7 @@
from ._common_conversion import (
_str,
)
+from ._constants import _CLIENT_REQUEST_ID_HEADER_NAME
def _to_utc_datetime(value):
@@ -62,7 +63,7 @@
# append addtional headers based on the service
request.headers['x-ms-version'] = x_ms_version
request.headers['User-Agent'] = user_agent_string
- request.headers['x-ms-client-request-id'] = str(uuid.uuid1())
+ request.headers[_CLIENT_REQUEST_ID_HEADER_NAME] = str(uuid.uuid1())
# If the host has a path component (ex local storage), move it
path = request.host.split('/', 1)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/sharedaccesssignature.py
new/azure-storage-common-2.1.0/azure/storage/common/sharedaccesssignature.py
---
old/azure-storage-common-1.4.0/azure/storage/common/sharedaccesssignature.py
2018-10-17 22:48:05.000000000 +0200
+++
new/azure-storage-common-2.1.0/azure/storage/common/sharedaccesssignature.py
2019-06-07 09:59:17.000000000 +0200
@@ -157,43 +157,6 @@
self._add_query(_QueryStringConstants.SIGNED_CONTENT_LANGUAGE,
content_language)
self._add_query(_QueryStringConstants.SIGNED_CONTENT_TYPE,
content_type)
- def add_resource_signature(self, account_name, account_key, service, path):
- def get_value_to_append(query):
- return_value = self.query_dict.get(query) or ''
- return return_value + '\n'
-
- if path[0] != '/':
- path = '/' + path
-
- canonicalized_resource = '/' + service + '/' + account_name + path +
'\n'
-
- # Form the string to sign from shared_access_policy and canonicalized
- # resource. The order of values is important.
- string_to_sign = \
- (get_value_to_append(_QueryStringConstants.SIGNED_PERMISSION) +
- get_value_to_append(_QueryStringConstants.SIGNED_START) +
- get_value_to_append(_QueryStringConstants.SIGNED_EXPIRY) +
- canonicalized_resource +
- get_value_to_append(_QueryStringConstants.SIGNED_IDENTIFIER) +
- get_value_to_append(_QueryStringConstants.SIGNED_IP) +
- get_value_to_append(_QueryStringConstants.SIGNED_PROTOCOL) +
- get_value_to_append(_QueryStringConstants.SIGNED_VERSION))
-
- if service == 'blob' or service == 'file':
- string_to_sign += \
-
(get_value_to_append(_QueryStringConstants.SIGNED_CACHE_CONTROL) +
-
get_value_to_append(_QueryStringConstants.SIGNED_CONTENT_DISPOSITION) +
-
get_value_to_append(_QueryStringConstants.SIGNED_CONTENT_ENCODING) +
-
get_value_to_append(_QueryStringConstants.SIGNED_CONTENT_LANGUAGE) +
-
get_value_to_append(_QueryStringConstants.SIGNED_CONTENT_TYPE))
-
- # remove the trailing newline
- if string_to_sign[-1] == '\n':
- string_to_sign = string_to_sign[:-1]
-
- self._add_query(_QueryStringConstants.SIGNED_SIGNATURE,
- _sign_string(account_key, string_to_sign))
-
def add_account_signature(self, account_name, account_key):
def get_value_to_append(query):
return_value = self.query_dict.get(query) or ''
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure/storage/common/storageclient.py
new/azure-storage-common-2.1.0/azure/storage/common/storageclient.py
--- old/azure-storage-common-1.4.0/azure/storage/common/storageclient.py
2018-11-10 00:24:09.000000000 +0100
+++ new/azure-storage-common-2.1.0/azure/storage/common/storageclient.py
2019-07-29 21:42:06.000000000 +0200
@@ -24,6 +24,7 @@
_AUTHORIZATION_HEADER_NAME,
_REDACTED_VALUE,
_COPY_SOURCE_HEADER_NAME,
+ _CLIENT_REQUEST_ID_HEADER_NAME,
)
from ._error import (
_ERROR_DECRYPTION_FAILURE,
@@ -149,6 +150,7 @@
self.retry_callback = None
self._X_MS_VERSION = DEFAULT_X_MS_VERSION
self._USER_AGENT_STRING = DEFAULT_USER_AGENT_STRING
+ self._is_validating_request_id = True
def _update_user_agent_string(self, service_package_version):
self._USER_AGENT_STRING = '{}{} {}'.format(USER_AGENT_STRING_PREFIX,
@@ -260,6 +262,16 @@
clean_queries[_QueryStringConstants.SIGNED_SIGNATURE] =
_REDACTED_VALUE
return clean_queries
+ @staticmethod
+ def _validate_echoed_client_request_id(request, response):
+ # raise exception if the echoed client request id from the service is
not identical to the one we sent
+ if _CLIENT_REQUEST_ID_HEADER_NAME in response.headers and \
+ request.headers[_CLIENT_REQUEST_ID_HEADER_NAME] !=
response.headers[_CLIENT_REQUEST_ID_HEADER_NAME]:
+ raise AzureException(
+ "Echoed client request ID: {} does not match sent client
request ID: {}. Service request ID: {}".format(
+ response.headers[_CLIENT_REQUEST_ID_HEADER_NAME],
request.headers[_CLIENT_REQUEST_ID_HEADER_NAME],
+ response.headers['x-ms-request-id']))
+
def _perform_request(self, request, parser=None, parser_args=None,
operation_context=None, expected_errors=None):
'''
Sends the request and return response. Catches HTTPError and hands it
@@ -282,7 +294,7 @@
# Apply common settings to the request
_update_request(request, self._X_MS_VERSION, self._USER_AGENT_STRING)
- client_request_id_prefix = str.format("Client-Request-ID={0}",
request.headers['x-ms-client-request-id'])
+ client_request_id_prefix = str.format("Client-Request-ID={0}",
request.headers[_CLIENT_REQUEST_ID_HEADER_NAME])
while True:
try:
@@ -324,6 +336,10 @@
if self.response_callback:
self.response_callback(response)
+ # Validate the client request ID
+ if self._is_validating_request_id:
+ self._validate_echoed_client_request_id(request,
response)
+
# Set the response context
retry_context.response = response
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/azure-storage-common-1.4.0/azure_storage_common.egg-info/PKG-INFO
new/azure-storage-common-2.1.0/azure_storage_common.egg-info/PKG-INFO
--- old/azure-storage-common-1.4.0/azure_storage_common.egg-info/PKG-INFO
2018-11-10 03:01:25.000000000 +0100
+++ new/azure-storage-common-2.1.0/azure_storage_common.egg-info/PKG-INFO
2019-08-02 06:12:48.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: azure-storage-common
-Version: 1.4.0
+Version: 2.1.0
Summary: Microsoft Azure Storage Common Client Library for Python
Home-page: https://github.com/Azure/azure-storage-python
Author: Microsoft Corporation
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/azure-storage-common-1.4.0/setup.py
new/azure-storage-common-2.1.0/setup.py
--- old/azure-storage-common-1.4.0/setup.py 2018-11-10 00:24:52.000000000
+0100
+++ new/azure-storage-common-2.1.0/setup.py 2019-08-02 06:02:49.000000000
+0200
@@ -44,7 +44,7 @@
setup(
name='azure-storage-common',
- version='1.4.0',
+ version='2.1.0',
description='Microsoft Azure Storage Common Client Library for Python',
long_description=open('README.rst', 'r').read(),
license='MIT License',