summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorottero <rodrigo.ottero@est.tech>2019-06-06 13:46:11 +0000
committerottero <rodrigo.ottero@est.tech>2019-06-06 13:46:11 +0000
commitbe4979c8ebd5e9df53b59dbca32d9703794fc500 (patch)
tree96cc967ac2300664a0c6b8a748cba2d76006bef5
parent184c1b55dd7bd01b2d2033ce960cb7179f0ca33c (diff)
Fixing restconf_client.py script
The restconf_client.py script uses BlueprintWebClientService to send REST requests to ODL. When the methods of that interface have the type of the returns changed from String to WebClientResponse, the script stopped working. This fix changes the way the response is manipulated, to act upon a WebClientResponse and not on a String Change-Id: I3876c5b27d65058f0b5b77da17f9225fc04779c6 Issue-ID: CCSDK-1384 Signed-off-by: ottero <rodrigo.ottero@est.tech>
-rw-r--r--components/scripts/python/ccsdk_restconf/restconf_client.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/components/scripts/python/ccsdk_restconf/restconf_client.py b/components/scripts/python/ccsdk_restconf/restconf_client.py
index 92069c571..6d18b03c5 100644
--- a/components/scripts/python/ccsdk_restconf/restconf_client.py
+++ b/components/scripts/python/ccsdk_restconf/restconf_client.py
@@ -47,7 +47,7 @@ class RestconfClient:
expected_result = '"netconf-node-topology:connection-status":"connected"'
while counter < self.__odl_status_check_limit:
result = web_client_service.exchangeResource("GET", url, "")
- if expected_result in result:
+ if expected_result in result.body:
self.__log.info("NF was mounted successfully on ODL")
return None
sleep(self.__odl_status_check_pause)