]> granicus.if.org Git - python/log
python
11 years agoIssue #18266: test_largefile now works with unittest test discovery and
Serhiy Storchaka [Wed, 17 Jul 2013 10:44:17 +0000 (13:44 +0300)]
Issue #18266: test_largefile now works with unittest test discovery and
supports running only selected tests.  Patch by Zachary Ware.

11 years agoIssue #18266: test_largefile now works with unittest test discovery and
Serhiy Storchaka [Wed, 17 Jul 2013 10:42:24 +0000 (13:42 +0300)]
Issue #18266: test_largefile now works with unittest test discovery and
supports running only selected tests.  Patch by Zachary Ware.

11 years agoIssue #17767: test_locale now works with unittest test discovery.
Serhiy Storchaka [Wed, 17 Jul 2013 10:26:48 +0000 (13:26 +0300)]
Issue #17767: test_locale now works with unittest test discovery.
Original patch by Zachary Ware.

11 years agoIssue #17767: test_locale now works with unittest test discovery.
Serhiy Storchaka [Wed, 17 Jul 2013 10:23:45 +0000 (13:23 +0300)]
Issue #17767: test_locale now works with unittest test discovery.
Original patch by Zachary Ware.

11 years agoClose #18469: Replace PyDict_GetItemString() with _PyDict_GetItemId() in structseq.c
Victor Stinner [Tue, 16 Jul 2013 23:22:45 +0000 (01:22 +0200)]
Close #18469: Replace PyDict_GetItemString() with _PyDict_GetItemId() in structseq.c

_PyDict_GetItemId() is more efficient: it only builds the Unicode string once.
Identifiers (dictionary keys) are now created at Python initialization, and if
the creation failed, Python does exit with a fatal error.

Before, PyDict_GetItemString() failure was not handled: structseq_new() could
call PyObject_GC_NewVar() with a negative size, and structseq_dealloc() could
also crash.

11 years agoIssue #18408: Mention changes in Misc/NEWS
Victor Stinner [Tue, 16 Jul 2013 23:10:04 +0000 (01:10 +0200)]
Issue #18408: Mention changes in Misc/NEWS

11 years agoIssue #18408: Handle PyArena_AddPyObject() failure in ast.c
Victor Stinner [Tue, 16 Jul 2013 22:57:58 +0000 (00:57 +0200)]
Issue #18408: Handle PyArena_AddPyObject() failure in ast.c

PyList_Append() (called by PyArena_AddPyObject()) can fail because of a
MemoryError for example.

11 years agoIssue #18408: Fix locale.localeconv(), handle PyDict_SetItemString() failure
Victor Stinner [Tue, 16 Jul 2013 22:55:57 +0000 (00:55 +0200)]
Issue #18408: Fix locale.localeconv(), handle PyDict_SetItemString() failure

11 years agoIssue #18408: Fix PyErr_NormalizeException(), handle PyObject_IsSubclass() failure
Victor Stinner [Tue, 16 Jul 2013 22:44:53 +0000 (00:44 +0200)]
Issue #18408: Fix PyErr_NormalizeException(), handle PyObject_IsSubclass() failure

PyObject_IsSubclass() can fail and raise a new exception!

11 years agoIssue #18408: Fix Python-ast.c: handle init_types() failure (ex: MemoryError)
Victor Stinner [Tue, 16 Jul 2013 22:17:15 +0000 (00:17 +0200)]
Issue #18408: Fix Python-ast.c: handle init_types() failure (ex: MemoryError)

11 years agoIssue #18408: Fix typo in build_node_tree() of the parser module
Victor Stinner [Tue, 16 Jul 2013 22:13:52 +0000 (00:13 +0200)]
Issue #18408: Fix typo in build_node_tree() of the parser module

Type "o" format of Py_BuildValue() is invalid: it must be "O".

11 years agoCleanup type_call() to ease debug
Victor Stinner [Tue, 16 Jul 2013 20:51:21 +0000 (22:51 +0200)]
Cleanup type_call() to ease debug

It was easy to miss the call to type->tp_init because it was done in a long
conditional expression. Split the long expression in multiple lines to make the
debug step by step easier.

