Merge "[requirements] Update requirements"
This commit is contained in:
commit
e6f4dafc9a
@ -1,7 +1,8 @@
|
|||||||
python-mistralclient>=2.0.0,<=2.1.1
|
python-mistralclient>=2.0.0
|
||||||
|
# [do-not-touch] our plugins support only one version of fuelclient
|
||||||
python-fuelclient==6.1.0 # Apache Software License
|
python-fuelclient==6.1.0 # Apache Software License
|
||||||
python-muranoclient>=0.8.2,<=0.11.0 # Apache License, Version 2.0
|
python-muranoclient>=0.8.2 # Apache License, Version 2.0
|
||||||
python-cueclient>=1.0.0,<=1.0.0 # Apache License, Version 2.0
|
python-cueclient>=1.0.0 # Apache License, Version 2.0
|
||||||
python-senlinclient>=0.3.0,<=1.0.0 # Apache Software License
|
python-senlinclient>=0.3.0 # Apache Software License
|
||||||
python-magnumclient>=2.0.0,<=2.3.0 # Apache Software License
|
python-magnumclient>=2.0.0 # Apache Software License
|
||||||
gnocchiclient>=2.2.0,<=2.5.0 # Apache Software License
|
gnocchiclient>=2.2.0 # Apache Software License
|
||||||
|
@ -1,45 +1,41 @@
|
|||||||
# The order of packages is significant, because pip processes them in the order
|
# The order of packages is significant, because pip processes them in the order
|
||||||
# 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.
|
||||||
alembic>=0.8.4,<=0.8.7 # MIT
|
alembic>=0.8.4 # MIT
|
||||||
boto>=2.32.1,<=2.42.0 # MIT
|
boto>=2.32.1 # MIT
|
||||||
decorator>=3.4.0,<=4.0.10 # new BSD License
|
decorator>=3.4.0 # new BSD License
|
||||||
Jinja2>=2.8,<=2.8 # BSD
|
Jinja2>=2.8 # BSD
|
||||||
# [constant-upper-limit]
|
jsonschema>=2.0.0,!=2.5.0,<3.0.0 # MIT
|
||||||
jsonschema!=2.5.0,>=2.0.0,<3.0.0 # MIT
|
netaddr>=0.7.12,!=0.7.16 # BSD
|
||||||
netaddr!=0.7.16,>=0.7.12,<=0.7.18 # BSD
|
oslo.config>=3.14.0 # Apache Software License
|
||||||
oslo.config>=3.14.0,<=3.17.0 # Apache Software License
|
oslo.db>=4.10.0 # Apache Software License
|
||||||
oslo.db>=4.10.0,<=4.13.1 # Apache Software License
|
oslo.i18n>=2.1.0 # Apache Software License
|
||||||
oslo.i18n>=2.1.0,<=3.9.0 # Apache Software License
|
oslo.log>=1.14.0 # Apache Software License
|
||||||
oslo.log>=1.14.0,<=3.16.0 # Apache Software License
|
oslo.serialization>=1.10.0 # Apache Software License
|
||||||
oslo.serialization>=1.10.0,<=2.13.0 # Apache Software License
|
oslo.utils>=3.16.0 # Apache Software License
|
||||||
oslo.utils>=3.16.0,<=3.16.0 # Apache Software License
|
paramiko>=2.0 # LGPL
|
||||||
paramiko>=2.0,<=2.0.2 # LGPL
|
pbr>=1.6 # Apache Software License
|
||||||
pbr>=1.6,<=1.10.0 # Apache Software License
|
|
||||||
# [constant-upper-limit]
|
|
||||||
PrettyTable>=0.7,<0.8 # BSD
|
PrettyTable>=0.7,<0.8 # BSD
|
||||||
PyYAML>=3.1.0,<=3.12 # MIT
|
PyYAML>=3.1.0 # MIT
|
||||||
python-designateclient>=1.5.0,<=2.3.0 # Apache License, Version 2.0
|
python-designateclient>=1.5.0 # Apache License, Version 2.0
|
||||||
python-glanceclient!=2.4.0,>=2.3.0,<=2.5.0 # Apache License, Version 2.0
|
python-glanceclient>=2.3.0,!=2.4.0 # Apache License, Version 2.0
|
||||||
python-keystoneclient!=2.1.0,>=2.0.0,<=3.5.0 # Apache Software License
|
python-keystoneclient>=2.0.0,!=2.1.0 # Apache Software License
|
||||||
keystoneauth1>=2.10.0,<=2.12.1 # Apache Software License
|
keystoneauth1>=2.10.0 # Apache Software License
|
||||||
python-novaclient!=2.33.0,>=2.29.0,<=6.0.0 # Apache License, Version 2.0
|
python-novaclient>=2.29.0,!=2.33.0 # Apache License, Version 2.0
|
||||||
python-neutronclient>=5.1.0,<=6.0.0 # Apache Software License
|
python-neutronclient>=5.1.0 # Apache Software License
|
||||||
python-cinderclient!=1.7.0,!=1.7.1,>=1.6.0,<=1.9.0 # Apache Software License
|
python-cinderclient>=1.6.0,!=1.7.0,!=1.7.1 # Apache Software License
|
||||||
python-manilaclient>=1.10.0,<=1.11.0 # Apache Software License
|
python-manilaclient>=1.10.0 # Apache Software License
|
||||||
python-monascaclient>=1.1.0,<=1.2.0 # Apache Software License
|
python-monascaclient>=1.1.0 # Apache Software License
|
||||||
python-heatclient>=1.4.0,<=1.4.0 # Apache Software License
|
python-heatclient>=1.4.0 # Apache Software License
|
||||||
python-ceilometerclient>=2.5.0,<=2.6.0 # Apache Software License
|
python-ceilometerclient>=2.5.0 # Apache Software License
|
||||||
python-ironicclient>=1.6.0,<=1.7.0 # Apache Software License
|
python-ironicclient>=1.6.0 # Apache Software License
|
||||||
python-saharaclient>=0.18.0,<=0.18.0 # Apache License, Version 2.0
|
python-saharaclient>=0.18.0 # Apache License, Version 2.0
|
||||||
python-troveclient>=2.2.0,<=2.5.0 # Apache Software License
|
python-troveclient>=2.2.0 # Apache Software License
|
||||||
python-zaqarclient>=1.0.0,<=1.2.0 # Apache Software License
|
python-zaqarclient>=1.0.0 # Apache Software License
|
||||||
python-swiftclient>=2.2.0,<=3.1.0 # Apache Software License
|
python-swiftclient>=2.2.0 # Apache Software License
|
||||||
python-watcherclient>=0.23.0,<=0.25.0 # Apache Software License
|
python-watcherclient>=0.23.0 # Apache Software License
|
||||||
python-subunit>=0.0.18,<=1.2.0
|
python-subunit>=0.0.18
|
||||||
requests>=2.10.0,<=2.11.1 # Apache License, Version 2.0
|
requests>=2.10.0 # Apache License, Version 2.0
|
||||||
# [constant-upper-limit]
|
|
||||||
SQLAlchemy>=1.0.10,<1.1.0 # MIT
|
SQLAlchemy>=1.0.10,<1.1.0 # MIT
|
||||||
# [constant-upper-limit]
|
sphinx>=1.2.1,!=1.3b1,<1.3 # BSD
|
||||||
sphinx!=1.3b1,>=1.2.1,<1.3 # BSD
|
six>=1.9.0 # MIT
|
||||||
six>=1.9.0,<=1.10.0 # MIT
|
|
||||||
|
@ -1,18 +1,21 @@
|
|||||||
# The order of packages is significant, because pip processes them in the order
|
# The order of packages is significant, because pip processes them in the order
|
||||||
# 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.
|
||||||
# [constant-upper-limit]
|
|
||||||
|
# [do-not-touch] we need to modify our code to support latest release of this
|
||||||
|
# lib
|
||||||
hacking>=0.9.2,<0.10 # Apache Software License
|
hacking>=0.9.2,<0.10 # Apache Software License
|
||||||
pytest>=2.7,<=3.0.2 # MIT
|
|
||||||
pytest-cov>=2.2.1,<=2.3.1 # MIT
|
pytest>=2.7 # MIT
|
||||||
pytest-html>=1.10.0,<=1.10.0 # Mozilla Public License 2.0 (MPL 2.0)
|
pytest-cov>=2.2.1 # MIT
|
||||||
|
pytest-html>=1.10.0 # Mozilla Public License 2.0 (MPL 2.0)
|
||||||
pytest-xdist # MIT
|
pytest-xdist # MIT
|
||||||
|
|
||||||
coverage>=3.6,<=4.2 # Apache License, Version 2.0
|
coverage>=3.6 # Apache License, Version 2.0
|
||||||
ddt>=1.0.1,<=1.1.0
|
ddt>=1.0.1
|
||||||
mock>=2.0,<=2.0.0
|
mock>=2.0
|
||||||
python-dateutil>=2.4.2,<=2.5.3 # Simplified BSD
|
python-dateutil>=2.4.2 # Simplified BSD
|
||||||
testtools>=1.4.0,<=2.2.0
|
testtools>=1.4.0
|
||||||
|
|
||||||
oslosphinx!=3.4.0,>=2.5.0,<=4.7.0 # Apache Software License
|
oslosphinx>=2.5.0,!=3.4.0 # Apache Software License
|
||||||
oslotest>=1.10.0,<=2.10.0 # Apache Software License
|
oslotest>=1.10.0 # Apache Software License
|
||||||
|
@ -43,13 +43,13 @@ RALLY_REQUIREMENTS_FILES = (
|
|||||||
"test-requirements.txt",
|
"test-requirements.txt",
|
||||||
"optional-requirements.txt"
|
"optional-requirements.txt"
|
||||||
)
|
)
|
||||||
UPPER_LIMIT_TAG = "[constant-upper-limit]"
|
DO_NOT_TOUCH_TAG = "[do-not-touch]"
|
||||||
|
|
||||||
|
|
||||||
class Comment(object):
|
class Comment(object):
|
||||||
def __init__(self, s=None):
|
def __init__(self, s=None, finished=False):
|
||||||
self._comments = []
|
self._comments = []
|
||||||
self.is_finished = False
|
self.is_finished = finished
|
||||||
if s:
|
if s:
|
||||||
self.append(s)
|
self.append(s)
|
||||||
|
|
||||||
@ -82,7 +82,7 @@ class Requirement(object):
|
|||||||
self.version = version
|
self.version = version
|
||||||
self._license = None
|
self._license = None
|
||||||
self._pypy_info = None
|
self._pypy_info = None
|
||||||
self.upper_limit_flag = False
|
self.do_not_touch = False
|
||||||
|
|
||||||
def sync_max_version_with_pypy(self):
|
def sync_max_version_with_pypy(self):
|
||||||
if isinstance(self.version, dict) and not self.upper_limit_flag:
|
if isinstance(self.version, dict) and not self.upper_limit_flag:
|
||||||
@ -151,26 +151,41 @@ class Requirement(object):
|
|||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
if isinstance(self.version, dict):
|
if isinstance(self.version, dict):
|
||||||
version = ""
|
version = []
|
||||||
if self.version["ne"]:
|
|
||||||
version += ",".join(self.version["ne"])
|
min_equal_to_max = False
|
||||||
if self.version["min"]:
|
if self.version["min"] and self.version["max"]:
|
||||||
if version:
|
if (self.version["min"].startswith(">=") and
|
||||||
version += ","
|
self.version["max"].startswith("<=") and
|
||||||
version += self.version["min"]
|
self.version["min"][2:] == self.version["max"][2:]):
|
||||||
if self.version["max"]:
|
# min and max versions are equal there is no need to write
|
||||||
if version:
|
# both of them
|
||||||
version += ","
|
min_equal_to_max = True
|
||||||
version += self.version["max"]
|
version.append("==%s" % self.version["min"][2:])
|
||||||
|
|
||||||
|
if not min_equal_to_max and self.version["min"]:
|
||||||
|
version.append(self.version["min"])
|
||||||
|
|
||||||
|
if not min_equal_to_max and self.version["ne"]:
|
||||||
|
version.extend(self.version["ne"])
|
||||||
|
|
||||||
|
if not min_equal_to_max and self.version["max"]:
|
||||||
|
version.append(self.version["max"])
|
||||||
|
|
||||||
|
version = ",".join(version)
|
||||||
else:
|
else:
|
||||||
version = self.version
|
if self.do_not_touch:
|
||||||
|
version = self.version
|
||||||
|
else:
|
||||||
|
# remove const version
|
||||||
|
version = ">=%s" % self.version[2:]
|
||||||
|
|
||||||
string = "%s%s" % (self.package_name, version)
|
string = "%s%s" % (self.package_name, version)
|
||||||
if self.license:
|
if self.license:
|
||||||
# NOTE(andreykurilin): When I start implementation of this script,
|
# NOTE(andreykurilin): When I start implementation of this script,
|
||||||
# python-keystoneclient dependency took around ~45-55, so let's
|
# python-keystoneclient dependency string took around ~45-55
|
||||||
# use this length as indent. Feel free to modify it to lower or
|
# chars, so let's use this length as indent. Feel free to modify
|
||||||
# greater value.
|
# it to lower or greater value.
|
||||||
magic_number = 55
|
magic_number = 55
|
||||||
if len(string) < magic_number:
|
if len(string) < magic_number:
|
||||||
indent = magic_number - len(string)
|
indent = magic_number - len(string)
|
||||||
@ -195,30 +210,33 @@ def parse_data(raw_data, include_comments=True):
|
|||||||
if not include_comments:
|
if not include_comments:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
if (isinstance(requirements[-1], Comment) and
|
|
||||||
UPPER_LIMIT_TAG in line):
|
|
||||||
requirements[-1].is_finished = True
|
|
||||||
|
|
||||||
if getattr(requirements[-1], "is_finished", True):
|
if getattr(requirements[-1], "is_finished", True):
|
||||||
requirements.append(Comment())
|
requirements.append(Comment())
|
||||||
|
|
||||||
requirements[-1].append(line)
|
requirements[-1].append(line)
|
||||||
|
elif line == "":
|
||||||
|
# just empty line
|
||||||
|
if isinstance(requirements[-1], Comment):
|
||||||
|
requirements[-1].finish_him()
|
||||||
|
requirements.append(Comment(finished=True))
|
||||||
else:
|
else:
|
||||||
if (isinstance(requirements[-1], Comment) and
|
if (isinstance(requirements[-1], Comment) and
|
||||||
not requirements[-1].is_finished):
|
not requirements[-1].is_finished):
|
||||||
requirements[-1].finish_him()
|
requirements[-1].finish_him()
|
||||||
if line == "":
|
# parse_line
|
||||||
requirements.append("")
|
req = Requirement.parse_line(line)
|
||||||
else:
|
if req:
|
||||||
# parse_line
|
if (isinstance(requirements[-1], Comment) and
|
||||||
req = Requirement.parse_line(line)
|
DO_NOT_TOUCH_TAG in str(requirements[-1])):
|
||||||
if req:
|
req.do_not_touch = True
|
||||||
if (isinstance(requirements[-1], Comment) and
|
requirements.append(req)
|
||||||
str(requirements[-1]).endswith(UPPER_LIMIT_TAG)):
|
for i in range(len(requirements) - 1, 0, -1):
|
||||||
req.upper_limit_flag = True
|
# remove empty lines at the end of file
|
||||||
requirements.append(req)
|
if isinstance(requirements[i], Comment):
|
||||||
if not requirements[-1]:
|
if str(requirements[i]) == "":
|
||||||
requirements.pop()
|
requirements.pop(i)
|
||||||
|
else:
|
||||||
|
break
|
||||||
return requirements[1:]
|
return requirements[1:]
|
||||||
|
|
||||||
|
|
||||||
@ -264,12 +282,14 @@ def _sync():
|
|||||||
gr = parse_data(raw_gr, include_comments=False)
|
gr = parse_data(raw_gr, include_comments=False)
|
||||||
for filename, requirements in _read_requirements():
|
for filename, requirements in _read_requirements():
|
||||||
for i in range(0, len(requirements)):
|
for i in range(0, len(requirements)):
|
||||||
if isinstance(requirements[i], Requirement):
|
if (isinstance(requirements[i], Requirement) and
|
||||||
|
not requirements[i].do_not_touch):
|
||||||
try:
|
try:
|
||||||
gr_item = gr[gr.index(requirements[i])]
|
gr_item = gr[gr.index(requirements[i])]
|
||||||
except ValueError:
|
except ValueError:
|
||||||
# it not g-r requirements
|
# it not g-r requirements
|
||||||
pass
|
if isinstance(requirements[i].version, dict):
|
||||||
|
requirements[i].version["max"] = None
|
||||||
else:
|
else:
|
||||||
requirements[i].version = gr_item.version
|
requirements[i].version = gr_item.version
|
||||||
yield filename, requirements
|
yield filename, requirements
|
||||||
@ -293,7 +313,8 @@ def add_uppers():
|
|||||||
LOG.info("Obtaining latest versions of packages from %s." % filename)
|
LOG.info("Obtaining latest versions of packages from %s." % filename)
|
||||||
for req in requirements:
|
for req in requirements:
|
||||||
if isinstance(req, Requirement):
|
if isinstance(req, Requirement):
|
||||||
req.sync_max_version_with_pypy()
|
if isinstance(req.version, dict) and not req.version["max"]:
|
||||||
|
req.sync_max_version_with_pypy()
|
||||||
_write_requirements(filename, requirements)
|
_write_requirements(filename, requirements)
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user