A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2009-September/092208.html below:

[Python-Dev] IO module precisions and exception hierarchy

[Python-Dev] IO module precisions and exception hierarchy [Python-Dev] IO module precisions and exception hierarchyNick Coghlan ncoghlan at gmail.com
Mon Sep 28 14:40:44 CEST 2009
Antoine Pitrou wrote:
> Le Mon, 28 Sep 2009 06:41:17 +1000, Nick Coghlan a écrit :
>> Michael's response cut to the heart of the issue though - a richer IO
>> exception hierarchy can make life interesting for compatibility purposes
>> (especially when creating "file-like" interfaces to non-file objects).
> 
> Well, not more interesting than currently where you need to replicate 
> errno numbers if you want to make the errors precise enough, since an API 
> consumer wanting to check specific error conditions will discriminate on 
> errno.
> 
> If you don't want to go to that level of perfection, you just have to 
> raise a plain IOError (or OSError :-)) without bothering about errno or 
> subclasses; like you would do today.

Fair point.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4