A RetroSearch Logo

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

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2008-July/081317.html below:

[Python-Dev] assertRaises

[Python-Dev] assertRaises [Python-Dev] assertRaisesAntoine Pitrou solipsis at pitrou.net
Thu Jul 17 11:12:59 CEST 2008
Fred Drake <fdrake <at> acm.org> writes:
> 
> Sounds like adding a new method, catchException(...), that returns the  
> exception it catches, would be a reasonable compromise.  I can't think  
> of any reason that the method that catches-and-returns needs to be the  
> existing API, which does something different.

So you'd have a method that just catches (assertRaises), and another one that 
catches-and-returns (catchException)?
It doesn't seem very practical to have two different methods based on such a 
small and trivial difference.
Let's just make assertRaises return the exception instance, it seems like it 
feels the need correctly.


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