Benjamin Peterson | a58a626 | 2009-03-07 16:34:40 +0000 | [diff] [blame^] | 1 | This is Python version 3.1 alpha 1 |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 2 | ================================== |
Guido van Rossum | 9144763 | 2000-04-11 17:11:09 +0000 | [diff] [blame] | 3 | |
Guido van Rossum | 4405cf3 | 2007-08-30 17:16:55 +0000 | [diff] [blame] | 4 | For notes specific to this release, see RELNOTES in this directory. |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 5 | Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 |
Christian Heimes | b558a2e | 2008-03-02 22:46:37 +0000 | [diff] [blame] | 6 | Python Software Foundation. |
| 7 | All rights reserved. |
Guido van Rossum | 4405cf3 | 2007-08-30 17:16:55 +0000 | [diff] [blame] | 8 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 9 | Python 3.x is a new version of the language, which is incompatible with the |
| 10 | 2.x line of releases. The language is mostly the same, but many details, |
| 11 | especially how built-in objects like dictionaries and strings work, have |
| 12 | changed considerably, and a lot of deprecated features have finally been |
| 13 | removed. |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 14 | |
| 15 | This is an ongoing project; the cleanup isn't expected to be complete |
Guido van Rossum | 99533a9 | 2007-12-06 05:07:41 +0000 | [diff] [blame] | 16 | until some time in 2008. In particular there are plans to reorganize |
| 17 | the standard library namespace. |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 18 | |
Guido van Rossum | 50e9fb9 | 2006-08-17 05:42:55 +0000 | [diff] [blame] | 19 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 20 | Release Schedule |
| 21 | ---------------- |
Guido van Rossum | 3ff96dd | 1996-07-30 18:05:04 +0000 | [diff] [blame] | 22 | |
Benjamin Peterson | a58a626 | 2009-03-07 16:34:40 +0000 | [diff] [blame^] | 23 | See PEP 375 for release details: http://www.python.org/dev/peps/pep-0375/ |
Guido van Rossum | 8d90f9d | 1997-05-22 20:13:25 +0000 | [diff] [blame] | 24 | |
Guido van Rossum | f501b4e | 1996-10-25 14:32:48 +0000 | [diff] [blame] | 25 | |
Guido van Rossum | c07d5fa | 2000-09-01 22:50:02 +0000 | [diff] [blame] | 26 | Documentation |
| 27 | ------------- |
Guido van Rossum | 91cb9d2 | 1995-04-10 11:47:38 +0000 | [diff] [blame] | 28 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 29 | Documentation for Python 3.1 is online, updated twice a day: |
Guido van Rossum | 91cb9d2 | 1995-04-10 11:47:38 +0000 | [diff] [blame] | 30 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 31 | http://docs.python.org/dev/3.1/ |
Guido van Rossum | c07d5fa | 2000-09-01 22:50:02 +0000 | [diff] [blame] | 32 | |
Benjamin Peterson | 2a691a8 | 2008-03-31 01:51:45 +0000 | [diff] [blame] | 33 | All documentation is also available online at the Python web site |
Barry Warsaw | bb5cd08 | 2008-04-02 23:33:27 +0000 | [diff] [blame] | 34 | (http://docs.python.org/, see below). It is available online for |
| 35 | occasional reference, or can be downloaded in many formats for faster |
| 36 | access. The documentation is downloadable in HTML, PostScript, PDF, |
| 37 | LaTeX (through 2.5), and reStructuredText (2.6+) formats; the LaTeX and |
| 38 | reStructuredText versions are primarily for documentation authors, |
| 39 | translators, and people with special formatting requirements. |
Benjamin Peterson | 2a691a8 | 2008-03-31 01:51:45 +0000 | [diff] [blame] | 40 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 41 | This is a work in progress; please help improve it! |
Barry Warsaw | 0655745 | 2001-12-14 20:47:12 +0000 | [diff] [blame] | 42 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 43 | The design documents for Python 3 are also online. While the reference |
| 44 | documentation is being updated, the PEPs are often the best source of |
| 45 | information about new features. Start by reading PEP 3000: |
Barry Warsaw | 0655745 | 2001-12-14 20:47:12 +0000 | [diff] [blame] | 46 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 47 | http://python.org/dev/peps/pep-3000/ |
Guido van Rossum | c07d5fa | 2000-09-01 22:50:02 +0000 | [diff] [blame] | 48 | |
Guido van Rossum | c07d5fa | 2000-09-01 22:50:02 +0000 | [diff] [blame] | 49 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 50 | What's New |
Guido van Rossum | 91cb9d2 | 1995-04-10 11:47:38 +0000 | [diff] [blame] | 51 | ---------- |
| 52 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 53 | For an overview of what's new in Python 3, see Guido van Rossum's blog at |
| 54 | artima.com: |
Guido van Rossum | 6477380 | 1997-11-26 17:07:02 +0000 | [diff] [blame] | 55 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 56 | http://www.artima.com/weblogs/index.jsp?blogger=guido |
Guido van Rossum | 6477380 | 1997-11-26 17:07:02 +0000 | [diff] [blame] | 57 | |
Georg Brandl | f3f67f2 | 2008-02-22 14:22:51 +0000 | [diff] [blame] | 58 | We try to eventually have a comprehensive overview of the changes in |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 59 | the "What's New in Python 3.1" document, found at |
Georg Brandl | f3f67f2 | 2008-02-22 14:22:51 +0000 | [diff] [blame] | 60 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 61 | http://docs.python.org/dev/3.1/whatsnew/3.1 |
Georg Brandl | f3f67f2 | 2008-02-22 14:22:51 +0000 | [diff] [blame] | 62 | |
| 63 | Please help write it! |
Jack Jansen | a39ef86 | 2001-08-19 21:17:03 +0000 | [diff] [blame] | 64 | |
Guido van Rossum | 99533a9 | 2007-12-06 05:07:41 +0000 | [diff] [blame] | 65 | For a more detailed change log, read Misc/NEWS (though this file, too, |
| 66 | is incomplete, and also doesn't list anything merged in from the 2.6 |
| 67 | release under development). |
| 68 | |
Barry Warsaw | 160b9a3 | 2008-05-08 11:54:13 +0000 | [diff] [blame] | 69 | If you want to install multiple versions of Python see the section below |
| 70 | entitled "Installing multiple versions". |
| 71 | |
| 72 | |
Benjamin Peterson | 2a691a8 | 2008-03-31 01:51:45 +0000 | [diff] [blame] | 73 | Proposals for enhancement |
Barry Warsaw | bb5cd08 | 2008-04-02 23:33:27 +0000 | [diff] [blame] | 74 | ------------------------- |
Benjamin Peterson | 2a691a8 | 2008-03-31 01:51:45 +0000 | [diff] [blame] | 75 | |
Benjamin Peterson | ad9d48d | 2008-04-02 21:49:44 +0000 | [diff] [blame] | 76 | If you have a proposal to change Python, you may want to send an email to the |
| 77 | comp.lang.python or python-ideas mailing lists for inital feedback. A Python |
| 78 | Enhancement Proposal (PEP) may be submitted if your idea gains ground. All |
| 79 | current PEPs, as well as guidelines for submitting a new PEP, are listed at |
| 80 | http://www.python.org/dev/peps/. |
Guido van Rossum | 99533a9 | 2007-12-06 05:07:41 +0000 | [diff] [blame] | 81 | |
Barry Warsaw | 160b9a3 | 2008-05-08 11:54:13 +0000 | [diff] [blame] | 82 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 83 | Converting From Python 2.x to 3.x |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 84 | --------------------------------- |
Guido van Rossum | 433c8ad | 1994-08-01 12:07:07 +0000 | [diff] [blame] | 85 | |
Barry Warsaw | 97f005d | 2008-12-03 16:46:14 +0000 | [diff] [blame] | 86 | Python starting with 2.6 will contain features to help locating code that |
| 87 | needs to be changed, such as optional warnings when deprecated features are |
| 88 | used, and backported versions of certain key Python 3.x features. |
Guido van Rossum | 433c8ad | 1994-08-01 12:07:07 +0000 | [diff] [blame] | 89 | |
Christian Heimes | dd15f6c | 2008-03-16 00:07:10 +0000 | [diff] [blame] | 90 | |
Benjamin Peterson | ad3d5c2 | 2009-02-26 03:38:59 +0000 | [diff] [blame] | 91 | Testing |
| 92 | ------- |
| 93 | |
| 94 | To test the interpreter, type "make test" in the top-level directory. |
| 95 | This runs the test set twice (once with no compiled files, once with |
| 96 | the compiled files left by the previous test run). The test set |
| 97 | produces some output. You can generally ignore the messages about |
| 98 | skipped tests due to optional features which can't be imported. |
| 99 | If a message is printed about a failed test or a traceback or core |
| 100 | dump is produced, something is wrong. On some Linux systems (those |
| 101 | that are not yet using glibc 6), test_strftime fails due to a |
| 102 | non-standard implementation of strftime() in the C library. Please |
| 103 | ignore this, or upgrade to glibc version 6. |
| 104 | |
| 105 | By default, tests are prevented from overusing resources like disk space and |
| 106 | memory. To enable these tests, run "make testall". |
| 107 | |
| 108 | IMPORTANT: If the tests fail and you decide to mail a bug report, |
| 109 | *don't* include the output of "make test". It is useless. Run the |
| 110 | failing test manually, as follows: |
| 111 | |
| 112 | ./python Lib/test/regrtest.py -v test_whatever |
| 113 | |
| 114 | (substituting the top of the source tree for '.' if you built in a |
| 115 | different directory). This runs the test in verbose mode. |
| 116 | |
| 117 | |
Christian Heimes | dd15f6c | 2008-03-16 00:07:10 +0000 | [diff] [blame] | 118 | Installing multiple versions |
| 119 | ---------------------------- |
| 120 | |
| 121 | On Unix and Mac systems if you intend to install multiple versions of Python |
| 122 | using the same installation prefix (--prefix argument to the configure |
| 123 | script) you must take care that your primary python executable is not |
| 124 | overwritten by the installation of a different versio. All files and |
| 125 | directories installed using "make altinstall" contain the major and minor |
| 126 | version and can thus live side-by-side. "make install" also creates |
| 127 | ${prefix}/bin/python which refers to ${prefix}/bin/pythonX.Y. If you intend |
| 128 | to install multiple versions using the same prefix you must decide which |
| 129 | version (if any) is your "primary" version. Install that version using |
| 130 | "make install". Install all other versions using "make altinstall". |
| 131 | |
| 132 | For example, if you want to install Python 2.5, 2.6 and 3.0 with 2.6 being |
| 133 | the primary version, you would execute "make install" in your 2.6 build |
| 134 | directory and "make altinstall" in the others. |
| 135 | |
| 136 | |
| 137 | Configuration options and variables |
| 138 | ----------------------------------- |
| 139 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 140 | A source-to-source translation tool, "2to3", can take care of the |
| 141 | mundane task of converting large amounts of source code. It is not a |
| 142 | complete solution but is complemented by the deprecation warnings in |
| 143 | 2.6. This tool is currently available via the Subversion sandbox: |
Guido van Rossum | 433c8ad | 1994-08-01 12:07:07 +0000 | [diff] [blame] | 144 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 145 | http://svn.python.org/view/sandbox/trunk/2to3/ |
Martin v. Löwis | 2df6694 | 2000-12-13 14:14:32 +0000 | [diff] [blame] | 146 | |
| 147 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 148 | Issue Tracker and Mailing List |
| 149 | ------------------------------ |
Michael W. Hudson | 71dcc3e | 2005-02-22 15:33:26 +0000 | [diff] [blame] | 150 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 151 | We're soliciting bug reports about all aspects of the language. Fixes |
| 152 | are also welcome, preferable in unified diff format. Please use the |
| 153 | issue tracker: |
Fred Drake | 6caae14 | 2000-10-25 17:51:02 +0000 | [diff] [blame] | 154 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 155 | http://bugs.python.org/ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 156 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 157 | If you're not sure whether you're dealing with a bug or a feature, use |
| 158 | the mailing list: |
| 159 | |
Mark Dickinson | b9ebd04 | 2009-02-06 16:39:11 +0000 | [diff] [blame] | 160 | python-dev@python.org |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 161 | |
| 162 | To subscribe to the list, use the mailman form: |
| 163 | |
Mark Dickinson | b9ebd04 | 2009-02-06 16:39:11 +0000 | [diff] [blame] | 164 | http://mail.python.org/mailman/listinfo/python-dev/ |
Georg Brandl | 81299ad | 2006-02-20 10:24:06 +0000 | [diff] [blame] | 165 | |
Michael W. Hudson | 71dcc3e | 2005-02-22 15:33:26 +0000 | [diff] [blame] | 166 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 167 | Build Instructions |
Guido van Rossum | c07d5fa | 2000-09-01 22:50:02 +0000 | [diff] [blame] | 168 | ------------------ |
Guido van Rossum | 433c8ad | 1994-08-01 12:07:07 +0000 | [diff] [blame] | 169 | |
Neal Norwitz | bf2604c | 2007-08-30 17:22:44 +0000 | [diff] [blame] | 170 | On Unix, Linux, BSD, OSX, and Cygwin: |
Guido van Rossum | 433c8ad | 1994-08-01 12:07:07 +0000 | [diff] [blame] | 171 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 172 | ./configure |
| 173 | make |
| 174 | make test |
| 175 | sudo make install # or "make altinstall" |
| 176 | |
| 177 | You can pass many options to the configure script; run "./configure |
| 178 | --help" to find out more. On OSX and Cygwin, the executable is called |
| 179 | python.exe; elsewhere it's just python. |
| 180 | |
| 181 | On Mac OS X, if you have configured Python with --enable-framework, |
| 182 | you should use "make frameworkinstall" to do the installation. Note |
| 183 | that this installs the Python executable in a place that is not |
| 184 | normally on your PATH, you may want to set up a symlink in |
| 185 | /usr/local/bin. |
| 186 | |
Martin v. Löwis | 0c3842f | 2007-08-30 05:34:10 +0000 | [diff] [blame] | 187 | On Windows, see PCbuild/readme.txt. |
| 188 | |
Guido van Rossum | 1c896e3 | 2007-08-29 23:03:30 +0000 | [diff] [blame] | 189 | If you wish, you can create a subdirectory and invoke configure from |
| 190 | there. For example: |
| 191 | |
| 192 | mkdir debug |
| 193 | cd debug |
| 194 | ../configure --with-pydebug |
| 195 | make |
| 196 | make test |
| 197 | |
| 198 | (This will fail if you *also* built at the top-level directory. You |
| 199 | should do a "make clean" at the toplevel first.) |
Guido van Rossum | ef0f129 | 2007-08-30 14:51:05 +0000 | [diff] [blame] | 200 | |
| 201 | |
| 202 | Copyright and License Information |
| 203 | --------------------------------- |
| 204 | |
Barry Warsaw | 659fc42 | 2008-03-01 17:45:23 +0000 | [diff] [blame] | 205 | Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 |
Guido van Rossum | ef0f129 | 2007-08-30 14:51:05 +0000 | [diff] [blame] | 206 | Python Software Foundation. |
| 207 | All rights reserved. |
| 208 | |
| 209 | Copyright (c) 2000 BeOpen.com. |
| 210 | All rights reserved. |
| 211 | |
| 212 | Copyright (c) 1995-2001 Corporation for National Research Initiatives. |
| 213 | All rights reserved. |
| 214 | |
| 215 | Copyright (c) 1991-1995 Stichting Mathematisch Centrum. |
| 216 | All rights reserved. |
| 217 | |
| 218 | See the file "LICENSE" for information on the history of this |
| 219 | software, terms & conditions for usage, and a DISCLAIMER OF ALL |
| 220 | WARRANTIES. |
| 221 | |
| 222 | This Python distribution contains *no* GNU General Public License |
| 223 | (GPL) code, so it may be used in proprietary projects. There are |
| 224 | interfaces to some GNU code but these are entirely optional. |
| 225 | |
| 226 | All trademarks referenced herein are property of their respective |
| 227 | holders. |