Commit Graph

2228 Commits

Author SHA1 Message Date
Martin v. Löwis 4d394dfebb Truncate st_?time before comparing it with ST_?TIME in the tests. 2005-01-23 09:19:22 +00:00
Thomas Heller d6c6e2224b distutils/command/install.py change. 2005-01-20 19:20:16 +00:00
Michael W. Hudson 46e6d92dc1 tweaks, small updates 2005-01-18 15:53:59 +00:00
Skip Montanaro 058858151d Document the reconvert module. 2005-01-16 20:48:27 +00:00
Martin v. Löwis fe33d0ba87 Default stat_float_times to true. 2005-01-16 08:57:39 +00:00
Martin v. Löwis 22b457e03b Added SEEK_* constants. Fixes #711830. 2005-01-16 08:40:58 +00:00
Andrew McNamara f69d94f6c0 Moved reader \r and \n processing from the iterator to the state machine -
this allows for better handling of newline characters in quoted fields (and
hopefully resolves Bug 967934).
2005-01-13 11:30:54 +00:00
Skip Montanaro 0af3ade6aa Add strptime() constructor to datetime class. Thanks to Josh Spoerri for
the changes.
2005-01-13 04:12:31 +00:00
Andrew McNamara 7f2053eff3 Add counting of source iterator lines to the reader object - handy for
user error messages (otherwise difficult to do without instrumenting
the source).
2005-01-12 11:17:16 +00:00
Andrew McNamara 0f0599ddc1 When quoting=QUOTE_NONNUMERIC, the reader now casts unquoted fields
to floats.
2005-01-12 09:45:18 +00:00
Andrew McNamara c89f284df8 When using QUOTE_NONNUMERIC, we now test for "numericness" with
PyNumber_Check, rather than trying to convert to a float.  Reimplemented
writer - now raises exceptions when it sees a quotechar but neither
doublequote or escapechar are set. Doublequote results are now more
consistent (eg, single quote should generate """", rather than "",
which is ambiguous).
2005-01-12 07:44:42 +00:00
Andrew McNamara 31d8896ee2 Rename csv.set_field_limit to csv.field_size_limit (since it both sets and
gets).
2005-01-12 03:45:10 +00:00
Andrew McNamara a08eecb638 Add news about csv module updates. 2005-01-12 03:25:27 +00:00
Raymond Hettinger a422c34b70 SF 1098985: set objects cannot be marshalled 2005-01-11 03:03:27 +00:00
Skip Montanaro afd77d980e Add definitions for "up" and "down" commands that print/display the current
Python file/line when the current C execution frame is inside
PyEval_EvalFrame.  These are commented out by default because GDB sometimes
crashes as a result (seems like a GDB bug).

Add a pyframe command that displays the current Python stack frame.  If the
marked lines are uncommented, it will also cause Emacs/XEmacs to display the
current file/line.
2005-01-08 21:56:43 +00:00
Brett Cannon e6539c4401 In _DummyThread objects the lock stored in __block (allocated thanks to
_Thread.__init__) was never used.  This is a waste since locks use OS
primitives that are in limited supply.  So the lock is deleted in
_DummyThread.__init__ .

Closes bug #1089632.
2005-01-08 02:43:53 +00:00
Raymond Hettinger 97db05de3e SF #75103: imghdr -- identify JPEGs in EXIF format 2005-01-07 08:15:41 +00:00
Raymond Hettinger c34f8673a1 Teach the peephole optimizer to fold simple constant expressions. 2005-01-02 06:17:33 +00:00
Andrew M. Kuchling 3b585b30c0 [Bug #1083110] calling .flush() on decompress objects causes a segfault due to an uninitialized pointer: fixes the problem and adds a test case 2004-12-28 20:10:48 +00:00
Walter Dörwald 3673369951 Add NEWS entry about bug #1076985. 2004-12-22 12:50:50 +00:00
Sean Reifschneider 7caafe7018 Changing the idle wrapper to use Python and execvp() to pass arguments to
idle.
2004-12-21 02:22:29 +00:00
Raymond Hettinger 6065d32325 SF bug #951915: fix bug in StringIO.truncate - length not changed
(Patch by Armin Rigo.)
2004-12-20 23:51:53 +00:00
Raymond Hettinger b0900e6a21 SF #1085304: Make array.array pickle-able 2004-12-16 16:23:40 +00:00
Marc-André Lemburg bb4f1bdd8b locale.py now uses an updated locale alias table (built using
Tools/i18n/makelocalealias.py, a tool to parse the X11 locale
alias file); the encoding lookup was enhanced to use Python's
encoding alias table

As sige-effect, this fixes SF bug [ 1080864 ] locale.py doesn't recognize
valid locale setting.
2004-12-10 21:58:14 +00:00
Raymond Hettinger 3557f42658 Combined several entries. 2004-12-07 12:02:02 +00:00
Raymond Hettinger a6b45cc31d Eliminate the deprecated option to return None instead of a tuple of arguments in __reduce__(). 2004-12-07 07:05:57 +00:00
Brett Cannon 84667c063a Change code in setup.py for parsing LDFLAGS and CPPFLAGS to use optparse
instead of getopt.  Required making use of gettext._ as optional (optparse
changed OK'ed by Greg Ward in private email).
2004-12-07 03:25:18 +00:00
Brett Cannon 516592f4ff setup.py now uses the library directories specified in LDFLAGS (``-L``
directories) and the include directories specified in CPPFLAGS (``-I``
directories) for compiling the extension modules.

This has led to the core being compiled with the values in the shell's
CPPFLAGS.  It has also removed the need for special casing to use Fink and
DarwinPorts under darwin since the needed directories can now be specified in
LDFLAGS and CPPFLAGS (e.g., DarwinPorts users can now do
``LDFLAGS=-L/opt/local/lib; CPPFLAGS=-I/opt/local/include; ./configure`` for
everything to work properly).

Parsing the values in the environment variables is done with getopt.  While optparse
would have been a nicer solution it cannot be used because of dependency issues
at execution time; optparse uses gettext which uses struct which will not have
been compiled when the code is imported.  If optparse ever makes its
importation of gettext optional by catching ImportError and setting _() to an
identity function then it can be used.
2004-12-07 00:42:59 +00:00
Raymond Hettinger c7979f16ec Removed deprecated tzparse module. 2004-12-05 11:38:18 +00:00
Raymond Hettinger b2594050ea Added optional None arguments to itertools.islice(). 2004-12-05 09:25:51 +00:00
Raymond Hettinger 3489cad30a Removed the deprecated bin parameter from the pickle module. 2004-12-05 05:20:42 +00:00
Raymond Hettinger 4ebe364277 Remove the deprecated statcache module. 2004-12-05 04:55:14 +00:00
Raymond Hettinger 1bc82f891c Removed deprecated method arguments from the shelve module. 2004-12-05 03:58:17 +00:00
Raymond Hettinger 6c92d76abc Removed deprecated method from pstats. 2004-12-05 03:28:00 +00:00
Raymond Hettinger f3fa9460de Removed deprecated use_statcache argument. 2004-12-05 01:58:09 +00:00
Raymond Hettinger 664347be94 SF bug #1078905: Docs for unittest run() methods are misleading 2004-12-04 21:21:53 +00:00
Raymond Hettinger 784ab76c87 Remove the deprecated whrandom module. 2004-12-04 10:50:51 +00:00
Raymond Hettinger 665174834a Remove PyRange_New(). 2004-12-03 11:45:13 +00:00
Raymond Hettinger f9245578c9 Acknowledge contribution of a thorough tutorial review. 2004-12-03 08:33:32 +00:00
Raymond Hettinger 3b0c7c20a1 SF patch #1077353: add key= argument to min and max
(First draft of patch contributed by Steven Bethard.)
2004-12-03 08:30:39 +00:00
Raymond Hettinger 4901a1f267 Add key= argument to heapq.nsmallest() and heapq.nlargest(). 2004-12-02 08:59:14 +00:00
Anthony Baxter 4277ed8d0a whoops! 2004-11-30 11:53:10 +00:00
Anthony Baxter e2648eeb14 doodedoodedoo on the way to 2.4 final 2004-11-30 01:28:55 +00:00
Anthony Baxter e48bad7a24 preparing for 2.4 final (wooooooo!) 2004-11-29 01:40:31 +00:00
Kurt B. Kaiser 4c79a83e0c Hye-Shik Chang's fix for Bug 875692.
Improve signal handling, especially when using threads, by forcing an early
re-execution of PyEval_EvalFrame() "periodic" code when things_to_do is not
cleared by Py_MakePendingCalls().

M Misc/NEWS
M Python/ceval.c
2004-11-23 18:06:08 +00:00
Anthony Baxter 5cc727ad7b 2.4rc1 2004-11-18 12:32:27 +00:00
Raymond Hettinger 39e92ead4b Mark PyRange_New() as deprecated. 2004-11-18 09:41:45 +00:00
Skip Montanaro 0bb2a65dbd split functionality into pystack and pystackv commands. The former will
work with core dumps because it avoids calling any Python API routines.  The
latter prints all the local variable values as well as the stack frames but
won't work with core dumps because it relies on _PyObject_Dump to print
variables.
2004-11-17 16:04:15 +00:00
Tim Peters bbc0d4409c SF bug 1065388: calendar day/month name lookup too slow
__getitem__() methods:  compute only the new spellings needed to satisfy
the given indexing object.  This is purely an optimization (it should
have no effect on visible semantics).
2004-11-13 16:18:32 +00:00
Raymond Hettinger 96b49a51d0 SF patch 1062495: Modules/zipimport.c does not compile on solaris (Contributed by Niki W. Waibel.)
Simple renaming to avoid a conflict that prevented compilation on Solaris.
2004-11-10 13:13:05 +00:00
Tim Peters 50c6bdb1d6 test_doctest.py test_pdb_set_trace_nested(): A new test from Jim Fulton
showing that doctest's pdb.set_trace() support was dramatically broken.

doctest.py _OutputRedirectingPdb.trace_dispatch():  Return a local trace
function instead of (implicitly) None.  Else interaction with pdb was
bizarre, noticing only 'call' events.  Amazingly, the existing set_trace()
tests didn't care.
2004-11-08 22:07:37 +00:00
Tim Peters fb1ffb0ebb SF bug 1061968: threads: segfault or Py_FatalError at exit
PyGILState_Ensure():  The fix in 2.4a3 for bug 1010677 reintroduced thread
shutdown race bug 225673.  Repaired by (once again) ensuring the GIL is
held whenever deleting a thread state.

Alas, there's no useful test case for this shy bug.  Four years ago, only
Guido could provoke it, on his box, and today only Armin can provoke it
on his box.  I've never been able to provoke it (but not for lack of
trying!).

This is a critical fix for 2.3.5 too, since the fix for 1010677 got
backported there already and so also reintroduced 225673.  I don't intend to
backport this fix.  For whoever (if anyone) does, there are other thread
fixes in 2.4 that need backporting too, and I bet they need to happen first
for this patch to apply cleanly.
2004-11-08 04:30:21 +00:00
Jeremy Hylton def9d2a17c Fix for SF bug 988120 via patch 1061941.
If read() returned less than the number of bytes request, the full amount was subtracted from length instead of the actually read amount.
2004-11-07 16:13:49 +00:00
Brett Cannon 7d28e96a41 Add comment about removal of CoreServices/CoreFoundation compilation against
the core on OS X (also specifically mention removal of
PyMac_GetAppletScriptFile() ).
2004-11-07 01:19:00 +00:00
Tim Peters 90cf212cef Essentially SF patch 1061679: add missing __all__ to pickletools.py.
Harmless.
2004-11-06 23:45:48 +00:00
Brett Cannon b12efd3f8a Comment cleanup. 2004-11-06 19:56:45 +00:00
Anthony Baxter b0c6630794 post-release 2004-11-04 05:23:17 +00:00
Skip Montanaro 599bd5e1e1 Fix bug 1052242. Also includes rewrite of test case using unittest and
avoiding use of popen.
2004-11-04 04:31:30 +00:00
Anthony Baxter 9f41f3a192 release shenanigans 2004-11-03 06:21:37 +00:00
Barry Warsaw 8c72eae237 SF patch #1056967, changes the semantics of Template.safe_substitute() to not
raise a ValueError for dangling delimiters (the delimiter itself is returned).
2004-11-01 03:52:43 +00:00
Tim Peters ead8b7ab30 SF 1055820: weakref callback vs gc vs threads
In cyclic gc, clear weakrefs to unreachable objects before allowing any
Python code (weakref callbacks or __del__ methods) to run.

This is a critical bugfix, affecting all versions of Python since weakrefs
were introduced.  I'll backport to 2.3.
2004-10-30 23:09:22 +00:00
Hye-Shik Chang 337614993e Patch #1044395: Allow configure option --enable-shared in FreeBSD.
(Submitted by James William Pye, Patch revised by Jiwon Seo)
2004-10-26 09:53:46 +00:00
Hye-Shik Chang 182ac85147 SF #737473: Show up-to-date source code in tracebacks always.
And add an optional argument 'filename' to linecache.checkcache()
to enable checking caches per-file.
2004-10-26 09:16:42 +00:00
Raymond Hettinger 561fbf138d SF bug #1054139: serious string hashing error in 2.4b1
_PyString_Resize() readied strings for mutation but did not invalidate
the cached hash value.
2004-10-26 01:52:37 +00:00
Raymond Hettinger 2ef7e6c8f2 SF bug #1052503: pdb runcall should accept keyword arguments 2004-10-24 00:32:24 +00:00
Raymond Hettinger 9047c8f73d SF bug #1048870: call arg of lambda not updating 2004-10-24 00:10:06 +00:00
Tim Peters acaffe65a3 Move to version 2 of the PSF license, approved by the Board earlier today. 2004-10-23 03:43:54 +00:00
Brett Cannon 06a30b087e Fix minor reST error in Misc/NEWS.
Applies patch #1051866.  Thanks Felix Wiemann.
2004-10-22 06:22:54 +00:00
Sean Reifschneider 054541e924 Latest version for beta 1. 2004-10-21 23:35:45 +00:00
Andrew M. Kuchling 66e80baea2 Add item 2004-10-20 11:56:15 +00:00
Raymond Hettinger c64aab8400 SF bug #902037: relative on-disk SYSTEM id handling is incorrect 2004-10-20 08:21:57 +00:00
Raymond Hettinger e54e726f0b SF patch #1038388: __main__ for whichdb.py
(Contributed by Oleg Broytmann.)
2004-10-20 07:17:16 +00:00
Andrew M. Kuchling 9414ded8f3 Delete empty sections in beta1 news 2004-10-19 19:56:55 +00:00
Andrew M. Kuchling 0d19bae30e Add item 2004-10-19 19:54:41 +00:00
Brett Cannon 8abcc5d533 Add support for %U and %W to contribute to calculating the date when the year
and day of the week are specified.

Closes bug #1045381.
2004-10-18 01:37:57 +00:00
Brett Cannon be8370dc9c Add sections for 2.4b2 2004-10-18 01:32:09 +00:00
Anthony Baxter 6a587c160b release shenanigans 2004-10-15 08:07:21 +00:00
Anthony Baxter a024034b94 Patch 1046644 - improved distutils support for SWIG. 2004-10-14 10:02:08 +00:00
Anthony Baxter 22dcf66f84 Patch 983206: distutils obeys LDSHARED env var. Removed the code in
Python's own setup.py that did the same thing (and tested on Solaris,
where LDSHARED is needed...)
2004-10-13 15:54:17 +00:00
Anthony Baxter e4f8a48b8f 969574 2004-10-13 14:55:56 +00:00
Andrew M. Kuchling 518d393e0e Fix PEP number 2004-10-12 15:32:10 +00:00
Fredrik Lundh 5b3687df2e Added Peter Astrand's subprocess module. 2004-10-12 15:26:28 +00:00
Barry Warsaw 418de1f23c Added note about the new usegmt argument to email.Utils.formatdate(). 2004-10-11 14:32:47 +00:00
Tim Peters 7f468f29f4 SF patch 1044089: New C API function PyEval_ThreadsInitialized(), by Nick
Coghlan, for determining whether PyEval_InitThreads() has been called.
Also purged the undocumented+unused _PyThread_Started int.
2004-10-11 02:40:51 +00:00
Tim Peters 8470558a04 PyInterpreterState_New(), PyThreadState_New(): use malloc/free directly.
This appears to finish repairs for SF bug 1041645.

This is a critical bugfix.
2004-10-10 02:47:33 +00:00
Tim Peters 263091e388 find_key(): This routine wasn't thread-correct, and accounts for the
release-build failures noted in bug 1041645.

This is a critical bugfix.  I'm not going to backport it, though (no time).
2004-10-10 01:58:44 +00:00
Andrew M. Kuchling 3afe4f371c Add helpful comment 2004-10-07 12:30:54 +00:00
Andrew M. Kuchling 6f5932502d Take out Guido's name and put in the PSF 2004-10-07 12:27:31 +00:00
Andrew M. Kuchling 895f245954 Update two URLs 2004-10-07 12:23:12 +00:00
Andrew M. Kuchling 166e625d6c Add -m to man page 2004-10-07 12:04:50 +00:00
Raymond Hettinger db29e0fe8c SF patch #1035498: -m option to run a module as a script
(Contributed by Nick Coghlan.)
2004-10-07 06:46:25 +00:00
Brett Cannon 4f35c71543 Locale data that contains regex metacharacters are now properly escaped.
Closes bug #1039270.
2004-10-06 02:11:37 +00:00
Tim Peters 130e37f3e2 Read the text files to be compared in universal-newline mode. 2004-10-03 19:03:19 +00:00
Just van Rossum dd3c83734d added plistlib news item 2004-10-03 16:27:09 +00:00
David Goodger 1cbf206d32 SF bug #997050: Document, test, & check for non-string values in ConfigParser. Moved the new string-only restriction added in rev. 1.65 to the SafeConfigParser class, leaving existing ConfigParser & RawConfigParser behavior alone, and documented the conditions under which non-string values work. 2004-10-03 15:55:09 +00:00
David Goodger 68a1abdade SF bug #1017864: ConfigParser now correctly handles default keys, processing them with ``ConfigParser.optionxform`` when supplied, consistent with the handling of config file entries and runtime-set options. 2004-10-03 15:40:25 +00:00
Barry Warsaw bb11386730 Big email 3.0 API changes, with updated unit tests and documentation.
Briefly (from the NEWS file):

- Updates for the email package:
  + All deprecated APIs that in email 2.x issued warnings have been removed:
    _encoder argument to the MIMEText constructor, Message.add_payload(),
    Utils.dump_address_pair(), Utils.decode(), Utils.encode()
  + New deprecations: Generator.__call__(), Message.get_type(),
    Message.get_main_type(), Message.get_subtype(), the 'strict' argument to
    the Parser constructor.  These will be removed in email 3.1.
  + Support for Python earlier than 2.3 has been removed (see PEP 291).
  + All defect classes have been renamed to end in 'Defect'.
  + Some FeedParser fixes; also a MultipartInvariantViolationDefect will be
    added to messages that claim to be multipart but really aren't.
  + Updates to documentation.
2004-10-03 03:16:19 +00:00
Raymond Hettinger 565ea5ae37 SF bug#1038917 fix typos (Contributed by George Yoshida.) 2004-10-02 11:02:59 +00:00
Tim Peters cf8997f6f8 Noted the fix to deque gc. 2004-10-01 02:13:16 +00:00
Brett Cannon bfef869510 Add note about inclusion of DarwinPorts directories in setup.py on darwin. 2004-09-28 04:08:11 +00:00
Tim Peters a80a2c8e67 Updated doctest doc news. 2004-09-26 05:13:18 +00:00
Brett Cannon 35ae3dd5aa Add warning notation about using 'bomb' setting. 2004-09-25 01:39:56 +00:00
Raymond Hettinger 596ba4d89e Granted Noam Raphael's request for minor improvements to the re module and
its documentation.

* Documented that the compiled re methods are supposed to be more full
  featured than their simpilified function counterparts.

* Documented the existing start and stop position arguments for the
  findall() and finditer() methods of compiled regular expression objects.

* Added an optional flags argument to the re.findall() and re.finditer()
  functions.  This aligns their API with that for re.search() and
  re.match().
2004-09-24 03:41:05 +00:00
Tim Peters 862f0593d8 Introduced a Py_IS_NAN macro, which probably works on the major platforms
today.  pyconfig.h can override it if not, and can also override
Py_IS_INFINITY now.  Py_IS_NAN and Py_IS_INFINITY are overridden now
for Microsoft compilers, using efficient MS-specific spellings.
2004-09-23 19:11:32 +00:00
Tim Peters 307fa78107 SF bug #513866: Float/long comparison anomaly.
When an integer is compared to a float now, the int isn't coerced to float.
This avoids spurious overflow exceptions and insane results.  This should
compute correct results, without raising spurious exceptions, in all cases
now -- although I expect that what happens when an int/long is compared to
a NaN is still a platform accident.

Note that we had potential problems here even with "short" ints, on boxes
where sizeof(long)==8.  There's #ifdef'ed code here to handle that, but
I can't test it as intended.  I tested it by changing the #ifdef to
trigger on my 32-bit box instead.

I suppose this is a bugfix candidate, but I won't backport it.  It's
long-winded (for speed) and messy (because the problem is messy).  Note
that this also depends on a previous 2.4 patch that introduced
_Py_SwappedOp[] as an extern.
2004-09-23 08:06:40 +00:00
Raymond Hettinger 2c31a058eb SF patch #1031667: Fold tuples of constants into a single constant
Example:
>>> import dis
>>> dis.dis(compile('1,2,3', '', 'eval'))
  0           0 LOAD_CONST               3 ((1, 2, 3))
              3 RETURN_VALUE
2004-09-22 18:44:21 +00:00
Raymond Hettinger 0318a939dd Clarify that iteration is over headers, not Mime elements. 2004-09-22 18:03:47 +00:00
Raymond Hettinger ce96d8b684 Bug #1030125: rfc822 __iter__ problem
Add iteration support to the Message class.
2004-09-22 17:17:32 +00:00
Brett Cannon 24a0045d58 Add a commented-out recipe on making trailing whitespace explicit.
If people think this is not too intrusive it could be uncommented.
2004-09-20 22:33:21 +00:00
Martin v. Löwis 729d47db09 Patch #1024670: Support int objects in PyLong_AsUnsignedLong[Mask]. 2004-09-20 06:17:46 +00:00
Brett Cannon 8b4e886ed9 When this file is sourced in, or used as, one's vimrc file it will set the proper settings to follow the style guidelines laid out in PEPs 7 & 8 as best it can without forcing extraneous settings.
Suggested settings are commented out and included at the end of the file.

The goal is to have this file prevent as much as possible from deviating from the style guidelines.  It is not meant to collect every cool macro possible for Python.  Any useful settings for features included with Vim can be included and commented out, but anything overly extraneous should be left out.
2004-09-19 05:43:13 +00:00
Martin v. Löwis f3c5611fef Patch #1029061: Always extract member names from the tarinfo. 2004-09-18 09:08:52 +00:00
Martin v. Löwis 39a317890f Patch #1025790: Add status code constants to httplib. 2004-09-18 09:03:49 +00:00
Tim Peters 528ca53b74 SF bug #1028306: date-datetime comparison
Treat comparing a date to a datetime like a mixed-type comparison.
2004-09-16 01:30:50 +00:00
Skip Montanaro 82d0eecf42 mention httplib ipv6 fix 2004-09-14 17:58:31 +00:00
Walter Dörwald 5011d0c683 Fix quoting. 2004-09-13 08:53:15 +00:00
Tim Peters 82076ef194 Reluctantly, rehabilitate doctest.master. 2004-09-13 00:52:51 +00:00
Andrew M. Kuchling 55be9eab38 Typo fix: 'comparisions' is not a word 2004-09-10 12:59:54 +00:00
Martin v. Löwis 23c48a12d9 Patch #808120: Add --force-arch=ARCH to bdist_rpm.py. 2004-09-10 06:32:54 +00:00
Martin v. Löwis 641d64812c Patch #808115: Add script support to bdist_rpm.py. 2004-09-10 06:25:01 +00:00
Walter Dörwald 69652035bc SF patch #998993: The UTF-8 and the UTF-16 stateful decoders now support
decoding incomplete input (when the input stream is temporarily exhausted).
codecs.StreamReader now implements buffering, which enables proper
readline support for the UTF-16 decoders. codecs.StreamReader.read()
has a new argument chars which specifies the number of characters to
return. codecs.StreamReader.readline() and codecs.StreamReader.readlines()
have a new argument keepends. Trailing "\n"s will be stripped from the lines
if keepends is false. Added C APIs PyUnicode_DecodeUTF8Stateful and
PyUnicode_DecodeUTF16Stateful.
2004-09-07 20:24:22 +00:00
Jeremy Hylton 566d934745 compiler.transformer: correct lineno attribute when possible
SF patch #1015989

The basic idea of this patch is to compute lineno attributes for all AST nodes.  The actual
implementation lead to a lot of restructing and code cleanup.

The generated AST nodes now have an optional lineno argument to constructor.  Remove the
top-level asList(), since it didn't seem to serve any purpose.  Add an __iter__ to ast nodes.
Use isinstance() instead of explicit type tests.

Change transformer to use the new lineno attribute, which replaces three lines of code with one.
Use universal newlines so that we can get rid of special-case code for line endings.  Use
lookup_node() in a few more frequently called, but simple com_xxx methods().  Change string
exception to class exception.
2004-09-07 15:28:01 +00:00
Brett Cannon 2ad68e69b9 Ported test__locale to unittest. 2004-09-06 23:30:27 +00:00
Anthony Baxter f30bc11ce0 update version 2004-09-02 16:38:20 +00:00
Anthony Baxter e13943a1b0 release date 2004-09-02 16:37:15 +00:00
Andrew M. Kuchling 00873430c1 Add news item. 2004-08-31 13:50:43 +00:00
Andrew M. Kuchling 5a9618e069 Remove mpz, rotor 2004-08-31 13:43:19 +00:00
Andrew M. Kuchling 57269d0c7c Remove mpz, rotor, xreadlines modules 2004-08-31 13:37:25 +00:00
Anthony Baxter 1a4ddaecc7 SF patch #1007189, multi-line imports, for instance:
"from blah import (foo, bar
baz, bongo)"
2004-08-31 10:07:13 +00:00
Johannes Gijsbers 5ae9743ea6 Bug #1014775: update NEWS.help for changes in docutils. 2004-08-30 14:33:25 +00:00
Johannes Gijsbers 343cb8a768 Bug #1014770: apply some rest-foo and fix some docutils errors. 2004-08-30 14:27:11 +00:00
Johannes Gijsbers 4c11f6088a Patch #934356: if a module defines __all__, believe that rather than using
heuristics for filtering out imported names.
2004-08-30 14:13:04 +00:00
Johannes Gijsbers ae882f7984 Patch #941486: add os.path.lexists(). Also fix bug #940578 by using lexists in glob.glob. 2004-08-30 10:19:56 +00:00
Raymond Hettinger 356a4599ac Teach the random module about os.urandom().
* Use it for seeding when it is available.
* Provide an alternate generator based on it.
2004-08-30 06:14:31 +00:00
Tim Peters 47e52ee0c5 SF patch 936813: fast modular exponentiation
This checkin is adapted from part 2 (of 3) of Trevor Perrin's patch set.

BACKWARD INCOMPATIBILITY:  SHIFT must now be divisible by 5.  AFAIK,
nobody will care.  long_pow() could be complicated to worm around that,
if necessary.

long_pow():
  - BUGFIX:  This leaked the base and power when the power was negative
    (and so the computation delegated to float pow).
  - Instead of doing right-to-left exponentiation, do left-to-right.  This
    is more efficient for small bases, which is the common case.
  - In addition, if the exponent is large (more than FIVEARY_CUTOFF
    digits), precompute [a**i % c for i in range(32)], and go left to
    right 5 bits at a time.
l_divmod():
  - The signature changed so that callers who don't want the quotient,
    or don't want the remainder, can pass NULL in the slot they don't
    want.  This saves them from having to declare a vrbl for unwanted
    stuff, and remembering to decref it.
long_mod(), long_div(), long_classic_div():
  - Adjust to new l_divmod() signature, and simplified as a result.
2004-08-30 02:44:38 +00:00
Tim Peters 0973b99e1c SF patch 936813: fast modular exponentiation
This checkin is adapted from part 1 (of 3) of Trevor Perrin's patch set.

x_mul()
  - sped a little by optimizing the C
  - sped a lot (~2X) if it's doing a square; note that long_pow() squares
    often
k_mul()
  - more cache-friendly now if it's doing a square
KARATSUBA_CUTOFF
  - boosted; gradeschool mult is quicker now, and it may have been too low
    for many platforms anyway
KARATSUBA_SQUARE_CUTOFF
  - new
  - since x_mul is a lot faster at squaring now, the point at which
    Karatsuba pays for squaring is much higher than for general mult
2004-08-29 22:16:50 +00:00
Martin v. Löwis e064b41f5a Patch #914575: difflib side by side diff support, diff.py s/b/s HTML option. 2004-08-29 16:34:40 +00:00
Martin v. Löwis dc3883f671 Patch #934711: Expose platform-specific entropy. 2004-08-29 15:46:35 +00:00
Raymond Hettinger 6ab78cd0c0 SF feature request #992967: array.array objects should support sequences.
Made the constructor accept general iterables.
2004-08-29 07:50:43 +00:00
Brett Cannon cc8a4f6563 When building with --disable-toolbox-glue under Darwin, skip building any
Mac-specific modules.  Before all modules were compiled but would fail thanks
to a dependence on the code included when Python was built without the compiler
flag.

Closes bug #991962.
2004-08-26 01:44:07 +00:00
Dave Cole 3203efb55f Patch #1014930. Expose current parse location to XMLParser. 2004-08-26 00:37:31 +00:00
Martin v. Löwis cae9e673d6 Patch #970015: Replace - by _ in version and release. 2004-08-25 13:04:53 +00:00
Martin v. Löwis cf525241bb Patch #970019: Include version and release in the BuildRoot. 2004-08-25 13:00:34 +00:00
Martin v. Löwis 9f5c0c41ce Patch #736857, #736859: Add -e option to build_scripts. 2004-08-25 11:37:43 +00:00
Barry Warsaw 8bee76106e PEP 292 classes Template and SafeTemplate are added to the string module.
This patch includes test cases and documentation updates, as well as NEWS file
updates.

This patch also updates the sre modules so that they don't import the string
module, breaking direct circular imports.
2004-08-25 02:22:30 +00:00
Tim Peters c885443479 Stop producing or using OverflowWarning. PEP 237 thought this would
happen in 2.3, but nobody noticed it still was getting generated (the
warning was disabled by default).  OverflowWarning and
PyExc_OverflowWarning should be removed for 2.5, and left notes all over
saying so.
2004-08-25 02:14:08 +00:00
Raymond Hettinger 08158a0c65 Add Nick Coghlan for his patch solving an issue with joining string
subclasses.
2004-08-23 23:30:20 +00:00
Neal Norwitz 5268c3955a sf #1009373, #1005936. fix underscores in index entries in PDF files.
I couldn't test this, but it didn't break anything and the patch
reported fixed the problem.

Bugfix candidate.
2004-08-21 15:13:52 +00:00
Tim Peters 037b3ee44e Patch 1012740: cStringIO's truncate doesn't
truncate() left the stream position unchanged, which meant the
"truncated" data didn't go away:

>>> io.write('abc')
>>> io.truncate(0)
>>> io.write('xyz')
>>> io.getvalue()
'abcxyz'

Patch by Dima Dorfman.
2004-08-21 06:55:43 +00:00
Hye-Shik Chang 3ba5bfc766 Bug #1005737, #1007249: Fix several build problems and warnings
found on old/legacy C compilers of HP-UX, IRIX and Tru64.  (Reported
by roadkill, Richard Townsend, Maik Hertha and Minsik Kim)
2004-08-19 17:52:37 +00:00
Martin v. Löwis 336e85f56a Patch #900727: Add Py_InitializeEx to allow embedding without signals. 2004-08-19 11:31:58 +00:00
Hye-Shik Chang f64700a512 Add support for FreeBSD 6. 2004-08-18 15:13:41 +00:00
Martin v. Löwis 75b9da4aaf Patch #995126: Correct directory size, and generate GNU tarfiles by default. 2004-08-18 13:57:44 +00:00
Martin v. Löwis deacce2c87 Patch #800236: add HTTPResponse.getheaders(). 2004-08-18 12:46:26 +00:00
Johannes Gijsbers c473c99d16 Patch #1006219: let inspect.getsource show '@' decorators and add tests for
this (which are rather ugly, but it'll have to do until test_inspect gets a
major overhaul and a conversion to unittest). Thanks Simon Percivall!
2004-08-18 12:40:31 +00:00
Martin v. Löwis 318a12eb01 Patch #791776: Replace SMTPHandler.date_time with email.Utils.formatdate. 2004-08-18 12:27:40 +00:00
Martin v. Löwis fe84d17a6a Patch #764217: Add nametofont function, exists parameter. 2004-08-18 11:06:45 +00:00
Raymond Hettinger 9bb1f0592c Various alpha 3 updates. 2004-08-18 02:51:32 +00:00
Matthias Klose 2443d4ab5d - pygettext.py: Generate POT-Creation-Date header in ISO format. 2004-08-16 12:10:12 +00:00
Matthias Klose a2542bee59 The attached patch fixes FTBFS on GNU/k*BSD. The problem happens on GNU/k*BSD
because GNU/k*BSD uses gnu pth to provide pthreads, but will also happen on any
system that does the same.

python fails to build because it doesn't detect gnu pth in pthread
emulation. See C comments in patch for details.

patch taken from http://bugs.debian.org/264315
2004-08-16 11:35:51 +00:00
Matthias Klose 2e829c0214 - Bug #891637, patch #1005466: fix inspect.getargs() crash on def foo((bar)). 2004-08-15 17:04:33 +00:00
Skip Montanaro e5069019e7 Add get_history_item and replace_history_item functions to the readline
module.  Closes patch #675551.  My apologies to Michal Vitecek for taking so
long to process this.
2004-08-15 14:32:06 +00:00
Brett Cannon add33601c2 Correct the order of application for decorators. Meant to be bottom-up and not
top-down.  Now matches the PEP.
2004-08-15 07:21:25 +00:00
Johannes Gijsbers 34c4120731 bug #989672: pdb.doc and the help messages for the help_d and help_u methods
of the pdb.Pdb class gives have been corrected. d(own) goes to a newer frame,
u(p) to an older frame, not the other way around.
2004-08-14 15:19:28 +00:00
Johannes Gijsbers 4ec40648a5 bug #990669: os.path.realpath() will resolve symlinks before normalizing the
path, as normalizing the path may alter the meaning of the path if it contains
symlinks.

Also add tests for infinite symlink loops and parent symlinks that need to be
resolved.
2004-08-14 15:01:53 +00:00
Johannes Gijsbers b112d6ed78 bug 990669: os.path.normpath may alter the meaning of a path if it contains
symbolic links. This has been documented in a comment since 1992, but is now in
the library reference as well.
2004-08-14 14:41:32 +00:00
Johannes Gijsbers 9d134b7386 bug #851123: shutil.copyfile will raise an exception when trying to copy a file
onto a link to itself. Thanks Gregory Ball.
2004-08-14 14:03:03 +00:00
Tim Peters 7c399d3e68 Removed item about an asyncore patch that got backed out. 2004-08-13 22:34:14 +00:00
Brett Cannon b3de2e13ba 'inspect' was not listing the functions in a module properly if the module was
reached through a symlink (was comparing path of module to path to function and
were not matching because of the symlink).  os.path.realpath() is now used to
solve this discrepency.

Closes bug #570300.  Thanks Johannes Gijsbers for the fix.
2004-08-13 18:46:24 +00:00
Neal Norwitz f076953eb1 SF patch #1005778, Fix seg fault if list object is modified during list.index()
Backport candidate
2004-08-13 03:18:29 +00:00
Tim Peters 79b52b7261 Boosted the stack reservation for python.exe and python_w.exe from the
default 1MB to 2 million bytes.  The test suite passes with -uall again
(test_compiler no longer drives WinXP into an insane state).
2004-08-12 18:37:10 +00:00
Michael W. Hudson 800ba2375a This is my patch:
[ 1005891 ] support --with-tsc on PPC

plus a trivial change to settscdump's docstring and a Misc/NEWS entry.
2004-08-12 18:19:17 +00:00
Michael W. Hudson 5e897959db This is my patch
[ 1004703 ] Make func_name writable

plus fixing a couple of nits in the documentation changes spotted by MvL
and a Misc/NEWS entry.
2004-08-12 18:12:44 +00:00
Michael W. Hudson 5523c2517f A NEWS entry for my last checked in change (I've gotten out of the
habit of these, sorry).
2004-08-12 18:09:00 +00:00
Dave Cole 331708b226 Patch #1003700: Add socketpair function to socket module. 2004-08-09 04:51:41 +00:00
Tim Peters 83b57355a8 Brief xrange news. 2004-08-08 07:24:22 +00:00
Tim Peters 3ddd60a83b Also deprecated the old Tester class, which is no longer used by anything
except internal tests.
2004-08-08 02:43:33 +00:00
Michael W. Hudson 8c47f4a657 eval_frame now has a PyAPI-style name 2004-08-07 20:11:22 +00:00
Jeremy Hylton 4c989ddc9c Subclasses of string can no longer be interned. The semantics of
interning were not clear here -- a subclass could be mutable, for
example -- and had bugs.  Explicitly interning a subclass of string
via intern() will raise a TypeError.  Internal operations that attempt
to intern a string subclass will have no effect.

Added a few tests to test_builtin that includes the old buggy code and
verifies that calls like PyObject_SetAttr() don't fail.  Perhaps these
tests should have gone in test_string.
2004-08-07 19:20:05 +00:00
Andrew M. Kuchling 955d00922c Add name 2004-08-07 14:17:50 +00:00
Andrew M. Kuchling b34a6bc19d Create section for 2.4a3; remove empty sections in 2.4a2 2004-08-07 14:03:33 +00:00
Andrew M. Kuchling 78d375fb86 Another typo 2004-08-07 14:00:39 +00:00
Andrew M. Kuchling 28025ecda4 Typo fix 2004-08-07 13:59:22 +00:00
Raymond Hettinger 52a21b8e65 SF patch #980695: efficient string concatenation
(Original patch by Armin Rigo).
2004-08-06 18:43:09 +00:00
Marc-André Lemburg c759f070ef Added new codecs and aliases for ISO_8859-11, ISO_8859-16 and
TIS-620.

Closes SF bug #1001895: Adding missing ISO 8859 codecs, especially Thai.
2004-08-05 12:43:30 +00:00
Anthony Baxter ff347cadc4 release date 2004-08-05 07:21:01 +00:00
Tim Peters 8485b56216 Edward Loper's cool and massive refactoring of doctest.py, merged from
the tim-doctest-merge-24a2 tag on the the tim-doctest-branch branch.
We did development on the branch in case it wouldn't land in time for
2.4a2, but the branch looked good:  Edward's tests passed there, ditto
Python's tests, and ditto the Zope3 tests.  Together, those hit doctest
heavily.
2004-08-04 18:46:34 +00:00
Hye-Shik Chang c81c695dc9 Add a proper pointer to SF bug item. 2004-08-04 17:40:38 +00:00
Hye-Shik Chang 7df44b384a SF #941229: Decode source code with sys.stdin.encoding in interactive
modes like non-interactive modes.  This allows for non-latin-1 users
to write unicode strings directly and sets Japanese users free from
weird manual escaping <wink> in shift_jis environments.
(Reviewed by Martin v. Loewis)
2004-08-04 17:36:41 +00:00
Hye-Shik Chang e9ddfbb412 SF #989185: Drop unicode.iswide() and unicode.width() and add
unicodedata.east_asian_width().  You can still implement your own
simple width() function using it like this:
    def width(u):
        w = 0
        for c in unicodedata.normalize('NFC', u):
            cwidth = unicodedata.east_asian_width(c)
            if cwidth in ('W', 'F'): w += 2
            else: w += 1
        return w
2004-08-04 07:38:35 +00:00
Hye-Shik Chang b5047fd019 Add a workaround for a problem that UTF-8 strings can be corrupted
or broken by basic ctype functions in 4.4BSD descendants.  This
will be fixed in their future development branches but they'll keep
the POSIX-incompatibility for their backward-compatiblities in near
future.
2004-08-04 06:33:51 +00:00
Martin v. Löwis 1fa649f2d5 Patch #986929: Add support for wish -sync and -use options. 2004-08-03 18:45:31 +00:00
Fred Drake f901abdd62 allow ctime(), gmtime(), and localtime() to take None as equivalent to an omitted arg
(closes SF bug #658254, patch #663482)
2004-08-03 17:58:55 +00:00
Martin v. Löwis 9513e34ac4 Patch #823072: add option to NOT use ~/.netrc in nntplib.NNTP(). 2004-08-03 14:36:32 +00:00
Martin v. Löwis 65a7975f16 Patch #994595: Recognize Basic auth even if other schemes are offered.
Will backport to 2.3.
2004-08-03 12:59:55 +00:00
Raymond Hettinger 66bd233225 Completed the patch for Bug #215126.
* Fixes an incorrect variable in a PyDict_CheckExact.
* Allow general mapping locals arguments for the execfile() function
  and exec statement.
* Add tests.
2004-08-02 08:30:07 +00:00
Anthony Baxter 32083f64a7 notes for @decorator 2004-08-02 06:24:59 +00:00
Tim Peters 94f9b86930 "Core" and "C API" news about new semantics for failing imports. 2004-08-02 03:48:03 +00:00
Neal Norwitz 0e67fd478f Fix SF #1001053, wave.open() with unicode filename fails
Backport candidate.
2004-08-01 22:48:06 +00:00
Greg Ward 9c8fe1a9b5 Mention upgrade of optparse to Optik 1.5a1. 2004-07-31 16:16:11 +00:00
Neal Norwitz 014f103705 SF bug #999776, zlib home page wrong
Backport candidate.
2004-07-29 03:55:56 +00:00
Marc-André Lemburg 17b6d28c64 New codec: [ 996067 ] hp-roman8 codec 2004-07-28 15:37:54 +00:00
Tim Peters 5cfb05eef0 Added a new fileno() method. ZODB's repozo.py wants this so it can
apply os.fsync() to the GzipFile backup files it creates.
2004-07-27 21:02:02 +00:00
Martin v. Löwis 544f1195b1 Patch #995766: Keyword argument support in cPickle. 2004-07-27 05:22:33 +00:00
Martin v. Löwis 7b9190b8fc Patch #998149: imaplib deleteacl and myrights. 2004-07-27 05:07:19 +00:00
Martin v. Löwis cc0f93233a Patch #605370: Add description[s] for RFC 2980 compliance. 2004-07-26 12:40:50 +00:00
Tim Peters 66bb6e661c SF bug 996392: math and cmath docs don't specify radians
Major rewrite of the math module docs.  Slapped in "radians" where
appropriate; grouped the functions into reasonable categories; supplied
many more words to address common confusions about some of the subtler
issues.
2004-07-24 23:00:24 +00:00
Marc-André Lemburg b314ce91d3 Add news item for u'%s' change. 2004-07-23 16:14:57 +00:00
Gustavo Niemeyer 7bd33c5e22 This change implements the following gettext features, as
discussed recently in python-dev:

In _locale module:

- bind_textdomain_codeset() binding

In gettext module:

- bind_textdomain_codeset() function
- lgettext(), lngettext(), ldgettext(), ldngettext(),
  which return translated strings encoded in
  preferred system encoding, if
  bind_textdomain_codeset() was not used.
- Added equivalent functionality in translate()
  function and catalog classes.

Every change was also documented.
2004-07-22 18:44:01 +00:00
Tim Peters aa1c7ff7e8 SF patch 995225: tarfile.py fix for bug #990325
Removes CVS keywords from this binary file, so that test_tarfile passes
regardless of whether Python is checked out with -kk.
2004-07-22 00:54:37 +00:00
Brett Cannon 8b3d92a977 Fix bug where a KeyError was raised if -O was being used for the interpreter
and Thread.__delete() was called after a Thread instance was created.  Problem
resulted from a currentThread() call in an 'assert' statement being optimized
out and dummy_thread.get_ident() always returning -1 and thus overwriting the
entry for the _MainThread() instance created in 'threading' at import time.

Closes bug #993394.
2004-07-21 02:21:58 +00:00
Neal Norwitz a4f651a2ae SF #857297 and 916874, improve handling of hard links when extracting 2004-07-20 22:07:44 +00:00
Neal Norwitz 0662f8a5ea SF #846659, fix bufsize violation and GNU longname/longlink extensions 2004-07-20 21:54:18 +00:00
Neil Schemenauer 3a313e3655 Check the type of values returned by __int__, __float__, __long__,
__oct__, and __hex__.  Raise TypeError if an invalid type is
returned.  Note that PyNumber_Int and PyNumber_Long can still
return ints or longs.  Fixes SF bug #966618.
2004-07-19 16:29:17 +00:00
Neil Schemenauer 66edb6295f Don't return spurious empty fields if 'keep_empty_values' is True.
Fixes SF bug #990307.
2004-07-19 15:38:11 +00:00
Tim Peters 90ee7eb18e Record that FCNTL.py has gone away; remove FCNTL hack in tempfile.py;
another hack remains in test___all__.py, but the problem that one
addresses is more general than *just* FCNTL, so leaving it alone.
2004-07-18 23:58:17 +00:00
Tim Peters 182b5aca27 Whitespace normalization, via reindent.py. 2004-07-18 06:16:08 +00:00
Hye-Shik Chang 2bb146f2f4 Bring CJKCodecs 1.1 into trunk. This completely reorganizes source
and installed layouts to make maintenance simple and easy.  And it
also adds four new codecs; big5hkscs, euc-jis-2004, shift-jis-2004
and iso2022-jp-2004.
2004-07-18 03:06:29 +00:00
Raymond Hettinger 76d962d700 Treat None as a constant. 2004-07-16 12:16:48 +00:00
Jim Fulton e827437f45 Summarized changes: threading.local, Py_CLEAR, Py_VISIT, improved type
tutorial.
2004-07-14 19:08:28 +00:00
Anthony Baxter fd4984d1fc install test/decimaltestdata as well 2004-07-12 09:33:39 +00:00
Tim Peters 5af0e41482 Bug #788520: Queue class has logic error when non-blocking
I don't agree it had a bug (see the report), so this is *not* a candidate
for backporting, but the docs were confusing and the Queue implementation
was old enough to vote.

Rewrote put/put_nowait/get/get_nowait from scratch, to use a pair of
Conditions (not_full and not_empty), sharing a common mutex.  The code
is 1/4 the size now, and 6.25x easier to understand.  For blocking
with timeout, we also get to reuse (indirectly) the tedious timeout
code from threading.Condition.  The Full and Empty exceptions raised
by non-blocking calls are now easy (instead of nearly impossible) to
explain truthfully:  Full is raised if and only if the Queue truly
is full when the non-blocking put call checks the queue size, and
similarly for Empty versus non-blocking get.

What I don't know is whether the new implementation is slower (or
faster) than the old one.  I don't really care.  Anyone who cares
a lot is encouraged to check that.
2004-07-12 00:45:14 +00:00
Tim Peters 183dabcd73 SF patch 986010: add missing doc for datetime C API, from
Anthony Tuininga.

This is a derived patch, taking the opportunity to add some organization
to the now-large pile of datetime-related macros, and to factor out
tedious repeated text.

Also improved some clumsy wording in NEWS.
2004-07-11 19:26:19 +00:00
Brett Cannon d2c5b4b549 SequenceMatcher(None, [], []).get_grouped_opcodes() now returns a generator
that behaves as if both lists has an empty string in each of them.

Closes bug #979794 (and duplicate bug #980117).
2004-07-10 23:54:07 +00:00
Brett Cannon e6f8a89d1a Debug output is now printed to sys.stderr .
Closes bug #980938.
2004-07-10 23:14:30 +00:00
Brett Cannon f50299c378 posixpath.realpath() now detects symlink loops and returns the path just before
the loop starts.

Closes bug #930024.  Thanks AM Kuchling.
2004-07-10 22:55:15 +00:00
Brett Cannon 711e7d97e4 Add PyArg_VaParseTupleAndKeywords(). Document this function and
PyArg_VaParse().

Closes patch #550732.  Thanks Greg Chapman.
2004-07-10 22:20:32 +00:00
Andrew M. Kuchling 79d7e92a5c Add item 2004-07-10 21:21:55 +00:00
Brett Cannon bdc36273a2 Make ntpath compress multiple slashes between drive letter and the rest of the
path.  Also clarifies UNC handling and adds appropriate tests.

Applies patch #988607 to fix bug #980327.  Thanks Paul Moore.
2004-07-10 20:42:22 +00:00
Brett Cannon e67511809b Add note about closing of bug #679953 and add Jimmy Burgett for helping out to
Misc/ACKS.
2004-07-10 19:13:42 +00:00
Andrew M. Kuchling 64ed298d7a Add an item 2004-07-10 18:43:32 +00:00
Marc-André Lemburg 88fcca6815 Added note about new codecs module APIs. 2004-07-10 16:16:06 +00:00
Raymond Hettinger 21f9fce968 Fix typo. 2004-07-10 16:11:03 +00:00
Raymond Hettinger 5aa478badf Module and tests:
* Map conditions to related signals.
* Make contexts unhashable.
* Eliminate used "default" attribute in exception definitions.
* Eliminate the _filterfunc in favor of a straight list.

Docs:
* Eliminate documented references to conditions that are not signals.
* Eliminate parenthetical notes such as "1/0 --> Inf" which are no
  longer true with the new defaults.
2004-07-09 10:02:53 +00:00
Anthony Baxter 563e449729 post-release fun 2004-07-09 07:30:10 +00:00
Anthony Baxter 275ce74f23 2.4a1 2004-07-08 06:01:42 +00:00
Anthony Baxter 3210b36a28 release dates 2004-07-08 05:59:43 +00:00
Michael W. Hudson 30ea2f223f This closes patch:
[ 960406 ] unblock signals in threads

although the changes do not correspond exactly to any patch attached to
that report.

Non-main threads no longer have all signals masked.

A different interface to readline is used.

The handling of signals inside calls to PyOS_Readline is now rather
different.

These changes are all a bit scary!  Review and cross-platform testing
much appreciated.
2004-07-07 17:44:12 +00:00
Tim Peters b8b20e22bc Made the explanation more accurate; trimmed trailing whitespace; fixed
a typo.
2004-07-07 02:46:03 +00:00
Guido van Rossum 5124b4a082 Add msg for bug #981530 (shutil.rmtree). Somehow that got missed in
the checkin.
2004-07-06 17:52:32 +00:00
Andrew M. Kuchling 81e3fb4b3a Typo fixes 2004-07-04 15:41:59 +00:00
Brett Cannon 41d13f61d2 Clarify last added comment (bug #754449). 2004-07-03 03:54:54 +00:00
Brett Cannon cc4e935ea5 threading.Thread objects will now print a traceback for an exception raised
during interpreter shutdown instead of masking it with another traceback about
accessing a NoneType when trying to print the exception out in the first place.

Closes bug #754449 (using patch #954922).
2004-07-03 03:52:35 +00:00
Fred Drake 0a4dd390bf Make weak references subclassable:
- weakref.ref and weakref.ReferenceType will become aliases for each
  other

- weakref.ref will be a modern, new-style class with proper __new__
  and __init__ methods

- weakref.WeakValueDictionary will have a lighter memory footprint,
  using a new weakref.ref subclass to associate the key with the
  value, allowing us to have only a single object of overhead for each
  dictionary entry (currently, there are 3 objects of overhead per
  entry: a weakref to the value, a weakref to the dictionary, and a
  function object used as a weakref callback; the weakref to the
  dictionary could be avoided without this change)

- a new macro, PyWeakref_CheckRefExact(), will be added

- PyWeakref_CheckRef() will check for subclasses of weakref.ref

This closes SF patch #983019.
2004-07-02 18:57:45 +00:00
Thomas Heller 04c673b6e2 SF #951851 fixed. 2004-07-02 08:56:20 +00:00
Raymond Hettinger 214b1c3aae SF Bug #215126: Over restricted type checking on eval() function
The builtin eval() function now accepts any mapping for the locals argument.
Time sensitive steps guarded by PyDict_CheckExact() to keep from slowing
down the normal case.  My timings so no measurable impact.
2004-07-02 06:41:07 +00:00
Raymond Hettinger 7c85fa4a52 Move Decimal from the sandbox into production. 2004-07-01 11:01:35 +00:00
Michael W. Hudson 7db865af40 tyop 2004-06-30 09:09:38 +00:00
Michael W. Hudson c30ba849cf restore NEWS entry for 957240 2004-06-30 09:06:29 +00:00
Andrew M. Kuchling 93b4b88e96 [Patch #974633] Check PyObject_MALLOC return for error 2004-06-29 14:03:04 +00:00