| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Initialize package before calling get_loader() for __main__, so that we do
not incorrectly handle ImportError from __init__.py. When runpy is used from
the Python CLI, use an internal exception rather than ImportError, to avoid
catching an unexpected ImportError.
Also simplify message formatting: str() is redundant with %s.
Also fix test_dash_m_error_code_is_one() in test_cmd_line_script, which was
failing because the test package was not in the current directlry, rather
the desired ValueError.
|
|
|
|
| |
Patch by Serhiy Storchaka.
|
|
|
|
|
|
|
|
|
|
| |
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r85398 | benjamin.peterson | 2010-10-12 20:04:36 -0500 (Tue, 12 Oct 2010) | 1 line
account for the module __dict__ being cleared when its module is
........
|
| |
|
| |
|
|
|
|
| |
code via the runpy module. Also consolidated some script execution functionality in the test harness into a helper module and removed some implementation details from the runpy module documentation.
|
| |
|
|
|
|
| |
this time in a way that leaves the import machinery in a valid state). (Original patch by Andi Vajda)
|
|
|
|
| |
Initial work by Alexander Belopolsky. See Misc/NEWS in this checkin for details.
|
|
|
|
| |
suppress traceback cruft from the implicitly invoked runpy machinery)
|
| |
|
|
|
|
| |
switch
|
|
|
|
| |
switches (better fix coming soon)
|
|
|
|
| |
reported on python-dev by PJE - runpy.run_module now leaves any changes it makes to the sys module intact after the function terminates
|
|
|
|
|
|
| |
tests
Restore Python 2.4 ImportError when attempting to execute a package
(as imports cannot be guaranteed to work properly if you try it)
|
|
|
|
| |
Python 2.6
|
|
|
|
| |
to something else (like '__main__')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
to share common PEP 302 support code, as described here:
http://mail.python.org/pipermail/python-dev/2006-April/063724.html
This revision strips all the PEP 302 emulation code from runpy,
replacing it with published API classes and functions in pkgutil,
mostly using setuptools' implementation of common functionality,
but adding features from runpy, and doing some refactoring to make
the layer pydoc needs easier to implement on top of this.
One step down, four to go, although step #4 (adding C versions of
the new APIs to 'imp') may not be able to make it in time for
alpha 2. We'll see how that goes.
|
| |
|
| |
|
| |
|
|
|