11 years agoIssue #18408: handle PySys_GetObject() failure, raise a RuntimeError
Victor Stinner [Tue, 16 Jul 2013 20:26:05 +0000 (22:26 +0200)]
Issue #18408: handle PySys_GetObject() failure, raise a RuntimeError

11 years agoIssue #18408: Py_ReprLeave() now saves/restores the current exception,
Victor Stinner [Tue, 16 Jul 2013 20:24:44 +0000 (22:24 +0200)]
Issue #18408: Py_ReprLeave() now saves/restores the current exception,
and ignores exceptions raised during the call

11 years agoIssue #18408: dict_new() now fails on new_keys_object() error
Victor Stinner [Tue, 16 Jul 2013 20:19:00 +0000 (22:19 +0200)]
Issue #18408: dict_new() now fails on new_keys_object() error

Pass the MemoryError exception to the caller, instead of using empty keys.

11 years agoCleanup dictobject.c
Victor Stinner [Tue, 16 Jul 2013 20:17:26 +0000 (22:17 +0200)]
Cleanup dictobject.c

11 years agoIssue #18408: Fix PyDict_GetItemString(), suppress PyUnicode_FromString() error
Victor Stinner [Tue, 16 Jul 2013 20:16:05 +0000 (22:16 +0200)]
Issue #18408: Fix PyDict_GetItemString(), suppress PyUnicode_FromString() error

As PyDict_GetItem(), PyDict_GetItemString() suppresses all errors that may
occur for historical reasons.

11 years agoIssue #18408: Fix list.extend(), handle list_resize() failure
Victor Stinner [Tue, 16 Jul 2013 19:45:58 +0000 (21:45 +0200)]
Issue #18408: Fix list.extend(), handle list_resize() failure

11 years agoIssue #18408: Fix cjkcodecs decoders, add a new MBERR_EXCEPTION constant to
Victor Stinner [Tue, 16 Jul 2013 19:41:43 +0000 (21:41 +0200)]
Issue #18408: Fix cjkcodecs decoders, add a new MBERR_EXCEPTION constant to
notify exceptions raised by the _PyUnicodeWriter API

11 years agoIssue #18408: Fix fileio_read() on _PyBytes_Resize() failure
Victor Stinner [Tue, 16 Jul 2013 19:36:02 +0000 (21:36 +0200)]
Issue #18408: Fix fileio_read() on _PyBytes_Resize() failure

bytes is NULL on _PyBytes_Resize() failure

11 years agoIssue #18448: Fix a typo in Tools/demo/eiffel.py.
Serhiy Storchaka [Tue, 16 Jul 2013 19:14:03 +0000 (22:14 +0300)]
Issue #18448: Fix a typo in Tools/demo/eiffel.py.

11 years agoIssue #18448: Fix a typo in Tools/demo/eiffel.py.
Serhiy Storchaka [Tue, 16 Jul 2013 19:12:03 +0000 (22:12 +0300)]
Issue #18448: Fix a typo in Tools/demo/eiffel.py.

11 years agoIssue #18457: Fixed saving of formulas and complex numbers in Tools/demo/ss1.py.
Serhiy Storchaka [Tue, 16 Jul 2013 18:58:37 +0000 (21:58 +0300)]
Issue #18457: Fixed saving of formulas and complex numbers in Tools/demo/ss1.py.
Useed context managers for file I/O.
Removed out-of-dated code and misleading comments.

11 years agoIssue #18457: Fixed saving of formulas and complex numbers in Tools/demo/ss1.py.
Serhiy Storchaka [Tue, 16 Jul 2013 18:55:36 +0000 (21:55 +0300)]
Issue #18457: Fixed saving of formulas and complex numbers in Tools/demo/ss1.py.
Useed context managers for file I/O.
Removed out-of-dated code and misleading comments.

11 years agoMerge: Closes #18475: add unittest.main() to test_email/test_inversions.
R David Murray [Tue, 16 Jul 2013 15:46:00 +0000 (11:46 -0400)]
Merge: Closes #18475: add unittest.main() to test_email/test_inversions.

11 years agoCloses #18475: add unittest.main() to test_email/test_inversions.
R David Murray [Tue, 16 Jul 2013 15:45:31 +0000 (11:45 -0400)]
Closes #18475: add unittest.main() to test_email/test_inversions.

