Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #53025

Re: Missing something on exception handling in Python 3

Path csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <skip.montanaro@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.019
X-Spam-Evidence '*H*': 0.96; '*S*': 0.00; 'subject:Python': 0.06; '%s"': 0.09; 'subject:exception': 0.16; 'subject:handling': 0.16; 'thanks.': 0.20; '2.x': 0.24; 'skip': 0.24; 'this:': 0.26; 'header :In-Reply-To:1': 0.27; 'raise': 0.29; 'message- id:@mail.gmail.com': 0.30; 'received:google.com': 0.35; 'there': 0.35; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=TlHwYkpR0+HhShr+AcIgtpAlUNRsjdiGRV3gBgdrIl4=; b=GM5xGybK4BiWroWj9HP4f4Eesu2Hsr+CSW1V4T6HMR6JJJd09QsA2EcOZW8QymPpZZ ZzYEDD8qrfjDe2mgpAJm3Ns7lnR8Vocyu4OEecHO2r0s7aHiN7T/PMdjjptyhlKc/PWs OvDOObao2pX/9MvBK4glxnKHA+Dtla3apOkUCLzJMNQKYkhwV6VNRjfzbgX9P0ocCPhv zQBG6StMrurYXBx6H1XuFsa3WaoiB/tvefbd3fKRo1blRz9fJPYyvdlqDVA7cV5axD/5 refEGMmlo8vcjoRANIwzCZtxy6w5kVMOz0RFfUjnnWiHBBOLS2JVrG0HhuYnmZ8kyY1d RWeQ==
MIME-Version 1.0
X-Received by 10.58.201.227 with SMTP id kd3mr18279942vec.14.1377571779202; Mon, 26 Aug 2013 19:49:39 -0700 (PDT)
In-Reply-To <521C0B62.1030004@mrabarnett.plus.com>
References <CANc-5Uztbwz5cYk6K8vdLdjaFSPOO4qmROvPoUqfGFCnW6JVqA@mail.gmail.com> <521C0B62.1030004@mrabarnett.plus.com>
Date Mon, 26 Aug 2013 21:49:39 -0500
Subject Re: Missing something on exception handling in Python 3
From Skip Montanaro <skip.montanaro@gmail.com>
To Python <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.252.1377571787.19984.python-list@python.org> (permalink)
Lines 7
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1377571787 news.xs4all.nl 15885 [2001:888:2000:d::a6]:42832
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:53025

Show key headers only | View raw


> Do this:
>
>     raise LockFailed("Failed to create %s" % self.path) from None

Thanks. Is there some construct which will work in 2.x and 3.x?

Skip

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Missing something on exception handling in Python 3 Skip Montanaro <skip.montanaro@gmail.com> - 2013-08-26 21:49 -0500

csiph-web