Welcome to getpython3.com - this site aims to be a resource for Python 3 for developers. This includes guides, videos, tutorials and other resources to help you and your team achieve a successful Python 3 port of your application, library, framework or tool. Also included is information on Python Software Foundation financial grants for porting to Python 3, other significant projects working on Python 3, as well as potential information on companies willing to fund or provide grants for Python 3 porting.
What is Python 3?
Short version: Although most Python code is written for Python 2.x, Python 3.x is the present and future of the language.
At the time of writing (Sept 28, 2011), the final 2.7 release is out, with a statement of extended support for this end-of-life release. The 2.x branch will see no new major releases after that. 3.x is under active development and has already seen stable releases, such as the recent 3.2. This means that all recent standard library improvements, for example, are only available in Python 3.x.
Guido van Rossum (the original creator of the Python language), in conjunction with other python-core developers decided to clean up Python 2.x properly, with less regard for backwards compatibility than is the case for new releases in the 2.x range. The most drastic improvement is the better unicode support (with all text strings being unicode by default) as well as saner bytes/unicode separation.
Besides, several aspects of the core language (such as print and exec being statements, integers using floor division) have been adjusted to be easier for newcomers to learn and to be more consistent with the rest of the language, and old cruft has been removed (for example, all classes are now new-style, range() returns a memory efficient iterable, not a list as in 2.x).
The What's New in Python 3.0 document provides a good overview of the major language changes and likely sources of incompatibility with existing Python 2.x code.
Cribbed from Python2orPython3 on the Python wiki.
The most current version of Python 3 is 3.2.2 - here's a list of new things:
- numerous improvements to the unittest module
- PEP 3147, support for .pyc repository directories
- PEP 3149, support for version tagged dynamic libraries
- PEP 3148, a new futures library for concurrent programming
- PEP 384, a stable ABI for extension modules
- PEP 391, dictionary-based logging configuration
- an overhauled GIL implementation that reduces contention
- an extended email package that handles bytes messages
- a much improved ssl module with support for SSL contexts and certificate hostname matching
- a sysconfig module to access configuration information
- additions to the shutil module, among them archive file support
- many enhancements to configparser, among them mapping protocol support
- improvements to pdb, the Python debugger
- countless fixes regarding bytes/string issues; among them full support for a bytes environment (filenames, environment variables)
- many consistency and behavior fixes for numeric operations
You can see details on what's changed by looking at the "What's New in 3.2" document as well as "What's New in 3.0", and the change log. Builds are available for all major platforms, and OS X users can use homebrew via "brew install python3"
The follow libraries/projects and frameworks are notable additions to the Python 3 ecosystem. Some of these represent entire frameworks, while others are major dependencies for other projects and tools:
- Pyramid 1.3a1
- Django (Development Branch)
- Mako Templates
In short: yes - there's a bevy of information, videos and blog posts out there that can help you on your way. Python 3 is the future of the Python language, and entities such as the Python Software Foundation strongly believe in supporting the porting effort.
For example, the Python Software Foundation has issued developer grants to port projects such as the email package, PyOpenSSL, and WebOb. It has also provided developer grants for other general Python development work, such as to Brett Cannon that allowed him to completely revamp the Python developer's guide.
The Python Software Foundation is here for not just CPython, or python-core, or python-the-language. It is here for Python - the community, it's efforts, its developers, designers and people.
How to find projects
If you are looking to help - but are not the maintainer of a module, library, etc there are various ways you can help. For example, see Brett Cannon's "Python 3 Support on PyPI" site, that lists out various projects that support, or do not support Python 3. You can always find some project there, or elsewhere that can use assistance in porting.
Additionally, there are threads and sites out there (such as Tarek's post on google+) where people have come out and voted for libraries they need ported to Python 3 so they can in turn make the transition.
There is a wealth of information out there on Porting to, and about Python 3. There is an entire mailing list (python-porting) dedicated to helping people port things to Python 3 - developers experienced in porting should join up, and there is already a good team there to help support you.
Guides, cheat sheets and tutorials:
Posts & links from the community:
- Porting to Python 3 — A Guide
- Lessons Learned Porting Dateutil to Python 3
- zzzeek's Guide to Python 3 Porting
- Alexandre Vassalotti: Porting your code to Python 3
- Michael Foord: Porting Mock to Python 3
- Jannis Leidel: Python 3 and You
- David Beazley: Porting Py65 (and my Superboard) to Python 3
- New! Nick Coghlan Python 3 and ASCII Compatible Binary Protocols
- New! Lessons in porting to Python 3