From 34d600edff2b60905104aecf1cfd7fe59f9aa697 Mon Sep 17 00:00:00 2001 From: Adrian Dudau Date: Wed, 31 May 2017 14:02:41 +0200 Subject: python-keystoneclient: Uprev to 3.5.1 This is used by latest stable/newton Drop memory leak patch, has been fixed in the new version. keystone.bash_completion has been removed in the newer version, so drop support for it from the recipe. Signed-off-by: Adrian Dudau --- .../fix_keystoneclient_memory_leak.patch | 37 ---------------------- .../python/python-keystoneclient_git.bb | 18 +++-------- 2 files changed, 5 insertions(+), 50 deletions(-) delete mode 100644 meta-openstack/recipes-devtools/python/python-keystoneclient/fix_keystoneclient_memory_leak.patch (limited to 'meta-openstack/recipes-devtools/python') diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient/fix_keystoneclient_memory_leak.patch b/meta-openstack/recipes-devtools/python/python-keystoneclient/fix_keystoneclient_memory_leak.patch deleted file mode 100644 index 05a1d23..0000000 --- a/meta-openstack/recipes-devtools/python/python-keystoneclient/fix_keystoneclient_memory_leak.patch +++ /dev/null @@ -1,37 +0,0 @@ ---- - keystoneclient/openstack/common/apiclient/client.py | 10 ++++++++++ - 1 file changed, 10 insertions(+) - ---- a/keystoneclient/openstack/common/apiclient/client.py -+++ b/keystoneclient/openstack/common/apiclient/client.py -@@ -90,6 +90,7 @@ - self.user_agent = user_agent or self.user_agent - - self.times = [] # [("item", starttime, endtime), ...] -+ self.times_max_len = 200 - self.timings = timings - - # requests within the same session can reuse TCP connections from pool -@@ -142,6 +143,12 @@ - def reset_timings(self): - self.times = [] - -+ def get_timings_max_len(self): -+ return self.times_max_len -+ -+ def set_timings_max_len(self, new_len): -+ self.times_max_len = new_len -+ - def request(self, method, url, **kwargs): - """Send an http request with the specified characteristics. - -@@ -173,6 +180,9 @@ - if self.timings: - self.times.append(("%s %s" % (method, url), - start_time, time.time())) -+ # remove oldest items until we maintain max length -+ while len(self.times) > self.times_max_len: -+ del self.times[0] - self._http_log_resp(resp) - - if resp.status_code >= 400: diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb index 0b67e40..1c1d4ec 100644 --- a/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb @@ -7,18 +7,17 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=4a4d0e932ffae1c0131528d30d419c55" SRCNAME = "keystoneclient" SRC_URI = "\ - git://github.com/openstack/python-keystoneclient.git;branch=master \ - file://fix_keystoneclient_memory_leak.patch \ + git://github.com/openstack/python-keystoneclient.git;branch=stable/newton \ file://keystone-api-check.sh \ " -PV = "1.7.1+git${SRCPV}" -SRCREV = "28138b588224c6b0503620ac2e24bd37dad25370" +PV = "3.5.1+git${SRCPV}" +SRCREV = "7c40ff8466dc5e49f93752ecb998db864f8e5598" S = "${WORKDIR}/git" inherit setuptools monitor rmargparse -FILES_${PN}-doc += "${datadir}/keystoneclient" +FILES_${PN}-doc += "${datadir}/keystoneclient" DEPENDS += " \ python-pip \ @@ -41,18 +40,11 @@ RDEPENDS_${PN} += " \ python-argparse \ " -PACKAGECONFIG ?= "bash-completion" -PACKAGECONFIG[bash-completion] = ",,bash-completion,bash-completion ${BPN}-bash-completion" - do_install_append() { - install -d ${D}/${sysconfdir}/bash_completion.d - install -m 664 ${S}/tools/keystone.bash_completion ${D}/${sysconfdir}/bash_completion.d - cp -r ${S}/examples ${D}${PYTHON_SITEPACKAGES_DIR}/${SRCNAME} } -PACKAGES =+ " ${SRCNAME}-tests ${BPN}-bash-completion" -FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" +PACKAGES =+ " ${SRCNAME}-tests" FILES_${SRCNAME}-tests = "${PYTHON_SITEPACKAGES_DIR}/${SRCNAME}/examples \ " -- cgit v1.2.3-54-g00ecf