summaryrefslogtreecommitdiffstats
path: root/Lib
Commit message (Collapse)AuthorAgeFilesLines
* Patch #1191700: Adjust column alignment in bdb breakpoint lists.Martin v. Löwis2006-04-151-3/+3
| | | | Backported to 2.4.
* Changed comments to make sense now that the LazyList-basedTim Peters2006-04-151-4/+6
| | | | | | | | | | | | | | | | | examples no longer require any explicit closing to avoid leaking. That the tee-based examples still do is (I think) still a mystery. Part of the mystery is that gc.garbage remains empty: if it were the case that some generator in a trash cycle said it needed finalization, suppressing collection of that cycle, that generator _would_ show up in gc.garbage. So this is acting more like, e.g., some tp_traverse slot isn't visiting all the pointers it should (in which case the skipped pointer(s) would act like an external root, silently suppressing collection of everything reachable from it(them)).
* Fix SF#1470508: crash in generator cycle finalization. There were twoPhillip J. Eby2006-04-151-7/+0
| | | | | | | | | | | problems: first, PyGen_NeedsFinalizing() had an off-by-one bug that prevented it from ever saying a generator didn't need finalizing, and second, frame objects cleared themselves in a way that caused their owning generator to think they were still executable, causing a double deallocation of objects on the value stack if there was still a loop on the block stack. This revision also removes some unnecessary close() operations from test_generators that are now appropriately handled by the cycle collector.
* Whitespace normalization.Tim Peters2006-04-141-16/+16
|
* Add a BufferedIncrementalEncoder class that can be used for implementingWalter Dörwald2006-04-143-9/+169
| | | | | | | | | an incremental encoder that must retain part of the data between calls to the encode() method. Fix the incremental encoder and decoder for the IDNA encoding. This closes SF patch #1453235.
* Make error message less misleading for u"a..b".encode("idna").Walter Dörwald2006-04-141-3/+3
|
* Fix wrong attribute name.Walter Dörwald2006-04-141-1/+1
|
* Make raise statements PEP 8 compatible.Walter Dörwald2006-04-141-11/+11
|
* Show case: reference cycles involving only the ob_type field are ratherArmin Rigo2006-04-141-0/+13
| | | | uncommon but possible. Inspired by SF bug 1469629.
* Call encode()/decode() with final==True as the last call in theWalter Dörwald2006-04-141-0/+4
| | | | incremental codec tests.
* Copy note from leakers README here too. We want to keep all test cases.Neal Norwitz2006-04-141-0/+5
|
* Restore test tee with some modifications.Neal Norwitz2006-04-141-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test case came from test_generators, not test_itertools. Ensure there's no cyclic garbage we are counting. This is weird because it leaks, then reaches a limit: python.exe -i test_tee.py >>> leak() 0 [26633 refs] >>> leak() 0 [26658 refs] >>> leak() 0 [26683 refs] >>> leak() 0 [26708 refs] >>> leak() 0 [26708 refs] >>> leak() 0 [26708 refs] >>> leak() 0
* Move the old test_generator_cycle.py which leaked but was removed into the testNeal Norwitz2006-04-141-0/+17
|
* Update notes to address cyclic garbage and what should happen when a test is ↵Neal Norwitz2006-04-141-0/+13
| | | | fixed.
* When using -R, lots of "*** DocTestRunner.merge:" nuisance messagesTim Peters2006-04-131-1/+3
| | | | | | | appear. Get rid of them by nuking doctest's default DocTestRunner instance as part of cleanup(). Also cleanup() before running the first test repetition (the test was run once before we get into the -R branch).
* Whitespace normalization.Tim Peters2006-04-131-1/+1
|
* Add a test for Py_ssize_t. Correct typo in getargs.c.Georg Brandl2006-04-131-1/+18
|
* test_compile can be really long if we are using -u compiler.Neal Norwitz2006-04-131-2/+11
| | | | | | | | | This may be causing the debian sparc buildbot to fail. Print a little message to let the user ^w buildbot know it's still thinking. We may want to adjust the time period which is currently 5 minutes. Will backport.
* Remove tests that no longer leak. There is still one leaking generator testNeal Norwitz2006-04-133-30/+19
|
* tty isn't supported on all boxes.Tim Peters2006-04-131-1/+6
|
* reverting r45321: Patch #860326: traceback.format_exception_only() nowAnthony Baxter2006-04-132-26/+1
| | | | | | | | prepends the exception's module name to non-builtin exceptions, like the interpreter itself does. broke a number of doctests. should be discussed before checking in (see discussion on python-dev).
* Patch #860326: traceback.format_exception_only() now prepends theGeorg Brandl2006-04-122-1/+26
| | | | | exception's module name to non-builtin exceptions, like the interpreter itself does.
* Fixes bug #1117761Gregory P. Smith2006-04-122-8/+10
| | | | | | | | | bsddb.*open() methods cachesize parameter wouldn't work (raised an internal bsddb.db exception when it was given). The set_cachesize call needed to be moved from the DB object to the DBEnv since the env was introduced to allow for threading. (will backport to 2.4)
* Closes bug #1149413Gregory P. Smith2006-04-122-2/+9
| | | | | | | Using None for a filename with the 'n' flag when calling bsddb.btopen would cause an error while checking if the file None existed. error not likely to be seen as anyone using None for a filename would likely use the 'c' flag in the first place.
* Fix for a bug found by Armin Rigo, plus test.Thomas Heller2006-04-121-0/+12
| | | | https://sourceforge.net/tracker/?func=detail&atid=532154&aid=1467852&group_id=71702
* Patch #1468808: don't complain if Tkinter is already deleted at the time ↵Georg Brandl2006-04-121-1/+3
| | | | Font.__del__ is run.
* Update test_sundry. Many modules have now tests, butGeorg Brandl2006-04-121-36/+12
| | | | e.g. SimpleXMLRPCServer wasn't in here yet.
* Bug #1469163: SimpleXMLRPCServer unconditionally attempted to import fcntl.Anthony Baxter2006-04-121-2/+6
| | | | Wrapped in a try/except.
* Patch #1463288: use a context manager to temporarily switch locales.Walter Dörwald2006-04-122-30/+164
| | | | Add tests for the output of the TextCalendar and HTMLCalendar classes.
* Add another little test to make sure we roundtrip multiple list comp ifs ok.Neal Norwitz2006-04-121-0/+4
| | | | Add tests for generator expressions too.
* Part two of the fix for SF bug #1466641: Regenerate graminit.c and add testThomas Wouters2006-04-121-0/+5
| | | | for the bogus failure.
* StreamHandler now checks explicitly for None before using sys.stderr as the ↵Vinay Sajip2006-04-111-1/+1
| | | | stream (see SF bug #1463840).
* Adjust whitespace.Neal Norwitz2006-04-112-4/+4
|
* Add whitespace after commaNeal Norwitz2006-04-111-1/+1
|
* Try to repair what may be the last new test failure on theTim Peters2006-04-111-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "x86 OpenBSD trunk" buildbot due to changing Python so that Python-exposed addresses are always non-negative. test_int_pointer_arg(): This line failed now whenever the box happened to assign an address to `ci` "with the sign bit set": self.failUnlessEqual(addressof(ci), func(byref(ci))) The problem is that the ctypes addressof() inherited "all addresses are non-negative now" from changes to PyLong_FromVoidPtr(), but byref() did not inherit that change and can still return a negative int. I don't know whether, or what, the ctypes implementation wants to do about that (possibly nothing), but in the meantime the test fails frequently. So, introduced a Python positive_address() function in the test module, that takes a purported machine address and, if negative, converts it to a non-negative value "with the same bits". This should leave the test passing under all versions of Python. Belated thanks to Armin Rigo for teaching me the sick trick ;-) for determining the # of bits in a machine pointer via abuse of the struct module.
* subclasspropagation(): Squash two more bogus hash(x) == id(x)Tim Peters2006-04-111-2/+2
| | | | | | | tests. Alas, because only the "x86 OpenBSD trunk" buildbot fails these tests, and test_descr stops after the first failure, there's no sane way for me to fix these short of fixing one and then waiting for the buildbot to reveal the next one.
* Whitespace normalization.Tim Peters2006-04-112-4/+4
|
* specials(): squash another incorrect hash(x) == id(x)Tim Peters2006-04-111-1/+6
| | | | | | test. Add some lines that at least invoke the default __hash__, although there's nothing to check there beyond that they don't blow up.
* Updated the warnings, linecache, inspect, traceback, site, and doctest modulesPhillip J. Eby2006-04-117-27/+142
| | | | | to work correctly with modules imported from zipfiles or via other PEP 302 __loader__ objects. Tests and doc updates are included.
* Huh. This belonged with the last checkin -- no idea why svnTim Peters2006-04-111-1/+0
| | | | didn't commit it.
* Try to repair more new buildbot failures in "x86 OpenBSD trunk", dueTim Peters2006-04-111-1/+1
| | | | | | | | | | | | | | | | to that id() can now return a Python long on a 32-bit box that allocates addresses "with the sign bit set". test_set.py test_subclass_with_custom_hash(): it's never been portably legal for a __hash__() method to return id(self), but on 32-bit boxes that never caused a problem before it became possible for id() to return a Python long. Changed __hash__ here to return a Python int regardless of platform. test_descr.py specials(): vereq(hash(c1), id(c1)) has never been a correct test -- just removed it (hash() is always a Python int; id() may be a Python long).
* Fix one of the tests that fails on the "x86 OpenBSD trunk" buildbot,Tim Peters2006-04-101-1/+1
| | | | | due to that id() may return a long on a 32-bit box now. On a box that assigns addresses "with the sign bit set", id() always returns a long now.
* Fix one of the tests that fails on the "x86 OpenBSD trunk" buildbot, dueTim Peters2006-04-101-1/+1
| | | | | to that id() may return a long on a 32-bit box now. On a box that assigns addresses "with the sign bit set", id() always returns a long now.
* Whitespace normalization.Tim Peters2006-04-101-2/+2
|
* DecimalContextTestCase: this permanently changed theTim Peters2006-04-101-9/+13
| | | | | | default decimal context, causing test_tokenize to fail if it ran after test_contextlib. Changed to restore the decimal context in effect at the test's start.
* test_contextlib wasn't actually being run by regrtest.py. Or more precisely,Phillip J. Eby2006-04-101-1/+9
| | | | it was being run, but no tests were actually executed!
* Minor clarity edit to contextlib per Guido's request.Phillip J. Eby2006-04-101-2/+2
|
* Patch #1467770: Add Popen objects to _active only in __del__.Martin v. Löwis2006-04-101-10/+26
| | | | | | Introduce _child_active member to keep track on whether a child needs to be waited for. Backport candidate.
* Patch #1429775: Link Python modules to libpython on linux ifMartin v. Löwis2006-04-102-4/+24
| | | | --enable-shared. Fixes #832799.
* Patch #1462222: Fix Tix.Grid. Closes #1036406.Martin v. Löwis2006-04-101-11/+87
|