Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | tweak exception message (again) | Brett Cannon | 2013-06-05 | 1 | -2304/+2305 |
| | |||||
* | Issue #9566: Fix compilater warnings on Windows 64-bit | Victor Stinner | 2013-06-04 | 1 | -1/+1 |
| | |||||
* | Issue #9566: Fix compiler warning on Windows 64-bit | Victor Stinner | 2013-06-04 | 1 | -1/+2 |
| | |||||
* | Tweak at the suggestion of Ezio Melotti for exception messages when | Brett Cannon | 2013-06-04 | 1 | -2300/+2302 |
| | | | | EOF is hit while trying to read the header of a bytecode file. | ||||
* | Issue #18065: For frozen packages set __path__ to []. | Brett Cannon | 2013-06-01 | 1 | -4/+2 |
| | | | | | | | Previously __path__ was set to [__name__], but that could lead to bad results if someone managed to circumvent the frozen importer and somehow ended up with a finder that thought __name__ was a legit directory/location. | ||||
* | Issues #18088, 18089: Introduce | Brett Cannon | 2013-05-31 | 1 | -3519/+3511 |
| | | | | | | | | | | | | | | | | | | | | | importlib.abc.Loader.init_module_attrs() and implement importlib.abc.InspectLoader.load_module(). The importlib.abc.Loader.init_module_attrs() method sets the various attributes on the module being loaded. It is done unconditionally to support reloading. Typically people used importlib.util.module_for_loader, but since that's a decorator there was no way to override it's actions, so init_module_attrs() came into existence to allow for overriding. This is also why module_for_loader is now pending deprecation (having its other use replaced by importlib.util.module_to_load). All of this allowed for importlib.abc.InspectLoader.load_module() to be implemented. At this point you can now implement a loader with nothing more than get_code() (which only requires get_source(); package support requires is_package()). Thanks to init_module_attrs() the implementation of load_module() is basically a context manager containing 2 methods calls, a call to exec(), and a return statement. | ||||
* | Rename importlib.util.ModuleManager to module_to_load so that the name | Brett Cannon | 2013-05-30 | 1 | -3509/+3522 |
| | | | | explains better what the context manager is providing. | ||||
* | Issue #18070: importlib.util.module_for_loader() now sets __loader__ | Brett Cannon | 2013-05-28 | 1 | -3432/+3413 |
| | | | | | and __package__ unconditionally in order to do the right thing for reloading. | ||||
* | Update importlib.h | Brett Cannon | 2013-05-28 | 1 | -2676/+2675 |
| | |||||
* | Introduce importlib.util.ModuleManager which is a context manager to | Brett Cannon | 2013-05-28 | 1 | -3328/+3400 |
| | | | | | | | | handle providing (and cleaning up if needed) the module to be loaded. A future commit will use the context manager in Lib/importlib/_bootstrap.py and thus why the code is placed there instead of in Lib/importlib/util.py. | ||||
* | Issue #17917: Use PyModule_AddIntMacro() instead of PyModule_AddIntConstant() | Charles-Francois Natali | 2013-05-20 | 1 | -1/+1 |
| | | | | when applicable. | ||||
* | Issue #17937: Try harder to collect cyclic garbage at shutdown. | Antoine Pitrou | 2013-05-18 | 1 | -0/+1 |
| | |||||
* | Use PY_FORMAT_SIZE_T because Visual Studio does not understand %zd format. | Richard Oudkerk | 2013-05-18 | 1 | -1/+1 |
| | |||||
* | Fix compilater warnings on Windows 64-bit | Victor Stinner | 2013-05-16 | 2 | -4/+4 |
| | |||||
* | Fix a compilater warning on Windows 64-bit | Victor Stinner | 2013-05-16 | 1 | -1/+1 |
| | |||||
* | Fix a compilater warning on Windows 64-bit | Victor Stinner | 2013-05-16 | 1 | -1/+1 |
| | | | | idx variable is used for a tuple indexn so use Py_ssize_t (not int). | ||||
* | fix compilation on Windows | Victor Stinner | 2013-05-16 | 1 | -1/+2 |
| | |||||
* | rather than passing locals to the class body, just execute the class body in ↵ | Benjamin Peterson | 2013-05-16 | 6 | -3157/+3132 |
| | | | | the proper environment | ||||
* | hide the __class__ closure from the class body (#12370) | Benjamin Peterson | 2013-05-15 | 3 | -149/+187 |
| | |||||
* | when an argument is a cell, set the local copy to NULL (see #17927) | Benjamin Peterson | 2013-05-12 | 1 | -8/+4 |
| | |||||
* | #17927: Keep frame from referencing cell-ified arguments. | Guido van Rossum | 2013-05-10 | 1 | -4/+12 |
| | |||||
* | Issue #17912: Use a doubly linked-list for thread states. | Charles-Francois Natali | 2013-05-08 | 1 | -41/+17 |
| | |||||
* | Issue #1545463: At shutdown, defer finalization of codec modules so that ↵ | Antoine Pitrou | 2013-05-08 | 2 | -22/+80 |
| | | | | | | stderr remains usable. (should fix Windows buildbot failures on test_gc) | ||||
* | Fix a compiler warning: use unsigned int type instead of enum PyUnicode_Kind to | Victor Stinner | 2013-05-07 | 1 | -1/+1 |
| | | | | compare two Unicode kinds | ||||
* | Fix a compiler warning: in and out are unused in _Py_char2wchar() if | Victor Stinner | 2013-05-07 | 1 | -1/+1 |
| | | | | HAVE_MBRTOWC is not defined | ||||
* | Issue #1545463: Global variables caught in reference cycles are now ↵ | Antoine Pitrou | 2013-05-06 | 2 | -4/+9 |
| | | | | garbage-collected at shutdown. | ||||
* | Issue #17094: Clear stale thread states after fork(). | Antoine Pitrou | 2013-05-05 | 2 | -8/+57 |
| | | | | | | | Note that this is a potentially disruptive change since it may release some system resources which would otherwise remain perpetually alive (e.g. database connections kept in thread-local storage). | ||||
* | Fix crash caused by 8c1385205a35 | Antoine Pitrou | 2013-05-05 | 1 | -6/+8 |
|\ | | | | | | | (thanks Arfrever for reporting). | ||||
| * | Fix crash caused by 8c1385205a35 | Antoine Pitrou | 2013-05-05 | 1 | -6/+8 |
| | | | | | | | | (thanks Arfrever for reporting). | ||||
* | | #17115: I hate you MS for not supporting C99. | Brett Cannon | 2013-05-04 | 1 | -2/+2 |
| | | |||||
* | | Issue #17408: Avoid using an obsolete instance of the copyreg module when ↵ | Antoine Pitrou | 2013-05-04 | 1 | -3/+1 |
|\ \ | |/ | | | | | the interpreter is shutdown and then started again. | ||||
| * | Issue #17408: Avoid using an obsolete instance of the copyreg module when ↵ | Antoine Pitrou | 2013-05-04 | 1 | -3/+1 |
| | | | | | | | | the interpreter is shutdown and then started again. | ||||
* | | #17115,17116: Have modules initialize the __package__ and __loader__ | Brett Cannon | 2013-05-04 | 2 | -182/+184 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | attributes to None. The long-term goal is for people to be able to rely on these attributes existing and checking for None to see if they have been set. Since import itself sets these attributes when a loader does not the only instances when the attributes are None are from someone overloading __import__() and not using a loader or someone creating a module from scratch. This patch also unifies module initialization. Before you could have different attributes with default values depending on how the module object was created. Now the only way to not get the same default set of attributes is to circumvent initialization by calling ModuleType.__new__() directly. | ||||
* | | Closes #17892: Fix the name of _PyObject_CallMethodObjIdArgs | Alexandre Vassalotti | 2013-05-02 | 1 | -4/+4 |
| | | |||||
* | | check local class namespace before reaching for cells (closes #17853) | Benjamin Peterson | 2013-04-30 | 4 | -121/+157 |
| | | |||||
* | | merge 3.3 (#17863) | Benjamin Peterson | 2013-04-29 | 1 | -9/+8 |
|\ \ | |/ | |||||
| * | ignore errors when trying to fetch sys.stdin.encoding (closes #17863) | Benjamin Peterson | 2013-04-29 | 1 | -9/+8 |
| | | |||||
* | | merge 3.3 | Benjamin Peterson | 2013-04-29 | 1 | -1/+2 |
|\ \ | |/ | |||||
| * | raise an ImportError (rather than fatal) when __import__ is not found in ↵ | Benjamin Peterson | 2013-04-29 | 1 | -1/+2 |
| | | | | | | | | __builtins__ (closes #17867) | ||||
* | | Issue #17832: fix a compilation warning about a function prototype. | Antoine Pitrou | 2013-04-24 | 1 | -1/+2 |
| | | | | | | | | Also, make the private function static. | ||||
* | | Merge #17413: make sure settrace funcs get passed exception instances for ↵ | R David Murray | 2013-04-19 | 1 | -0/+1 |
|\ \ | |/ | | | | | | | | | 'value'. Patch by Ingrid Cheung and Brendan McLoughlin. | ||||
| * | #17413: make sure settrace funcs get passed exception instances for 'value'. | R David Murray | 2013-04-19 | 1 | -0/+1 |
| | | | | | | | | Patch by Ingrid Cheung and Brendan McLoughlin. | ||||
* | | Merge indentation fix from 3.3. | Ezio Melotti | 2013-04-19 | 1 | -6/+6 |
|\ \ | |/ | |||||
| * | Fix indentation. | Ezio Melotti | 2013-04-19 | 1 | -6/+6 |
| | | |||||
* | | Issue #17244: Don't mask exceptions raised during the creation of | Brett Cannon | 2013-04-14 | 1 | -3467/+3479 |
| | | | | | | | | | | | | bytecode files in py_compile. Thanks to Arfrever Frehtes Taifersar Arahesis for the bug report. | ||||
* | | properly lookup the __round__ special method (closes #17722) | Benjamin Peterson | 2013-04-13 | 1 | -14/+11 |
| | | |||||
* | | Issue #15480: Remove the deprecated and unused TYPE_INT64 code from marshal. | Antoine Pitrou | 2013-04-13 | 1 | -46/+1 |
| | | | | | | | | Initial patch by Daniel Riti. | ||||
* | | Issue #17093,17566,17567: Methods from classes in importlib.abc now raise/return | Brett Cannon | 2013-04-09 | 1 | -1769/+1776 |
| | | | | | | | | | | | | | | | | | | | | the default exception/value when called instead of raising/returning NotimplementedError/NotImplemented (except where appropriate). This should allow for the ABCs to act as the bottom/end of the MRO with expected default results. As part of this work, also make importlib.abc.Loader.module_repr() optional instead of an abstractmethod. | ||||
* | | Revert a premature patch for issue #14010 (changeset 846bd418aee5). | Serhiy Storchaka | 2013-04-06 | 1 | -21/+9 |
|\ \ | |/ | |||||
| * | Revert a premature patch for issue #14010 (changeset aaaf36026511). | Serhiy Storchaka | 2013-04-06 | 1 | -21/+9 |
| | |