Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which supports Python 3. Fix problems found. Remove hacking and friends from lower-constraints, they are not installed in a running system. Change-Id: Ia62b221aa0807300eaee7b075607ac6b56256b76
This commit is contained in:
@@ -25,9 +25,7 @@ dulwich==0.19.0
|
|||||||
extras==1.0.0
|
extras==1.0.0
|
||||||
fasteners==0.14.1
|
fasteners==0.14.1
|
||||||
fixtures==3.0.0
|
fixtures==3.0.0
|
||||||
flake8==2.5.5
|
|
||||||
futurist==1.6.0
|
futurist==1.6.0
|
||||||
hacking==0.12.0
|
|
||||||
horizon==17.1.0
|
horizon==17.1.0
|
||||||
idna==2.6
|
idna==2.6
|
||||||
imagesize==1.0.0
|
imagesize==1.0.0
|
||||||
@@ -64,11 +62,9 @@ oslo.utils==3.33.0
|
|||||||
osprofiler==2.0.0
|
osprofiler==2.0.0
|
||||||
packaging==17.1
|
packaging==17.1
|
||||||
pbr==2.0.0
|
pbr==2.0.0
|
||||||
pep8==1.5.7
|
|
||||||
Pint==0.8.1
|
Pint==0.8.1
|
||||||
prettytable==0.7.2
|
prettytable==0.7.2
|
||||||
pycparser==2.18
|
pycparser==2.18
|
||||||
pyflakes==0.8.1
|
|
||||||
Pygments==2.2.0
|
Pygments==2.2.0
|
||||||
pyinotify==0.9.6
|
pyinotify==0.9.6
|
||||||
pymongo==3.6.1
|
pymongo==3.6.1
|
||||||
|
@@ -122,7 +122,7 @@ class DeleteReplica(tables.DeleteAction):
|
|||||||
replicas = manila.share_replica_list(request, replica.share_id)
|
replicas = manila.share_replica_list(request, replica.share_id)
|
||||||
if share.replication_type is None:
|
if share.replication_type is None:
|
||||||
return False
|
return False
|
||||||
elif (share.replication_type is 'writable' and
|
elif (share.replication_type == 'writable' and
|
||||||
replica.status in DELETABLE_STATUSES and
|
replica.status in DELETABLE_STATUSES and
|
||||||
len(replicas) > 1) or (
|
len(replicas) > 1) or (
|
||||||
share.replication_type in ('dr', 'readable') and
|
share.replication_type in ('dr', 'readable') and
|
||||||
|
@@ -108,7 +108,7 @@ class DeleteReplica(tables.DeleteAction):
|
|||||||
replicas = manila.share_replica_list(request, replica.share_id)
|
replicas = manila.share_replica_list(request, replica.share_id)
|
||||||
if share.replication_type is None:
|
if share.replication_type is None:
|
||||||
return False
|
return False
|
||||||
elif (share.replication_type is 'writable' and
|
elif (share.replication_type == 'writable' and
|
||||||
replica.status in DELETABLE_STATUSES and
|
replica.status in DELETABLE_STATUSES and
|
||||||
len(replicas) > 1) or (
|
len(replicas) > 1) or (
|
||||||
share.replication_type in ('dr', 'readable') and
|
share.replication_type in ('dr', 'readable') and
|
||||||
|
@@ -44,7 +44,7 @@ def parse_str_meta(meta_s):
|
|||||||
for string in strings:
|
for string in strings:
|
||||||
if string.count("=") == 0:
|
if string.count("=") == 0:
|
||||||
# Key for unsetting
|
# Key for unsetting
|
||||||
key = string.strip('\"\'\ ')
|
key = string.strip(r'\"\' ')
|
||||||
if len(key) not in range(1, 256):
|
if len(key) not in range(1, 256):
|
||||||
msg = _("Key '%s' has improper length.") % key
|
msg = _("Key '%s' has improper length.") % key
|
||||||
elif " " in key:
|
elif " " in key:
|
||||||
@@ -53,7 +53,7 @@ def parse_str_meta(meta_s):
|
|||||||
unset_list.append(key)
|
unset_list.append(key)
|
||||||
else:
|
else:
|
||||||
# Key-value pair for setting
|
# Key-value pair for setting
|
||||||
pair = [p.strip('\"\'\ ') for p in string.split("=", 1)]
|
pair = [p.strip(r'\"\' ') for p in string.split("=", 1)]
|
||||||
if not all(len(p) in range(1, 256) for p in pair):
|
if not all(len(p) in range(1, 256) for p in pair):
|
||||||
msg = _("All keys and values must be in range from 1 to 255.")
|
msg = _("All keys and values must be in range from 1 to 255.")
|
||||||
elif pair[0] in list(set_dict.keys()):
|
elif pair[0] in list(set_dict.keys()):
|
||||||
|
@@ -25,6 +25,7 @@ def data(TEST):
|
|||||||
"publicURL": "http://public.manila.example.com:8786/v1"}]},
|
"publicURL": "http://public.manila.example.com:8786/v1"}]},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
projects = [
|
projects = [
|
||||||
type("%sProject" % v, (object, ),
|
type("%sProject" % v, (object, ),
|
||||||
{'id': '%s_id' % v, 'name': '%s_name' % v})
|
{'id': '%s_id' % v, 'name': '%s_name' % v})
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
# of appearance. Changing the order has an impact on the overall integration
|
# of appearance. Changing the order has an impact on the overall integration
|
||||||
# process, which may cause wedges in the gate later.
|
# process, which may cause wedges in the gate later.
|
||||||
|
|
||||||
hacking>=1.1.0,<1.2.0 # Apache-2.0
|
hacking>=3.0,<3.1.0 # Apache-2.0
|
||||||
coverage!=4.4,>=4.0 # Apache-2.0
|
coverage!=4.4,>=4.0 # Apache-2.0
|
||||||
ddt>=1.0.1 # MIT
|
ddt>=1.0.1 # MIT
|
||||||
mock>=2.0.0 # BSD
|
mock>=2.0.0 # BSD
|
||||||
|
3
tox.ini
3
tox.ini
@@ -79,7 +79,8 @@ show-source = True
|
|||||||
# F405 TEMPLATES may be undefined, or defined from star imports
|
# F405 TEMPLATES may be undefined, or defined from star imports
|
||||||
# (because it is not easy to avoid this in openstack_dashboard.test.settings)
|
# (because it is not easy to avoid this in openstack_dashboard.test.settings)
|
||||||
# H405 multi line docstring summary not separated with an empty line
|
# H405 multi line docstring summary not separated with an empty line
|
||||||
ignore = E123,E125,F405,H405
|
# W504 line break after binary operator
|
||||||
|
ignore = E123,E125,F405,H405,W504
|
||||||
enable-extensions = H203,H106
|
enable-extensions = H203,H106
|
||||||
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,.ropeproject,tools
|
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,.ropeproject,tools
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user