11What's new in this release?
22===========================
33
4- Below is a list of all relevant changes since release 1.4. The
5- sections are now in a more useful order: the most recent changes are
6- listed first.
4+ Below is a list of all relevant changes since release 1.4. The most
5+ recent changes are listed first.
76
87A note on attributions: while I have sprinkled some names throughout
98here, I'm grateful to many more people who remain unnamed. You may
@@ -14,6 +13,274 @@ credit, let me know and I'll add you to the list!
1413======================================================================
1514
1615
16+ From 1.5.2a1 to 1.5.2a2
17+ =======================
18+
19+ General
20+ -------
21+
22+ - It is now a syntax error to have a function argument without a
23+ default following one with a default.
24+
25+ - __file__ is now set to the .py file if it was parsed (it used to
26+ always be the .pyc/.pyo file).
27+
28+ - Don't exit with a fatal error during initialization when there's a
29+ problem with the exceptions.py module.
30+
31+ - New environment variable PYTHONOPTIMIZE can be used to set -O.
32+
33+ - New version of python-mode.el for Emacs.
34+
35+ Miscellaneous fixed bugs
36+ ------------------------
37+
38+ - No longer print the (confusing) error message about stack underflow
39+ while compiling.
40+
41+ - Some threading and locking bugs fixed.
42+
43+ - When errno is zero, report "Error", not "Success".
44+
45+ Documentation
46+ -------------
47+
48+ - Documentation will be released separately.
49+
50+ - Doc strings added to array and md5 modules by Chris Petrilli.
51+
52+ Ports and build procedure
53+ -------------------------
54+
55+ - Stop installing when a move or copy fails.
56+
57+ - New version of the OS/2 port code by Jeff Rush.
58+
59+ - The makesetup script handles absolute filenames better.
60+
61+ - The 'new' module is now enabled by default in the Setup file.
62+
63+ - I *think* I've solved the problem with the Linux build blowing up
64+ sometimes due to a conflict between sigcheck/intrcheck and
65+ signalmodule.
66+
67+ Built-in functions
68+ ------------------
69+
70+ - The second argument to apply() can now be any sequence, not just a
71+ tuple.
72+
73+ Built-in types
74+ --------------
75+
76+ - Lists have a new method: L1.extend(L2) is equivalent to the common
77+ idiom L1[len(L1):] = L2.
78+
79+ - Better error messages when a sequence is indexed with a non-integer.
80+
81+ - Bettter error message when calling a non-callable object (include
82+ the type in the message).
83+
84+ Python services
85+ ---------------
86+
87+ - New version of cPickle.c fixes some bugs.
88+
89+ - pickle.py: improved instantiation error handling.
90+
91+ - code.py: reworked quite a bit. New base class
92+ InteractiveInterpreter and derived class InteractiveConsole. Fixed
93+ several problems in compile_command().
94+
95+ - py_compile.py: print error message and continue on syntax errors.
96+ Also fixed an old bug with the fstat code (it was never used).
97+
98+ - pyclbr.py: support submodules of packages.
99+
100+ String Services
101+ ---------------
102+
103+ - StringIO.py: raise the right exception (ValueError) for attempted
104+ I/O on closed StringIO objects.
105+
106+ - re.py: fixed a bug in subn(), which caused .groups() to fail inside
107+ the replacement function called by sub().
108+
109+ - The struct module has a new format 'P': void * in native mode.
110+
111+ Generic OS Services
112+ -------------------
113+
114+ - Module time: Y2K robustness. 2-digit year acceptance depends on
115+ value of time.accept2dyear, initialized from env var PYTHONY2K,
116+ default 0. Years 00-68 mean 2000-2068, while 69-99 mean 1969-1999
117+ (POSIX or X/Open recommendation).
118+
119+ - os.path: normpath(".//x") should return "x", not "/x".
120+
121+ - getpass.py: fall back on default_getpass() when sys.stdin.fileno()
122+ doesn't work.
123+
124+ - tempfile.py: regenerate the template after a fork() call.
125+
126+ Optional OS Services
127+ --------------------
128+
129+ - In the signal module, disable restarting interrupted system calls
130+ when we have siginterrupt().
131+
132+ Debugger
133+ --------
134+
135+ - No longer set __args__; this feature is no longer supported and can
136+ affect the debugged code.
137+
138+ - cmd.py, pdb.py and bdb.py have been overhauled by Richard Wolff, who
139+ added aliases and some other useful new features, e.g. much better
140+ breakpoint support: temporary breakpoint, disabled breakpoints,
141+ breakpoints with ignore counts, and conditions; breakpoints can be set
142+ on a file before it is loaded.
143+
144+ Profiler
145+ --------
146+
147+ - Changes so that JPython can use it. Also fix the calibration code
148+ so it actually works again
149+ .
150+ Internet Protocols and Support
151+ ------------------------------
152+
153+ - imaplib.py: new version from Piers Lauder.
154+
155+ - smtplib.py: change sendmail() method to accept a single string or a
156+ list or strings as the destination (commom newbie mistake).
157+
158+ - poplib.py: LIST with a msg argument fixed.
159+
160+ - urlparse.py: some optimizations for common case (http).
161+
162+ - urllib.py: support content-length in info() for ftp protocol;
163+ support for a progress meter through a third argument to
164+ urlretrieve(); commented out gopher test (the test site is dead).
165+
166+ Internet Data handling
167+ ----------------------
168+
169+ - sgmllib.py: support tags with - or . in their name.
170+
171+ - mimetypes.py: guess_type() understands 'data' URLs.
172+
173+ Restricted Execution
174+ --------------------
175+
176+ - The classes rexec.RModuleLoader and rexec.RModuleImporter no
177+ longer exist.
178+
179+ Tkinter
180+ -------
181+
182+ - When reporting an exception, store its info in sys.last_*. Also,
183+ write all of it to stderr.
184+
185+ - Added NS, EW, and NSEW constants, for grid's sticky option.
186+
187+ - Fixed last-minute bug in 1.5.2a1 release: need to include "mytime.h".
188+
189+ - Make bind variants without a sequence return a tuple of sequences
190+ (formerly it returned a string, which wasn't very convenient).
191+
192+ - Add image commands to the Text widget (these are new in Tk 8.0).
193+
194+ - Added new listbox and canvas methods: {xview,yview}_{scroll,moveto}.)
195+
196+ - Improved the thread code (but you still can't call update() from
197+ another thread on Windows).
198+
199+ - Fixed unnecessary references to _default_root in the new dialog
200+ modules.
201+
202+ - Miscellaneous problems fixed.
203+
204+
205+ Windows General
206+ ---------------
207+
208+ - Call LoadLibraryEx(..., ..., LOAD_WITH_ALTERED_SEARCH_PATH) to
209+ search for dependent dlls in the directory containing the .pyd.
210+
211+ - In debugging mode, call DebugBreak() in Py_FatalError().
212+
213+ Windows Installer
214+ -----------------
215+
216+ - Install zlib.dll in the DLLs directory instead of in the win32
217+ system directory, to avoid conflicts with other applications that have
218+ their own zlib.dll.
219+
220+ Test Suite
221+ ----------
222+
223+ - test_long.py: new test for long integers, by Tim Peters.
224+
225+ - regrtest.py: improved so it can be used for other test suites as
226+ well.
227+
228+ - test_strftime.py: use re to compare test results, to support legal
229+ variants (e.g. on Linux).
230+
231+ Tools and Demos
232+ ---------------
233+
234+ - Four new scripts in Tools/scripts: crlf.py and lfcr.py (to
235+ remove/add Windows style '\r\n' line endings), untabify.py (to remove
236+ tabs), and rgrep.yp (reverse grep).
237+
238+ - Improvements to Tools/freeze/. Each Python module is now written to
239+ its own C file. This prevents some compilers or assemblers from
240+ blowing up on large frozen programs, and saves recompilation time if
241+ only a few modules are changed. Other changes too, e.g. new command
242+ line options -x and -i.
243+
244+ - Much improved (and smaller!) version of Tools/scripts/mailerdaemon.py.
245+
246+ Python/C API
247+ ------------
248+
249+ - New mechanism to support extensions of the type object while
250+ remaining backward compatible with extensions compiled for previous
251+ versions of Python 1.5. A flags field indicates presence of certain
252+ fields.
253+
254+ - Addition to the buffer API to differentiate access to bytes and
255+ 8-bit characters (in anticipation of Unicode characters).
256+
257+ - New argument parsing format t# ("text") to indicate 8-bit
258+ characters; s# simply means 8-bit bytes, for backwards compatibility.
259+
260+ - New object type, bufferobject.c is an example and can be used to
261+ create buffers from memory.
262+
263+ - Some support for 64-bit longs, including some MS platforms.
264+
265+ - Many calls to fprintf(stderr, ...) have been replaced with calls to
266+ PySys_WriteStderr(...).
267+
268+ - The calling context for PyOS_Readline() has changed: it must now be
269+ called with the interpreter lock held! It releases the lock around
270+ the call to the function pointed to by PyOS_ReadlineFunctionPointer
271+ (default PyOS_StdioReadline()).
272+
273+ - New APIs PyLong_FromVoidPtr() and PyLong_AsVoidPtr().
274+
275+ - Renamed header file "thread.h" to "pythread.h".
276+
277+ - The code string of code objects may now be anything that supports the
278+ buffer API.
279+
280+
281+ ======================================================================
282+
283+
17284From 1.5.1 to 1.5.2a1
18285=====================
19286
0 commit comments