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


Groups > comp.lang.python > #21533

Re: Raise X or Raise X()?

Path csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.044
X-Spam-Evidence '*H*': 0.91; '*S*': 0.00; 'am,': 0.12; 'exception': 0.12; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'wrote:': 0.18; 'received:209.85.210.174': 0.21; 'received:mail- iy0-f174.google.com': 0.21; 'header:In-Reply-To:1': 0.22; 'wonder': 0.23; 'responses.': 0.23; 'message-id:@mail.gmail.com': 0.29; 'yield': 0.29; 'tue,': 0.32; 'rather': 0.34; 'statement,': 0.34; 'to:addr:python-list': 0.35; 'received:google.com': 0.37; 'received:209.85': 0.38; 'received:209': 0.39; 'to:addr:python.org': 0.40; 'here': 0.64; '12:06': 0.84
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=sbv+C/4II3vpYHQ4YG3ZIunuRkJtT18GbOcyHQOS9ac=; b=VESpFFKa8+n462W2A8sNTo2d//jmkb9qTwtVI3NVTPum3GjzCmY2E2L08Bu8/MwWw8 Od/F9i8cLCfvHxMh02euJ8rEAxAmQ+cDo1WJREezSsI4e/F6rNiaFcZwoa4dyqeInpoV hIPmv95TZzqlCPalY1pK7zJyxa5UYF8IsSX/ioo59DWX9fkTQUu0xLv3UmZSTAOSzSXj v5KwfOYEGQ99S9sqWP6eEh01FAU3oIaz5T3HkFtBkaom0X+L80ienGNHBKBalWqsgfgy Te4DEkCRrEq7l+x3BK+bg2lS4g09YjGuTdT38xsKfgOhijwIcHElZDDZz80ukWQS5Lcn 0W4w==
MIME-Version 1.0
In-Reply-To <4F5DF4D8.20901@gmail.com>
References <387014.2537.1331492695725.JavaMail.geo-discussion-forums@pbjv6> <4F5DF4D8.20901@gmail.com>
Date Tue, 13 Mar 2012 00:13:57 +1100
Subject Re: Raise X or Raise X()?
From Chris Angelico <rosuav@gmail.com>
To python-list@python.org
Content-Type text/plain; charset=ISO-8859-1
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
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.586.1331558040.3037.python-list@python.org> (permalink)
Lines 7
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1331558040 news.xs4all.nl 6952 [2001:888:2000:d::a6]:44997
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:21533

Show key headers only | View raw


On Tue, Mar 13, 2012 at 12:06 AM, James Elford <fil.oracle@gmail.com> wrote:
> I wonder whether you need to use an exception here rather than a yield
> statement?

Or a return statement, if you're not needing multiple responses.

ChrisA

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


Thread

Raise X or Raise X()? bvdp <bob@mellowood.ca> - 2012-03-11 12:04 -0700
  Re: Raise X or Raise X()? Irmen de Jong <irmen.NOSPAM@xs4all.nl> - 2012-03-11 21:37 +0100
    Re: Raise X or Raise X()? Chris Rebert <clp2@rebertia.com> - 2012-03-11 14:49 -0700
    Re: Raise X or Raise X()? Stefan Behnel <stefan_ml@behnel.de> - 2012-03-12 14:52 +0100
      Re: Raise X or Raise X()? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-03-12 15:08 +0000
        Re: Raise X or Raise X()? Stefan Behnel <stefan_ml@behnel.de> - 2012-03-12 17:08 +0100
  Re: Raise X or Raise X()? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-03-11 23:59 +0000
    Re: Raise X or Raise X()? bvdp <bob@mellowood.ca> - 2012-03-11 18:53 -0700
    Re: Raise X or Raise X()? MRAB <python@mrabarnett.plus.com> - 2012-03-12 02:26 +0000
  Re: Raise X or Raise X()? Jean-Michel Pichavant <jeanmichel@sequans.com> - 2012-03-12 11:37 +0100
  Re: Raise X or Raise X()? Robert Kern <robert.kern@gmail.com> - 2012-03-12 12:47 +0000
  Re: Raise X or Raise X()? James Elford <fil.oracle@gmail.com> - 2012-03-12 13:06 +0000
  Re: Raise X or Raise X()? Chris Angelico <rosuav@gmail.com> - 2012-03-13 00:13 +1100

csiph-web