Patch by Vajrasky Kok.

11 years agoIssue #17778: Fix test discovery for test_multiprocessing. (Patch by
Richard Oudkerk [Tue, 16 Jul 2013 14:57:16 +0000 (15:57 +0100)]
Issue #17778: Fix test discovery for test_multiprocessing. (Patch by
Zachary Ware.)

11 years agoIssue #17778: Fix test discovery for test_multiprocessing. (Patch by
Richard Oudkerk [Tue, 16 Jul 2013 14:33:41 +0000 (15:33 +0100)]
Issue #17778: Fix test discovery for test_multiprocessing. (Patch by
Zachary Ware.)

11 years agoAlso remove a (broken) leaker test for the code removed in issue #18393.
Ronald Oussoren [Tue, 16 Jul 2013 06:32:05 +0000 (08:32 +0200)]
Also remove a (broken) leaker test for the code removed in issue #18393.

11 years agomerge 3.3
Benjamin Peterson [Tue, 16 Jul 2013 03:50:25 +0000 (20:50 -0700)]
merge 3.3

11 years agomove declaration to top of block
Benjamin Peterson [Tue, 16 Jul 2013 03:50:22 +0000 (20:50 -0700)]
move declaration to top of block

11 years agomerge 3.3 (closes #18470)
Benjamin Peterson [Tue, 16 Jul 2013 03:47:47 +0000 (20:47 -0700)]
merge 3.3 (closes #18470)

11 years agocheck the return value of new_string() (closes #18470)
Benjamin Peterson [Tue, 16 Jul 2013 02:15:34 +0000 (19:15 -0700)]
check the return value of new_string() (closes #18470)

11 years agoCloses #18471: Fix typo in heapq documentation (reported by François Pinard).
Ned Deily [Tue, 16 Jul 2013 02:09:27 +0000 (19:09 -0700)]
Closes #18471: Fix typo in heapq documentation (reported by François Pinard).

11 years agoIssue #18471: Fix typo in heapq documentation (reported by François Pinard).
Ned Deily [Tue, 16 Jul 2013 02:08:13 +0000 (19:08 -0700)]
Issue #18471: Fix typo in heapq documentation (reported by François Pinard).

11 years agoIssue #18408: Fix show_warning(), clear also the exception raised by
Victor Stinner [Mon, 15 Jul 2013 23:54:37 +0000 (01:54 +0200)]
Issue #18408: Fix show_warning(), clear also the exception raised by
_Py_DisplaySourceLine()

For example, _PyGC_DumpShutdownStats() calls PyErr_WarnExplicitFormat() while
the import machinery does not work anymore, _Py_DisplaySourceLine() fails when
trying to import the io module.

11 years agoIssue #18408: add more assertions on PyErr_Occurred() in ceval.c to detect bugs
Victor Stinner [Mon, 15 Jul 2013 23:02:12 +0000 (01:02 +0200)]
Issue #18408: add more assertions on PyErr_Occurred() in ceval.c to detect bugs
earlier

11 years agoIssue #18408: Fix _Py_DisplaySourceLine()
Victor Stinner [Mon, 15 Jul 2013 22:32:14 +0000 (00:32 +0200)]
Issue #18408: Fix _Py_DisplaySourceLine()

Report _Py_FindSourceFile() error, so the error is cleared;
and clear io.open(filename) exception on failure.

11 years agoIssue #18408: Fix PyEval_EvalFrameEx() for MemoryError
Victor Stinner [Mon, 15 Jul 2013 19:16:27 +0000 (21:16 +0200)]
Issue #18408: Fix PyEval_EvalFrameEx() for MemoryError

Don't pass a NULL traceback to PyException_SetTraceback(): pass Py_None.
Passing NULL would raise a new exception.

11 years ago- Issue #18440: Clarify that `hash()` can truncate the value returned from an
Barry Warsaw [Mon, 15 Jul 2013 18:47:29 +0000 (14:47 -0400)]
- Issue #18440: Clarify that `hash()` can truncate the value returned from an
  object's custom `__hash__()` method.

11 years agoIssue #18408: random_seed() now raises a MemoryError on memory allocation
Victor Stinner [Mon, 15 Jul 2013 18:00:36 +0000 (20:00 +0200)]
Issue #18408: random_seed() now raises a MemoryError on memory allocation
failure

11 years agotest_io: check_interrupted_write() now cancels the alarm if ZeroDivisionError
Victor Stinner [Mon, 15 Jul 2013 17:53:13 +0000 (19:53 +0200)]
test_io: check_interrupted_write() now cancels the alarm if ZeroDivisionError
exception was not raised.

Before the process was killed by SIGALRM in another random test (1 second later)

11 years agoIssue #18408: type_new() and PyType_FromSpecWithBases() now raise MemoryError
Victor Stinner [Mon, 15 Jul 2013 17:34:20 +0000 (19:34 +0200)]
Issue #18408: type_new() and PyType_FromSpecWithBases() now raise MemoryError
on memory allocation failure

11 years agoIssue #18408: Don't check unicode consistency in _PyUnicode_HAS_UTF8_MEMORY()
Victor Stinner [Mon, 15 Jul 2013 16:22:47 +0000 (18:22 +0200)]
Issue #18408: Don't check unicode consistency in _PyUnicode_HAS_UTF8_MEMORY()
and _PyUnicode_HAS_WSTR_MEMORY() macros

These macros are called in unicode_dealloc(), whereas the unicode object can be
"inconsistent" if the creation of the object failed.

For example, when unicode_subtype_new() fails on a memory allocation,
_PyUnicode_CheckConsistency() fails with an assertion error because data is
NULL.

11 years agoCloses #18464: fix typo in test name.
R David Murray [Mon, 15 Jul 2013 16:09:47 +0000 (12:09 -0400)]
Closes #18464: fix typo in test name.

11 years agoIssue #18408: PyObject_Call() now fails with an assertion error in debug mode
Victor Stinner [Mon, 15 Jul 2013 15:50:07 +0000 (17:50 +0200)]
Issue #18408: PyObject_Call() now fails with an assertion error in debug mode
if the function called failed whereas no exception was raised, to detect bugs
earlier.

11 years agoIssue #18408: Fix CJK decoders, raise MemoryError on memory allocation failure
Victor Stinner [Mon, 15 Jul 2013 15:47:39 +0000 (17:47 +0200)]
Issue #18408: Fix CJK decoders, raise MemoryError on memory allocation failure

11 years agoIssue #18408: Fix pyexpat.ParserCreate()
Victor Stinner [Mon, 15 Jul 2013 15:15:57 +0000 (17:15 +0200)]
Issue #18408: Fix pyexpat.ParserCreate()

Check if XML_ParserCreate_MM() failed (ex: MemoryError) before using
self->itself.

11 years ago- Issue #18440: Clarify that `hash()` can truncate the value returned from an
Barry Warsaw [Mon, 15 Jul 2013 19:21:41 +0000 (15:21 -0400)]
- Issue #18440: Clarify that `hash()` can truncate the value returned from an
  object's custom `__hash__()` method.

11 years agoIssue #18393: Remove use of deprecated API on OSX
Ronald Oussoren [Mon, 15 Jul 2013 16:32:09 +0000 (18:32 +0200)]
Issue #18393: Remove use of deprecated API on OSX

The "Gestalt" function on OSX is deprecated (starting with OSX 10.8),
remove its usage from the stdlib. The patch removes a number of private
functions and a private module, but does not change the public API.

The removed code was effectively dead, the platform module has used
other code to fetch the OSX version for years and could only use
on the Gestalt-based code as a fallback. That fallback can only trigger
on broken OSX installs (that is, someone has removed parts of the system
install)

11 years agoMerge: Closes #18464: fix typo in test name.
R David Murray [Mon, 15 Jul 2013 16:10:29 +0000 (12:10 -0400)]
Merge: Closes #18464: fix typo in test name.

11 years agoIssue #18344: Fix potential ref-leaks in _bufferedreader_read_all().
Richard Oudkerk [Mon, 15 Jul 2013 15:10:28 +0000 (16:10 +0100)]
Issue #18344: Fix potential ref-leaks in _bufferedreader_read_all().

11 years agoIssue #18344: Fix potential ref-leaks in _bufferedreader_read_all().
Richard Oudkerk [Mon, 15 Jul 2013 15:05:22 +0000 (16:05 +0100)]
Issue #18344: Fix potential ref-leaks in _bufferedreader_read_all().

11 years agoClose issue 17482: don't overwrite __wrapped__
Nick Coghlan [Mon, 15 Jul 2013 11:13:08 +0000 (21:13 +1000)]
Close issue 17482: don't overwrite __wrapped__

11 years agoIssue #18449: Make Tools/demo/ss1.py work again on Python 3. Patch by
Serhiy Storchaka [Mon, 15 Jul 2013 09:37:43 +0000 (12:37 +0300)]
Issue #18449: Make Tools/demo/ss1.py work again on Python 3.  Patch by
Févry Thibault.

11 years agoIssue #18449: Make Tools/demo/ss1.py work again on Python 3. Patch by
Serhiy Storchaka [Mon, 15 Jul 2013 09:34:17 +0000 (12:34 +0300)]
Issue #18449: Make Tools/demo/ss1.py work again on Python 3.  Patch by
Févry Thibault.

11 years agoCloses #18452: fix several "occurrence" typos (reported by Févry Thibault).
Ned Deily [Sun, 14 Jul 2013 19:45:18 +0000 (12:45 -0700)]
Closes #18452: fix several "occurrence" typos (reported by Févry Thibault).

11 years agoIssue #18452: fix several "occurrence" typos (reported by Févry Thibault).
Ned Deily [Sun, 14 Jul 2013 19:43:16 +0000 (12:43 -0700)]
Issue #18452: fix several "occurrence" typos (reported by Févry Thibault).

11 years agoIssue #9893: remove an outdated mention of the Vim-related files.
Brett Cannon [Sun, 14 Jul 2013 13:50:50 +0000 (09:50 -0400)]
Issue #9893: remove an outdated mention of the Vim-related files.

11 years agomerge
Raymond Hettinger [Sun, 14 Jul 2013 05:48:49 +0000 (22:48 -0700)]
merge

11 years agoIssue #18432: Fix unintended API change in the sched module
Raymond Hettinger [Sun, 14 Jul 2013 05:42:09 +0000 (22:42 -0700)]
Issue #18432:  Fix unintended API change in the sched module

11 years agoTweak the deque struct by moving the least used fields (maxlen and weakref) to the...
Raymond Hettinger [Sun, 14 Jul 2013 05:30:25 +0000 (22:30 -0700)]
Tweak the deque struct by moving the least used fields (maxlen and weakref) to the end.

11 years agoUse a do-while loop in the inner loop for rotate (m is always greater than zero).
Raymond Hettinger [Sun, 14 Jul 2013 00:03:58 +0000 (17:03 -0700)]
Use a do-while loop in the inner loop for rotate (m is always greater than zero).

11 years agoMove the freeblock() call outside the main loop to speed-up and simplify the block...
Raymond Hettinger [Sat, 13 Jul 2013 09:34:08 +0000 (02:34 -0700)]
Move the freeblock() call outside the main loop to speed-up and simplify the block re-use logic.

11 years agoMerge with 3.3
Terry Jan Reedy [Sat, 13 Jul 2013 08:06:03 +0000 (04:06 -0400)]
Merge with 3.3

11 years agoIssue #18365: convert buildbot errors to skips.
Terry Jan Reedy [Sat, 13 Jul 2013 08:05:42 +0000 (04:05 -0400)]
Issue #18365: convert buildbot errors to skips.

11 years agoMerge with 3.3
Terry Jan Reedy [Sat, 13 Jul 2013 06:35:07 +0000 (02:35 -0400)]
Merge with 3.3

11 years agoIssue #18279: Add tests for idlelib/RstripExtension.py. Original patch by
Terry Jan Reedy [Sat, 13 Jul 2013 06:34:43 +0000 (02:34 -0400)]
Issue #18279: Add tests for idlelib/RstripExtension.py. Original patch by
Phil Webster. With that available, modify RstripExtension.py to stop deleting
null slices, which caused a file to be marked as changed when it was not.

11 years agoMerge: #18437: fix comment typo.
R David Murray [Sat, 13 Jul 2013 02:56:15 +0000 (22:56 -0400)]
Merge: #18437: fix comment typo.

11 years ago#18437: fix comment typo.
R David Murray [Sat, 13 Jul 2013 02:55:43 +0000 (22:55 -0400)]
#18437: fix comment typo.

11 years agoMerge with 3.3
Terry Jan Reedy [Sat, 13 Jul 2013 00:17:00 +0000 (20:17 -0400)]
Merge with 3.3

11 years agoIssue #18365: normalize whitespace
Terry Jan Reedy [Sat, 13 Jul 2013 00:16:28 +0000 (20:16 -0400)]
Issue #18365: normalize whitespace

11 years agoMerge with 3.3
Terry Jan Reedy [Sat, 13 Jul 2013 00:10:48 +0000 (20:10 -0400)]
Merge with 3.3

11 years agoIssue #18365: Add mock Text class and test thereof versus tk.Text.
Terry Jan Reedy [Sat, 13 Jul 2013 00:10:23 +0000 (20:10 -0400)]
Issue #18365: Add mock Text class and test thereof versus tk.Text.
Based on patches by Todd.Rovito and Phil Webster.

11 years ago#18389: Clarify that relpath does not access the file system.
R David Murray [Fri, 12 Jul 2013 21:43:53 +0000 (17:43 -0400)]
#18389: Clarify that relpath does not access the file system.

Initial patch by Madison May.

11 years ago#18389: Clarify that relpath does not access the file system.
R David Murray [Fri, 12 Jul 2013 21:43:11 +0000 (17:43 -0400)]
#18389: Clarify that relpath does not access the file system.

Initial patch by Madison May.

11 years agoCloses #18433: Merged documentation update from 3.3.
Vinay Sajip [Fri, 12 Jul 2013 20:54:12 +0000 (21:54 +0100)]
Closes #18433: Merged documentation update from 3.3.

11 years agoIssue #18433: Clarified venv documentation.
Vinay Sajip [Fri, 12 Jul 2013 20:52:51 +0000 (21:52 +0100)]
Issue #18433: Clarified venv documentation.

11 years agoMerged changes.
Vinay Sajip [Fri, 12 Jul 2013 20:46:05 +0000 (21:46 +0100)]
Merged changes.

11 years agoIssue #18434: Updated example script to tidy up resources.
Vinay Sajip [Fri, 12 Jul 2013 20:44:35 +0000 (21:44 +0100)]
Issue #18434: Updated example script to tidy up resources.

11 years agoMerged upstream changes.
Vinay Sajip [Fri, 12 Jul 2013 20:19:41 +0000 (21:19 +0100)]
Merged upstream changes.

11 years agoMerged upstream changes.
Vinay Sajip [Fri, 12 Jul 2013 20:18:49 +0000 (21:18 +0100)]
Merged upstream changes.

11 years agoCloses #18435: Merged fix from 3.3.
Vinay Sajip [Fri, 12 Jul 2013 20:13:01 +0000 (21:13 +0100)]
Closes #18435: Merged fix from 3.3.

11 years agoIssue #18435: Replaced simple attribute container class Context with types.SimpleName...
Vinay Sajip [Fri, 12 Jul 2013 20:10:19 +0000 (21:10 +0100)]
Issue #18435: Replaced simple attribute container class Context with types.SimpleNamespace.

11 years agoMerge heads.
R David Murray [Fri, 12 Jul 2013 20:04:18 +0000 (16:04 -0400)]
Merge heads.

11 years agoMerge heads.
R David Murray [Fri, 12 Jul 2013 20:03:44 +0000 (16:03 -0400)]
Merge heads.

11 years agoMerge: #18431: Decode encoded words in atoms in new email parser.
R David Murray [Fri, 12 Jul 2013 20:01:10 +0000 (16:01 -0400)]
Merge: #18431: Decode encoded words in atoms in new email parser.

11 years ago#18431: Decode encoded words in atoms in new email parser.
R David Murray [Fri, 12 Jul 2013 20:00:28 +0000 (16:00 -0400)]
#18431: Decode encoded words in atoms in new email parser.

There is more to be done here in terms of accepting RFC invalid
input that some mailers accept, but this covers the valid
RFC places where encoded words can occur in structured headers.

11 years agoCloses #18434: Merged documentation update from 3.3.
Vinay Sajip [Fri, 12 Jul 2013 19:58:14 +0000 (20:58 +0100)]
Closes #18434: Merged documentation update from 3.3.

11 years agoIssue #18434: Updated example script in venv docs to use setuptools rather than Distr...
Vinay Sajip [Fri, 12 Jul 2013 19:54:25 +0000 (20:54 +0100)]
Issue #18434: Updated example script in venv docs to use setuptools rather than Distribute.

11 years agoIssue #17845: Clarify the message setup.py prints upon successfully
Brett Cannon [Fri, 12 Jul 2013 15:30:32 +0000 (11:30 -0400)]
Issue #17845: Clarify the message setup.py prints upon successfully
building Python but having some optional module which didn't build.

Patch by Yogesh Chaudhari.

11 years agoIssue #18342: Use the repr of a module name for ``from ... import
Brett Cannon [Fri, 12 Jul 2013 15:22:26 +0000 (11:22 -0400)]
Issue #18342: Use the repr of a module name for ``from ... import
...`` when an ImportError occurs.

Other cases had already been switched over to using the repr.

Thanks to Tomasz Maćkowiak for the patch.

11 years agoIssue #18415: Normalize what type of quotes are used with string
Brett Cannon [Fri, 12 Jul 2013 15:04:23 +0000 (11:04 -0400)]
Issue #18415: Normalize what type of quotes are used with string
constants in importlib._bootstrap. Along the way clean up from string
interpolation to use the repr explicitly.

Initial patch by Madison May.

11 years agoIssue #18408: Fix constructors of _elementtree.c
Victor Stinner [Fri, 12 Jul 2013 00:05:17 +0000 (02:05 +0200)]
Issue #18408: Fix constructors of _elementtree.c

* Use Py_DECREF() instead of PyObject_GC_Del() to release correctly all
  resources
* Raise MemoryError on memory allocation failure

11 years agoIssue #18408: Fix create_extra() of _elementtree.c, raise MemoryError on memory
Victor Stinner [Fri, 12 Jul 2013 00:03:34 +0000 (02:03 +0200)]
Issue #18408: Fix create_extra() of _elementtree.c, raise MemoryError on memory
allocation failure

11 years agoIssue #18408: parser module: fix error handling in node2tuple()
Victor Stinner [Thu, 11 Jul 2013 23:35:10 +0000 (01:35 +0200)]
Issue #18408: parser module: fix error handling in node2tuple()

Handle PyLong_FromLong() and PyUnicode_FromString() failures

11 years agoIssue #18408: Fix parser.sequence2st() and parser.tuple2st(): raise MemoryError
Victor Stinner [Thu, 11 Jul 2013 23:33:59 +0000 (01:33 +0200)]
Issue #18408: Fix parser.sequence2st() and parser.tuple2st(): raise MemoryError
on memory allocation failure

Instead of ignoring the memory allocation failure and create invalid objects.

11 years agoIssue #18408: _pickle.c: Add missing PyErr_NoMemory() on memory allocation failures
Victor Stinner [Thu, 11 Jul 2013 22:53:57 +0000 (00:53 +0200)]
Issue #18408: _pickle.c: Add missing PyErr_NoMemory() on memory allocation failures

11 years agoIssue #18408: _PyMemoTable_ResizeTable() now restores the old table if
Victor Stinner [Thu, 11 Jul 2013 22:53:26 +0000 (00:53 +0200)]
Issue #18408: _PyMemoTable_ResizeTable() now restores the old table if
allocating a bigger table failed

PyMemoTable destructor does crash if mt_table is NULL.

11 years agoIssue #18408: pmerge() help of mro_implementation() now raises MemoryError on
Victor Stinner [Thu, 11 Jul 2013 22:42:14 +0000 (00:42 +0200)]
Issue #18408: pmerge() help of mro_implementation() now raises MemoryError on
memory allocation failure

Replace also PyMem_Free() with PyMem_FREE() to be consistent with the rest of
the function.