From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 83F4BA055A; Thu, 27 Feb 2020 02:29:46 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 466E31BFAB; Thu, 27 Feb 2020 02:29:46 +0100 (CET) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 57EED1BF8D for ; Thu, 27 Feb 2020 02:29:45 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Feb 2020 17:29:43 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,490,1574150400"; d="scan'208";a="261269034" Received: from dpdk-lihong-ub1604.sh.intel.com ([10.67.118.203]) by fmsmga004.fm.intel.com with ESMTP; 26 Feb 2020 17:29:42 -0800 From: lihong To: dts@dpdk.org Cc: lihong Date: Thu, 27 Feb 2020 02:00:59 +0800 Message-Id: <1582740059-13036-1-git-send-email-lihongx.ma@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [dts] [PATCH V1] framework/crb: add check key of pktgen in crb.cfg X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" Signed-off-by: lihong --- framework/crb.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/crb.py b/framework/crb.py index 2ac197e..2bf99e1 100644 --- a/framework/crb.py +++ b/framework/crb.py @@ -472,7 +472,7 @@ class Crb(object): if the tester and dut on same server and pktgen is trex, do not kill the process """ - if self.crb['pktgen'].lower() == 'trex': + if 'pktgen' in self.crb and (self.crb['pktgen'] is not None) and (self.crb['pktgen'].lower() == 'trex'): if self.crb['IP'] == self.crb['tester IP'] and self.trex_prefix is None: conf_inst = PktgenConf('trex') conf_info = conf_inst.load_pktgen_config() -- 2.7.4