From 78c0502f5935ae575d0d89d201c1de83afd05fae Mon Sep 17 00:00:00 2001 From: Yaroslav Brustinov Date: Sun, 5 Feb 2017 10:03:25 +0200 Subject: trex_daemon_server: check ZMQ port matches between the server and TRex platform config file. Change-Id: I1a6d6dc45513e4ba5f7c50f11f4730c8996c7731 Signed-off-by: Yaroslav Brustinov --- .../trex_control_plane/client_utils/external_packages.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'scripts/automation/trex_control_plane/client_utils') diff --git a/scripts/automation/trex_control_plane/client_utils/external_packages.py b/scripts/automation/trex_control_plane/client_utils/external_packages.py index 049cc59c..ac181aba 100644 --- a/scripts/automation/trex_control_plane/client_utils/external_packages.py +++ b/scripts/automation/trex_control_plane/client_utils/external_packages.py @@ -11,9 +11,9 @@ CURRENT_PATH = os.path.dirname(os.path.realpath(__file__)) ROOT_PATH = os.path.abspath(os.path.join(CURRENT_PATH, os.pardir)) # path to trex_control_plane directory PATH_TO_PYTHON_LIB = os.path.abspath(os.path.join(ROOT_PATH, os.pardir, os.pardir, 'external_libs')) ZMQ_PATH = os.path.abspath(os.path.join(PATH_TO_PYTHON_LIB, 'pyzmq-14.5.0', python_ver, ucs_ver, '64bit')) +YAML_PATH = os.path.abspath(os.path.join(PATH_TO_PYTHON_LIB, 'pyyaml-3.11', python_ver)) CLIENT_UTILS_MODULES = ['dpkt-1.8.6', - 'yaml-3.11', 'texttable-0.8.4', 'scapy-2.3.1' 'zmq', @@ -25,11 +25,9 @@ def import_client_utils_modules(): if PATH_TO_PYTHON_LIB not in sys.path: sys.path.insert(0, PATH_TO_PYTHON_LIB) - if ROOT_PATH not in sys.path: - sys.path.append(ROOT_PATH) - - if ZMQ_PATH not in sys.path: - sys.path.append(ZMQ_PATH) + for path in (ROOT_PATH, ZMQ_PATH, YAML_PATH): + if path not in sys.path: + sys.path.append(path) import_module_list(CLIENT_UTILS_MODULES) -- cgit 1.2.3-korg