summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAngus Salkeld <asalkeld@redhat.com>2012-11-01 20:15:02 +1100
committerAngus Salkeld <asalkeld@redhat.com>2012-11-01 20:15:02 +1100
commit6ce7b8ce6a56e600069ba8585e38095c41586d5d (patch)
treed238d6b04773c54576aa330d4df75ddb5d635ddd
parent5ea881a31173380e10ffdd6b05c02f92d9177f04 (diff)
downloadoslo-6ce7b8ce6a56e600069ba8585e38095c41586d5d.tar.gz
oslo-6ce7b8ce6a56e600069ba8585e38095c41586d5d.tar.xz
oslo-6ce7b8ce6a56e600069ba8585e38095c41586d5d.zip
Relax the update.py replace regex.
In service.py there is an import like: try: from openstack.common import rpc except: rpc = None and this currently does not get converted. The only downside is some doc strings also get converted. Change-Id: If283b50b8e889c0a1878e30cd7ff58494fabe634
-rw-r--r--update.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/update.py b/update.py
index 849c183..83f1ef5 100644
--- a/update.py
+++ b/update.py
@@ -142,8 +142,8 @@ def _copy_file(path, base, dest_dir):
shutil.copy2(path, dest)
_replace(dest,
- '^from openstack.common',
- 'from ' + base + '.openstack.common')
+ '^( *)from openstack.common',
+ r'\1from ' + base + '.openstack.common')
_replace(dest,
'\'openstack\.common',