Commit Graph

11747 Commits

Author SHA1 Message Date
Thomas Heller 8e9e4d8f95 Issue #1642: Fix segfault in ctypes when trying to delete attributes. 2007-12-18 19:00:59 +00:00
Alexandre Vassalotti 483704508d Backport r59480.
Fix issue #1313119.
2007-12-13 18:18:47 +00:00
Lars Gustäbel 7cc9c8bbe1 Issue #1531: Read fileobj from the current offset, do not seek to
the start.

(backport from r59260)
2007-12-01 21:06:06 +00:00
Amaury Forgeot d'Arc 8334a4fc31 Backport of r59241: str.decode fails on very long strings on 64bit platforms.
PyArgs_ParseTuple t# and w# formats truncated the lengths to 32bit.
2007-11-30 21:53:17 +00:00
Skip Montanaro 664ad76a34 back in these go - thanks to Titus Brown for the fix 2007-11-24 14:31:16 +00:00
Amaury Forgeot d'Arc 30f61cbb13 Issue #1445: Fix a SystemError when accessing the ``cell_contents``
attribute of an empty cell object.  Now a ValueError is raised.

Backport of r59170.
2007-11-24 13:53:29 +00:00
Skip Montanaro fb80cd91a8 revert change that breaks test_doctest (which I forgot to run - sorry) 2007-11-24 04:29:52 +00:00
Skip Montanaro ab4fce4d7c Make trace and doctest play nice together (issue 1429818). Backported from
head.
2007-11-23 17:09:34 +00:00
Brett Cannon a95fdb4f9c Backport of a fix for the __loader__.get_data() test. 2007-11-23 00:07:49 +00:00
Ronald Oussoren ce189e4e7b A test that should test for osx >= 10.4.0 actually tested for os versions <= 10.4. The end result is that
a universal ("fat") build will claim to be a single-architecture on on OSX 10.5 (Leopard).

This patch fixes this issue.
2007-11-22 10:14:26 +00:00
Brett Cannon d3a81df178 Backport of r59082 (doctest and using __loader__.get_data()). 2007-11-21 00:58:54 +00:00
Walter Dörwald f481598cd0 Backport r59049:
Fix for #1444: utf_8_sig.StreamReader was (indirectly through decode())
calling codecs.utf_8_decode() with final==True, which falled with incomplete
byte sequences. Fix and test by James G. Sack.
2007-11-19 12:43:39 +00:00
Walter Dörwald ad91c78698 Backport r59047: Fix typo in comment. 2007-11-19 12:23:44 +00:00
Amaury Forgeot d'Arc c572dc3752 Backport for issue1265 (pdb bug with "with" statement).
When an unfinished generator-iterator is garbage collected, PyEval_EvalFrameEx
is called with a GeneratorExit exception set.  This leads to funny results
if the sys.settrace function itself makes use of generators.
A visible effect is that the settrace function is reset to None.
Another is that the eventual "finally" block of the generator is not called.

It is necessary to save/restore the exception around the call to the trace
function.

This happens a lot with py3k: isinstance() of an ABCMeta instance runs
    def __instancecheck__(cls, instance):
        """Override for isinstance(instance, cls)."""
        return any(cls.__subclasscheck__(c)
                   for c in {instance.__class__, type(instance)})
which lets an opened generator expression each time it returns True.

And the problem can be reproduced in 2.5 with pure python code.
2007-11-13 22:43:05 +00:00
Guido van Rossum 809123c61f Issue 1704621. Fix segfaults in list_repeat() and list_inplace_repeat().
The C changes aren't quite the same as the patch given there; the test is.
2007-11-12 20:04:41 +00:00
Christian Heimes 50bbcc27e3 Fixed #1254: pdb fails to launch some script. 2007-11-12 17:28:45 +00:00
Walter Dörwald ad7363bed1 Backport r58942:
Fix TextCalendar.prweek(). This closes issue #1427.
2007-11-12 10:03:39 +00:00
Christian Heimes d66350ad58 Fix for #1427: Error in standard module calendar
merge -r58935:58936 ../trunk
2007-11-12 01:25:08 +00:00
Nick Coghlan e53fcfd7d3 Fix issue #1705170 (backport from trunk) 2007-11-07 12:26:40 +00:00
Gregory P. Smith 2e49f781cb * fix failing test_recno.py - backport from trunk.
* bump _bsddb patch version number.
2007-11-07 07:25:20 +00:00
Gregory P. Smith a1e5387ec5 Backport r58868:
Fixes Issue 1385: The hmac module now computes the correct hmac when using
  hashes with a block size other than 64 bytes (such as sha384 and sha512).
2007-11-06 00:32:04 +00:00
Gregory P. Smith 2c3e0d94b2 Backport r58757, r58758, r58759.
Undoes incorrect dbtables fix and errant strdup introduced as
described below:

r58757 | gregory.p.smith | 2007-11-01 14:08:14 -0700 (Thu, 01 Nov 2007) | 4 lines

Fix bug introduced in revision 58385.  Database keys could no longer
have NULL bytes in them.  Replace the errant strdup with a
malloc+memcpy.  Adds a unit test for the correct behavior.

r58758 | gregory.p.smith | 2007-11-01 14:15:36 -0700 (Thu, 01 Nov 2007) | 3 lines

Undo revision 58533 58534 fixes.  Those were a workaround for
a problem introduced by 58385.

r58759 | gregory.p.smith | 2007-11-01 14:17:47 -0700 (Thu, 01 Nov 2007) | 2 lines

