Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id E74ECE00C7C; Fri, 16 Sep 2016 07:12:36 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [185.38.180.37 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from smtp-out10.electric.net (smtp-out10.electric.net [185.38.180.37]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id B575BE00BC1 for ; Fri, 16 Sep 2016 07:12:32 -0700 (PDT) Received: from 1bktsT-0000Bh-V6 by out10d.electric.net with emc1-ok (Exim 4.87) (envelope-from ) id 1bktsU-0000Ch-UR for meta-virtualization@yoctoproject.org; Fri, 16 Sep 2016 07:12:30 -0700 Received: by emcmailer; Fri, 16 Sep 2016 07:12:30 -0700 Received: from [192.36.1.72] (helo=mx-3.enea.com) by out10d.electric.net with esmtps (TLSv1:AES128-SHA:128) (Exim 4.87) (envelope-from ) id 1bktsT-0000Bh-V6 for meta-virtualization@yoctoproject.org; Fri, 16 Sep 2016 07:12:29 -0700 Received: from sestofb11.enea.se (172.21.3.152) by smtp.enea.com (172.21.1.208) with Microsoft SMTP Server id 14.3.294.0; Fri, 16 Sep 2016 16:12:29 +0200 Received: by sestofb11.enea.se (Postfix, from userid 4451) id 4F6AD441B91; Fri, 16 Sep 2016 16:12:29 +0200 (CEST) From: Adrian Dudau To: Date: Fri, 16 Sep 2016 16:12:29 +0200 Message-ID: <1474035149-23539-1-git-send-email-adrian.dudau@enea.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 Received-SPF: None (SESTOEX08.enea.se: adrian.dudau@enea.com does not designate permitted sender hosts) X-Outbound-IP: 192.36.1.72 X-Env-From: Adrian.Dudau@enea.com X-Proto: esmtps X-Revdns: mx-3.enea.com X-HELO: mx-3.enea.com X-TLS: TLSv1:AES128-SHA:128 X-Authenticated_ID: X-PolicySMART: 6551647 X-Virus-Status: Scanned by VirusSMART (c) X-Virus-Status: Scanned by VirusSMART (s) Subject: [meta-cloud-services][PATCH] openstackchef_inc.bbclass: Update python synthax for except X-BeenThere: meta-virtualization@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Discussion of layer enabling hypervisor, virtualization tool stack, and cloud support" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Sep 2016 14:12:36 -0000 Content-Type: text/plain The synthax used is deprecated and causes errors. Signed-off-by: Adrian Dudau --- meta-openstack/classes/openstackchef_inc.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta-openstack/classes/openstackchef_inc.bbclass b/meta-openstack/classes/openstackchef_inc.bbclass index b8757be..048fce6 100644 --- a/meta-openstack/classes/openstackchef_inc.bbclass +++ b/meta-openstack/classes/openstackchef_inc.bbclass @@ -248,7 +248,7 @@ def deploychef_make_startup_shutdown_list(d): raise bb.build.FuncFailed(msg) hStartup.close() hShutdown.close() - except IOError, e: + except IOError as e: bb.error("Error opening startup/shutdown files %s %s, %s %s" % \ (startup_file, shutdown_file, d.getVar('FILE'), e)) else: @@ -381,7 +381,7 @@ def deploychef_make_templates( d, conf_tuple=tuple()): deploychef_make_substitutions(d, sub_dict, attr_file, file_name) else: bb.build.FuncFailed(msg) - except IOError, e: + except IOError as e: bb.error("Could not write to attribute file %s: in %s, %s" % \ (attr_file, d.getVar('FILE'), e)) -- 1.9.1