ASPN ActiveState Programmer Network
  ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups | Web Services
SEARCH
advanced | search help

Reference
ActivePython 2.4
What's New
What's new in Python 2.4?
Contents
1 PEP 218: Built-In Set Objects
2 PEP 237: Unifying Long Integers and Integers
3 PEP 289: Generator Expressions
4 PEP 292: Simpler String Substitutions
5 PEP 318: Decorators for Functions and Methods
6 PEP 322: Reverse Iteration
7 PEP 324: New subprocess Module
8 PEP 327: Decimal Data Type
9 PEP 328: Multi-line Imports
10 PEP 331: Locale-Independent Float/String Conversions
11 Other Language Changes
12 New, Improved, and Deprecated Modules
13 Build and C API Changes
14 Porting to Python 2.4
15 Acknowledgements
About this document ...

MyASPN >> Reference >> ActivePython 2.4 >> What's New >> What's new in Python 2.4?
ActivePython 2.4 documentation

14 Porting to Python 2.4

This section lists previously described changes that may require changes to your code:

  • Left shifts and hexadecimal/octal constants that are too large no longer trigger a FutureWarning and return a value limited to 32 or 64 bits; instead they return a long integer.

  • Integer operations will no longer trigger an OverflowWarning. The OverflowWarning warning will disappear in Python 2.5.

  • The zip() built-in function and itertools.izip() now return an empty list instead of raising a TypeError exception if called with no arguments.

  • dircache.listdir() now passes exceptions to the caller instead of returning empty lists.

  • LexicalHandler.startDTD() used to receive the public and system IDs in the wrong order. This has been corrected; applications relying on the wrong order need to be fixed.

  • fcntl.ioctl now warns if the mutate argument is omitted and relevant.

  • The tarfile module now generates GNU-format tar files by default.

  • Encountering a failure while importing a module no longer leaves a partially-initialized module object in sys.modules.

  • None is now a constant; code that binds a new value to the name "None" is now a syntax error.

See About this document... for information on suggesting changes.

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState 2004 All rights reserved