false "fix" undone as correct problem was found and fixed.
2007-11-01 21:22:40 +00:00
Vinay Sajip 5d512fa2e4 Bug #1321: Fixed logic error in TimedRotatingFileHandler.__init__() 2007-10-24 10:49:50 +00:00
Neal Norwitz 4b2a6dbf60 Backport 58618:
Issue 1307 by Derek Shockey, fix the same bug for RCPT.
2007-10-24 03:52:50 +00:00
Neal Norwitz 1046af6f59 Backport 58594:
Issue #1307, patch by Derek Shockey.
When "MAIL" is received without args, an exception happens instead of
sending a 501 syntax error response.
2007-10-23 05:35:11 +00:00
Gregory P. Smith dd4b025ad8 Backport 58539: squelch the warning that this test is intended to raise. 2007-10-19 07:35:22 +00:00
Gregory P. Smith 0dcc3cc949 Backport 58532, 58533, 58534:
- Fix bsddb.dbtables: Don't randomly corrupt newly inserted rows by
   picking a rowid string with null bytes in it.  Such rows could not
   later be deleted, modified or individually selected.  Existing
   bsdTableDb databases created with such rows are out of luck.
 - Use mkdtemp for the test_dbtables test database environment and
   clean it up afterwards using shutil.rmtree.
2007-10-18 17:15:20 +00:00
Gregory P. Smith 574e1ba814 Backport 58450: fix uncollectable reference leak in bsddb.db.DBShelf.append 2007-10-13 23:05:54 +00:00
Gregory P. Smith 137bdfa27a Merge trunk 58434:
Fixes http://bugs.python.org/issue1233 - bsddb.dbshelve.DBShelf.append
was useless due to inverted logic.  Also adds a test case for RECNO dbs
to test_dbshelve.
2007-10-12 18:49:36 +00:00
Gregory P. Smith 7d9c00ec4f Backport 58385 from trunk: fix a double free bug in the _bsddb module
on DBCursor.get (and a friends) when passing in a string key.
2007-10-09 07:25:24 +00:00
Gregory P. Smith 76ee2272ff Backport 58348: use a reliable host in the test. 2007-10-06 15:55:25 +00:00
Sean Reifscheider e8dd31aa2e issue1082: Fixing system and platform names for Vista. 2007-09-17 20:58:46 +00:00
Sean Reifscheider 1644e6ebd1 issue1140: Guido's patch from revision 58098 (2.6) applied to 2.5. 2007-09-17 09:43:11 +00:00
Thomas Heller 5cf6ef84b9 ctypes.util.find_library uses dump(1) instead of objdump(1) on Solaris.
Fixes issue #1777530; backported from trunk.
2007-09-14 20:05:26 +00:00
Georg Brandl fed6bb7d70 Bug #1153: repr.repr() now doesn't require set and dictionary items
to be orderable to properly represent them.
 (backport from rev. 58122)
2007-09-12 19:00:10 +00:00
Gregory P. Smith 339a3ad87a backport of r58023 to fix unit test suite issue1112 on windows 2007-09-06 23:01:32 +00:00
Martin v. Löwis fc787d515d Patch #1031213: Decode source line in SyntaxErrors back to its original
source encoding.
2007-09-04 14:20:25 +00:00
Martin v. Löwis 39f1f45262 Bug #1709599: Run test_1565150 only if the file system is NTFS. 2007-08-30 18:58:29 +00:00
Skip Montanaro 51cf11271f backport r57626 2007-08-28 23:26:55 +00:00
Lars Gustäbel a9bad98e3d TarFile.__init__() no longer fails if no name argument is passed and
the fileobj argument has no usable name attribute (e.g. StringIO).

(backported from r57616)
2007-08-28 12:33:15 +00:00
Skip Montanaro 1ab6a25401 Backport this change to get test_sqlite working on Macs. Same change Thomas
made to the trunk awhile ago I believe.
2007-08-27 03:00:59 +00:00
Gregory P. Smith 838c33268b backport of r57378 to fix bug 1725856 2007-08-24 05:26:15 +00:00
Gregory P. Smith e468ada1e6 Back port of r57286 from py3k and trunk
------------------------------------------------------------------------
  r57286 | gregory.p.smith | 2007-08-22 14:32:34 -0700 (Wed, 22 Aug 2007) | 3 lines

  stop leaving log.0000001 __db.00* and xxx.db turds in developer
  sandboxes when bsddb3 tests are run.
2007-08-23 05:05:12 +00:00
Neal Norwitz b354e3d915 Fix a typo in a comment 2007-08-21 04:55:11 +00:00
Georg Brandl f2944600bd Fix #1771558 (already fixed in trunk). 2007-08-10 17:29:51 +00:00
Georg Brandl eb4b738963 Revert the fix for #1548891, it broke backwards compatibility with arbitrary read buffers.
Fixes #1730114.
 (backport from rev. 56830)
2007-08-08 13:03:45 +00:00
Hye-Shik Chang 36fe3c0a84 Backport from trunk r56727:
Fix gb18030 codec's bug that doesn't map two-byte characters on
GB18030 extension in encoding. (bug reported by Bjorn Stabell)
2007-08-04 04:15:04 +00:00
Martin v. Löwis bd28ca65d6 Bug #1704793: Raise KeyError if unicodedata.lookup cannot
represent the result in a single character.
2007-07-28 07:01:43 +00:00
Martin v. Löwis 088277f290 Change location of the package index to pypi.python.org/pypi. 2007-07-25 16:24:08 +00:00
Andrew M. Kuchling 6ecd4a0535 [Backport of r56382]
Avoid exception if there's a stray directory inside a Maildir folder.

The Maildir specification doesn't seem to say anything about this
situation, and it can happen if you're keeping a Maildir mailbox in
Subversion (.svn directories) or some similar system.  The patch just
ignores directories in the cur/, new/, tmp/ folders.
2007-07-14 22:06:30 +00:00