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/2002-June/024957.html below:

[Python-Dev] Draft Guide for code migration and modernation

[Python-Dev] Draft Guide for code migration and modernation [Python-Dev] Draft Guide for code migration and modernationGuido van Rossum guido@python.org
Mon, 03 Jun 2002 15:42:49 -0400
> Pattern:  NewError = 'NewError' --> class NewError(Exception): pass
> Idea:     String exceptions are deprecated, derive from Exception base class.
> Version:  Any
> Benefits: String exceptions will not work in future versions.  Allows except Exception: clause to work.
> Locating: Use PyChecker

Should also warn against class exceptions not deriving from Exception.

Be careful about generic phrases like "String exceptions will not work
in future versions."  Some people (especially those who tend to fear
change ;-) start to panic when they read this, thinking it might be in
2.4.  I don't think we'll be able to delete string exceptions before
Python 3.0, so you can be explicit in this case.

--Guido van Rossum (home page: http://www.python.org/~guido/)




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