summaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorYang Yu <Gabriel.yuyang@huawei.com>2018-03-14 17:07:47 +0800
committerYang Yu <Gabriel.yuyang@huawei.com>2018-03-14 17:07:47 +0800
commit9400c02df69737daf14644d1113ac9c1173fa70a (patch)
tree56101c2497a3aa312b6f7e79a5c86c4578483e7e /utils
parent75bf3ebba105798ce450b321a5d770fcee985896 (diff)
bugfix: stress ping for offline support
JIRA: BOTTLENECK-226 See above Change-Id: Iba5d21348355a80d6c17deb1a12114d1d07e5c15 Signed-off-by: Yang Yu <Gabriel.yuyang@huawei.com>
Diffstat (limited to 'utils')
-rw-r--r--utils/env_prepare/stack_prepare.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/utils/env_prepare/stack_prepare.py b/utils/env_prepare/stack_prepare.py
index c1ac395a..6b9bc510 100644
--- a/utils/env_prepare/stack_prepare.py
+++ b/utils/env_prepare/stack_prepare.py
@@ -75,7 +75,13 @@ def _source_file(rc_file):
shell=True)
output = p.communicate()[0]
output_lines = output.splitlines()
- env = dict((line.split('=', 1) for line in output_lines))
+ env = list()
+ for line in output_lines:
+ if '=' in line:
+ env.append(tuple(line.split('=', 1)))
+
+ env = dict(env)
+# env = dict((line.split('=', 1) for line in output_lines))
os.environ.update(env)
return env