From 6d611b7f9758b04cfe67bd9533d59044a7844bc7 Mon Sep 17 00:00:00 2001 From: Sirushti Murugesan Date: Thu, 8 Oct 2015 09:13:04 +0530 Subject: [PATCH] Merge of three backported commits for fixing liberty gate First patch description: Use LOG.error when no exception handler is used There's no need to use LOG.exception here since sys.exc_info() results in (None, None, None) and thus would effectively just be LOG.error. Also, the failure of invoking LOG.exception outside of an exception handler is due to a bug in Python3[1]. The fix for that is only available in Python3.5. [1] http://bugs.python.org/issue17911 Closes-Bug: #1482261 (cherry picked from commit f5c415accfff2ad399194b30b9408a903042f009) Second patch description: Add testresources used by oslo.db fixture If we use oslo.db fixtures, we'll need these 2 packages or the next version of oslo.db release will break us. Closes-Bug: #1503501 (cherry picked from commit a7368fb68e8c1cccbb601aa1aad444248c645c25) Third patch description: Switch to post-versioning No longer mention next version on setup.cfg on stable branch. Change-Id: Ib40c664a4f0e01cd27e1f24cfdbc9de278aece42 --- heat/engine/resource.py | 8 ++++++-- setup.cfg | 1 - test-requirements.txt | 1 + 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/heat/engine/resource.py b/heat/engine/resource.py index b7d824c39c..589ded58bc 100644 --- a/heat/engine/resource.py +++ b/heat/engine/resource.py @@ -1378,8 +1378,12 @@ class Resource(object): if not updated_ok: ex = exception.UpdateInProgress(self.name) - LOG.exception('atomic:%s engine_id:%s/%s' % ( - rs.atomic_key, rs.engine_id, engine_id)) + LOG.error(_LE( + 'Error acquiring lock for resource id:%(resource_id)s with' + 'atomic key:%(atomic_key)s,' + 'engine_id:%(rs_engine_id)s/%(engine_id)s') % { + 'resource_id': rs.id, 'atomic_key': rs.atomic_key, + 'rs_engine_id': rs.engine_id, 'engine_id': engine_id}) raise ex def _release(self, engine_id): diff --git a/setup.cfg b/setup.cfg index ccc71c28e4..67ba0b3c27 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,5 @@ [metadata] name = heat -version = 5.0.0 summary = OpenStack Orchestration description-file = README.rst diff --git a/test-requirements.txt b/test-requirements.txt index 6b71384ccd..5761ec5875 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -19,3 +19,4 @@ sphinx!=1.2.0,!=1.3b1,<1.3,>=1.1.2 testrepository>=0.0.18 testscenarios>=0.4 testtools>=1.4.0 +testresources>=0.2.4