summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Issue #18076: Introduce imoportlib.util.decode_source().Brett Cannon2013-06-166-3554/+3611
| | | | | | | The helper function makes it easier to implement imoprtlib.abc.InspectLoader.get_source() by making that function require just the raw bytes for source code and handling all other details.
* importlib.abc.SourceLoader.get_source() was re-raising SyntaxError andBrett Cannon2013-06-164-1730/+1718
| | | | | | | | | UnicodeDecodeError as ImportError. That was over-reaching the point of raising ImportError in get_source() (which is to signal the source code was not found when it should have). Conflating the two exceptions with ImportError could lead to masking errors with the source which should be known outside of whether there was an error simply getting the source to begin with.
* Issue #18115: Abstract out managing the cleanup of modules to use inBrett Cannon2013-06-162-2461/+2491
| | | | loaders where C code provides the loaded module.
* Check that warnings.showwarning() is not changed.Brett Cannon2013-06-161-1/+6
|
* Issues #18058, 18057: Make importlib._bootstrap.NamespaceLoaderBrett Cannon2013-06-165-1079/+1156
| | | | | conform the the InspectLoader ABC. Perk of this is that runpy/-m can now work with namespace packages.
* mergeBrett Cannon2013-06-165-15/+41
|\
| * Merge with 3.3Andrew Kuchling2013-06-165-15/+41
| |\
| | * Describe 'surrogateescape' in the documentation.Andrew Kuchling2013-06-165-15/+41
| | | | | | | | | | | | | | | | | | Also, improve some docstring descriptions of the 'errors' parameter. Closes #14015.
* | | Issue #17177: The imp module is pending deprecation.Brett Cannon2013-06-1615-85/+103
|/ / | | | | | | | | | | To make sure there is no issue with code that is both Python 2 and 3 compatible, there are no plans to remove the module any sooner than Python 4 (unless the community moves to Python 3 solidly before then).
* | Stop using the deprecated unittest.TestCase.assertRaisesRegexp()Brett Cannon2013-06-161-5/+5
| |
* | Make test_builtin work when executed directlyBrett Cannon2013-06-161-1/+4
| |
* | Prevent a possible double close of parent pipe fds when the subprocessGregory P. Smith2013-06-162-18/+29
|\ \ | |/ | | | | | | exec runs into an error. Prevent a regular multi-close of the /dev/null fd when any of stdin, stdout and stderr was set to DEVNULL.
| * news entry for subprocess double close fix.Gregory P. Smith2013-06-161-0/+4
| |
| * Prevent a possible double close of parent pipe fds when the subprocessGregory P. Smith2013-06-161-18/+25
| | | | | | | | | | exec runs into an error. Prevent a regular multi-close of the /dev/null fd when any of stdin, stdout and stderr was set to DEVNULL.
* | Issue #17177: stop using imp in test_importlibBrett Cannon2013-06-1516-76/+78
| |
* | Issue #17177: update checkpyc to stop using impBrett Cannon2013-06-151-4/+4
| |
* | Issue # 17177: Stop using imp in setup.pyBrett Cannon2013-06-151-2/+3
| |
* | Issue # 17177: Stop using imp in turtledemoBrett Cannon2013-06-151-1/+1
| |
* | Issue #17177: Stop using imp in zipfileBrett Cannon2013-06-152-5/+5
| |
* | Issue #17177: Stop using imp in a bunch of testsBrett Cannon2013-06-157-15/+17
| |
* | Merge with 3.3Andrew Kuchling2013-06-153-0/+20
|\ \ | |/
| * #18113: Objects associated to a curses.panel object with set_userptr() were ↵Andrew Kuchling2013-06-153-0/+20
| | | | | | | | | | | | leaked. Reported by Atsuo Ishimoto.
* | Issue #17177: Stop using imp in sysconfigBrett Cannon2013-06-151-2/+2
| |
* | Issue #17177: switch from imp.new_module to types.ModuleType for runpyBrett Cannon2013-06-151-1/+2
| |
* | Issue #17177: Stop using imp in pydocBrett Cannon2013-06-151-5/+4
| |
* | Issue #17177: Stop using imp with py_compileBrett Cannon2013-06-152-5/+6
| |
* | mergeBrett Cannon2013-06-151-2/+2
|\ \
| * | Fix typo; clarify that the methods were removed entirelyAndrew Kuchling2013-06-151-2/+2
| | |
* | | merge w/ 3.3Brett Cannon2013-06-153-2/+2
|\ \ \ | |/ / |/| / | |/
| * Drop some dead imports of impBrett Cannon2013-06-153-2/+2
| |
* | Issue #17177: Stop using imp in multiprocessingBrett Cannon2013-06-151-2/+2
| |
* | Issue #17177: Stop using imp in distutilsBrett Cannon2013-06-157-22/+26
| |
* | Issue #17177: stop using imp for compileall.Brett Cannon2013-06-152-32/+29
| |
* | make test more robust under WindowsBrett Cannon2013-06-151-1/+1
| |
* | Issue #17177: Update the programming FAQ to use importlibBrett Cannon2013-06-151-5/+5
| |
* | Move something to the right section of What's NewBrett Cannon2013-06-151-4/+6
| |
* | Issue #18194: Introduce importlib.util.cache_from_source() andBrett Cannon2013-06-152-2/+37
| | | | | | | | | | source_from_cache(), finishing the work introduced in changset 4134:9cacdb9d0c59.
* | Make it more obvious what things used in imp are snuck in through private APIsBrett Cannon2013-06-151-11/+8
| |
* | Issue #17907: touch up the code for imp.new_module().Brett Cannon2013-06-158-3544/+3686
| |
* | Fix markup of the synopsis along with changing to state what is in theBrett Cannon2013-06-151-2/+2
| | | | | | | | module and not as a definition of what an enumeration is.
* | Merge headsVictor Stinner2013-06-156-2/+1964
|\ \
| * | Closes issue 17947. Adds PEP-0435 (Adding an Enum type to the Python ↵Ethan Furman2013-06-144-0/+1930
| | | | | | | | | | | | | | | | | | | | | standard library). Missing files added. News entry added.
| * | Issue #17907: Document types.ModuleType's constructor and attributes,Brett Cannon2013-06-143-2/+34
| | | | | | | | | | | | allowing for documenting imp.new_module() as deprecated.
* | | Revert changeset 6661a8154eb3: Issue #3329: Add new APIs to customize memory ↵Victor Stinner2013-06-156-772/+212
|/ / | | | | | | | | | | allocators The new API require more discussion.
* | Issue #18192: Introduce importlib.util.MAGIC_NUMBER and document theBrett Cannon2013-06-148-8/+37
| | | | | | | | deprecation of imp.get_magic().
* | Issue #3329: Add new APIs to customize memory allocatorsVictor Stinner2013-06-146-212/+772
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add a new PyMemAllocators structure * New functions: - PyMem_RawMalloc(), PyMem_RawRealloc(), PyMem_RawFree(): GIL-free memory allocator functions - PyMem_GetRawAllocators(), PyMem_SetRawAllocators() - PyMem_GetAllocators(), PyMem_SetAllocators() - PyMem_SetupDebugHooks() - _PyObject_GetArenaAllocators(), _PyObject_SetArenaAllocators() * Add unit test for PyMem_Malloc(0) and PyObject_Malloc(0) * Add unit test for new get/set allocators functions * PyObject_Malloc() now falls back on PyMem_Malloc() instead of malloc() if size is bigger than SMALL_REQUEST_THRESHOLD, and PyObject_Realloc() falls back on PyMem_Realloc() instead of realloc() * PyMem_Malloc() and PyMem_Realloc() now always call malloc() and realloc(), instead of calling PyObject_Malloc() and PyObject_Realloc() in debug mode
* | mergeBrett Cannon2013-06-145-3/+32
|\ \
| * | Issue #18149: Add filecmp.clear_cache() to manually clear the filecmp cache.Ned Deily2013-06-145-3/+32
| | | | | | | | | | | | Patch by Mark Levitt
* | | Issue #17222: Raise FileExistsError when py_compile.compile wouldBrett Cannon2013-06-145-1/+52
|/ / | | | | | | overwrite a symlink or non-regular file with a regular file.
* | Issue #18193: Add importlib.reload(), documenting (but notBrett Cannon2013-06-146-24/+122
| | | | | | | | | | | | implementing in code) the deprecation of imp.reload(). Thanks to Berker Peksag for the patch.