Re: [Python-Dev] Exception Reorg PEP checked in

2005-09-08 Thread Wilfredo Sánchez Vega
(sorry for the delayed reply; vacation) On Aug 14, 2005, at 12:27 PM, Guido van Rossum wrote: On 8/14/05, Michael Hudson <[EMAIL PROTECTED]> wrote: Wilfredo Sánchez Vega <[EMAIL PROTECTED]> writes: I'm curious about why Python lacks FileNotFoundError, PermissionError and the like as su

Re: [Python-Dev] Exception Reorg PEP checked in

2005-09-07 Thread Wilfredo Sánchez Vega
(sorry for the delayed reply; vacation) On Aug 14, 2005, at 12:27 PM, Guido van Rossum wrote: On 8/14/05, Michael Hudson <[EMAIL PROTECTED]> wrote: Wilfredo S ánchez Vega <[EMAIL PROTECTED]> writes: I'm curious about why Python lacks FileNotFoundError, PermissionError and the li

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-14 Thread Guido van Rossum
On 8/14/05, Michael Hudson <[EMAIL PROTECTED]> wrote: > Wilfredo Sánchez Vega <[EMAIL PROTECTED]> writes: > > >I'm curious about why Python lacks FileNotFoundError, > > PermissionError and the like as subclasses of IOError. > > Good question. Lack of effort/inertia? Well, I wonder how often

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-14 Thread Michael Hudson
Wilfredo Sánchez Vega <[EMAIL PROTECTED]> writes: >I'm curious about why Python lacks FileNotFoundError, > PermissionError and the like as subclasses of IOError. Good question. Lack of effort/inertia? >Catching IOError and looking at errno to figure out what went > wrong seems prett

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-13 Thread Wilfredo Sánchez Vega
I'm curious about why Python lacks FileNotFoundError, PermissionError and the like as subclasses of IOError. Catching IOError and looking at errno to figure out what went wrong seems pretty unpythonic, and I've often wished for built-in subclasses of IOError. I sometimes subclass t

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Raymond Hettinger
> > > > >+-- NamespaceError (rename of NameError) > > > > >+-- UnboundFreeError (new) > > > > >+-- UnboundGlobalError (new) > > > > >+-- UnboundLocalError > > > > > > > > > > > > > What are these new exceptions for? Under what circumstances are they > > >

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/5/05, Raymond Hettinger <[EMAIL PROTECTED]> wrote: > > On 8/4/05, James Y Knight <[EMAIL PROTECTED]> wrote: > > > >+-- NamespaceError (rename of NameError) > > > >+-- UnboundFreeError (new) > > > >+-- UnboundGlobalError (new) > > > >+-- UnboundLocalE

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/5/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On 8/5/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > > On 8/4/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > > > > This does contradict my earlier claim that Python itself doesn't use > > > RuntimeError; I think I'd be happier if it rema

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Charles Cazabon
Brett Cannon <[EMAIL PROTECTED]> wrote: > On 8/4/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > I just realized that keeping RuntimeError still does not resolve the > issue that the name kind of sucks for realizing intrinsically that it > is for quick-and-dirty exceptions (or am I the only on

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Guido van Rossum
On 8/5/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > On 8/4/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > > This does contradict my earlier claim that Python itself doesn't use > > RuntimeError; I think I'd be happier if it remained RuntimeError. (I > > think there are a few more uses of it

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/4/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > This does contradict my earlier claim that Python itself doesn't use > RuntimeError; I think I'd be happier if it remained RuntimeError. (I > think there are a few more uses of it inside Python itself; I don't > think it's worth inventing ne

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/4/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > In general the PEP looks really good now! > Glad you like it. > On 8/4/05, Willem Broekema <[EMAIL PROTECTED]> wrote: > > On 8/4/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > > > OK, once the cron job comes around and is run, > > > http://

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/4/05, James Y Knight <[EMAIL PROTECTED]> wrote: > >+-- NamespaceError (rename of NameError) > >+-- UnboundFreeError (new) > >+-- UnboundGlobalError (new) > >+-- UnboundLocalError > > > > What are these new exceptions for? Under what circumstances ar

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/4/05, Nick Coghlan <[EMAIL PROTECTED]> wrote: > Since I forgot to mention it in the last couple of messages - this version > looks very good. The transition strategy section makes it a lot more > meaningful. > Great to hear! > Brett Cannon wrote (in the PEP): > > Renamed Exceptions > > > >

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-05 Thread Brett Cannon
On 8/4/05, Nick Coghlan <[EMAIL PROTECTED]> wrote: > Brett Cannon wrote (in the PEP): > > KeyboardInterrupt inheriting from ControlFlowException > > > > KeyboardInterrupt has been a contentious point within this hierarchy. Some > > view the exception as more control flow being caused by the user. B

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Guido van Rossum
In general the PEP looks really good now! On 8/4/05, Willem Broekema <[EMAIL PROTECTED]> wrote: > On 8/4/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > > OK, once the cron job comes around and is run, > > http://www.python.org/peps/pep-0348.html will not be a 404 but be the > > latest version of th

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread James Y Knight
>+-- NamespaceError (rename of NameError) >+-- UnboundFreeError (new) >+-- UnboundGlobalError (new) >+-- UnboundLocalError > What are these new exceptions for? Under what circumstances are they raised? Why is this necessary or an improvement? > Rename

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Willem Broekema
On 8/4/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > OK, once the cron job comes around and is run, > http://www.python.org/peps/pep-0348.html will not be a 404 but be the > latest version of the PEP. Currently, when the "recursion limit" is reached, a RuntimeError is raised. RuntimeError is in th

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread James Y Knight
On Aug 4, 2005, at 7:03 AM, Nick Coghlan wrote: > Additionally, consider that a hypothetical ThreadExit exception > (used to > terminate a thread semi-gracefully) would also clearly belong under > ControlFlowException. That is, just because something is > asynchronous with > respect to the curr

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Nick Coghlan
Since I forgot to mention it in the last couple of messages - this version looks very good. The transition strategy section makes it a lot more meaningful. Brett Cannon wrote (in the PEP): > Renamed Exceptions > > Renamed exceptions will directly subclass the new names. When the old > exceptions

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Nick Coghlan
Brett Cannon wrote (in the PEP): > KeyboardInterrupt inheriting from ControlFlowException > > KeyboardInterrupt has been a contentious point within this hierarchy. Some > view the exception as more control flow being caused by the user. But with > its asynchronous cause thanks to the user being ab

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Nick Coghlan
Nick Coghlan wrote: > If/when you add a "Getting there from here" section, it would be worth noting > that there are a few basic strategies to be applied: Eh, never mind. It's already there ;) Cheers, Nick. -- Nick Coghlan | [EMAIL PROTECTED] | Brisbane, Australia -

Re: [Python-Dev] Exception Reorg PEP checked in

2005-08-04 Thread Nick Coghlan
Brett Cannon wrote: > OK, once the cron job comes around and is run, > http://www.python.org/peps/pep-0348.html will not be a 404 but be the > latest version of the PEP. > > Differences since my last public version is that it has > BaseException/Exception as the naming hierarchy, Warning inherits

[Python-Dev] Exception Reorg PEP checked in

2005-08-03 Thread Brett Cannon
OK, once the cron job comes around and is run, http://www.python.org/peps/pep-0348.html will not be a 404 but be the latest version of the PEP. Differences since my last public version is that it has BaseException/Exception as the naming hierarchy, Warning inherits from Exception, UserException is