summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhongyuzhao <zhao.hongyu@zte.com.cn>2019-07-05 17:30:11 +0800
committerhongyuzhao <zhao.hongyu@zte.com.cn>2019-07-05 17:34:22 +0800
commitd36b8189117b5b6832460bc8ae413242ce4c107f (patch)
tree5150df9134217d973dd305d960a4e1aa21ec4e3a
parent6a8c7b1a05e4796dc83b4c820dac2382a9e639d0 (diff)
vnflcm upgrade from python2 to python3
Change-Id: Iac483f3047f56af4b77ce0a111de329309d12ae9 Issue-ID: VFC-1429 Signed-off-by: hongyuzhao <zhao.hongyu@zte.com.cn>
-rwxr-xr-xlcm/docker/docker-env-conf.sh2
-rw-r--r--lcm/lcm/pub/utils/notificationsutil.py2
-rw-r--r--lcm/lcm/pub/vimapi/adaptor.py2
3 files changed, 3 insertions, 3 deletions
diff --git a/lcm/docker/docker-env-conf.sh b/lcm/docker/docker-env-conf.sh
index 5b32f3e8..8eb40c06 100755
--- a/lcm/docker/docker-env-conf.sh
+++ b/lcm/docker/docker-env-conf.sh
@@ -4,7 +4,7 @@ install_sf(){
apk --no-cache update
apk --no-cache add bash curl gcc wget mysql-client openssl-dev
- apk --no-cache add libffi-dev musl-dev py3-virtualenv
+ apk --no-cache add python3-dev libffi-dev musl-dev py3-virtualenv
# get binary zip from nexus - vfc-nfvo-catalog
wget -q -O vfc-gvnfm-vnflcm-lcm.zip "https://nexus.onap.org/service/local/artifact/maven/redirect?r=snapshots&g=org.onap.vfc.gvnfm.vnflcm.lcm&a=vfc-gvnfm-vnflcm-lcm&v=${pkg_version}-SNAPSHOT&e=zip" && \
diff --git a/lcm/lcm/pub/utils/notificationsutil.py b/lcm/lcm/pub/utils/notificationsutil.py
index 0bb40433..2eb820fe 100644
--- a/lcm/lcm/pub/utils/notificationsutil.py
+++ b/lcm/lcm/pub/utils/notificationsutil.py
@@ -65,7 +65,7 @@ class NotificationsUtil(object):
try:
self.post_notification(callbackUri, auth_info, notification)
except Exception as e:
- logger.error("Failed to post notification: %s", e.message)
+ logger.error("Failed to post notification: %s", e.args[0])
def post_notification(self, callbackUri, auth_info, notification):
params = auth_info.get("paramsBasic", {})
diff --git a/lcm/lcm/pub/vimapi/adaptor.py b/lcm/lcm/pub/vimapi/adaptor.py
index 45cae34e..55f6d164 100644
--- a/lcm/lcm/pub/vimapi/adaptor.py
+++ b/lcm/lcm/pub/vimapi/adaptor.py
@@ -160,7 +160,7 @@ def delete_vim_res(data, do_notify):
res_del_fun(res["vim_id"], res["tenant_id"], res["res_id"])
except VimException as e:
logger.error("Failed to delete %s(%s)", res_type, res["res_id"])
- logger.error("%s:%s", e.http_code, e.message)
+ logger.error("%s:%s", e.http_code, e.args[0])
do_notify(res_type, res["res_id"])