56 Commits

Author SHA1 Message Date
Eric Snow
d5f9223981 Issue #17211: Yield a namedtuple in pkgutil.
Patch by Ramchandra Apte.
2016-09-07 18:37:17 -07:00
Senthil Kumaran
56b4872ff5 [merge from 3.5] - Update pkgutil docs to reference appropriate finder and loader object documentation.
Initial patch contributed by Jaysinh shukla.
2016-09-05 17:16:06 -07:00
Senthil Kumaran
4672060d86 Update pkgutil docs to reference appropriate finder and loader object documentation.
Initial patch contributed by Jaysinh shukla.
2016-09-05 17:11:51 -07:00
Brett Cannon
fdcdd9ed80 Issue #26896: Disambiguate uses of "importer" with "finder".
Thanks to Oren Milman for the patch.
2016-07-08 11:00:00 -07:00
Łukasz Langa
34ad2ef8f9 Merge 3.5, issue #14209 2016-06-11 18:05:42 -07:00
Łukasz Langa
0d18c15fbf Issue #14209: pkgutil.iter_zipimport_modules ignores the prefix for packages
Patch by James Pickering.
2016-06-11 18:02:46 -07:00
Brett Cannon
c0d91aff9a Upgrade the imp module's deprecation to DeprecationWarning. 2015-10-16 12:21:37 -07:00
Brett Cannon
2a17bde930 Issue #20383: Introduce importlib.util.module_from_spec().
Along the way, dismantle importlib._bootstrap._SpecMethods as it was
no longer relevant and constructing the new function required
partially dismantling the class anyway.
2014-05-30 14:55:29 -04:00
Brett Cannon
8447c703d1 Issue #14710: Fix both pkgutil.find_loader() and get_loader() to not
raise an exception when a module doesn't exist.

Thanks to Pavel Aslanov for the bug report.
2014-05-23 12:30:37 -04:00
Eric Snow
658af31372 Issue #21200: Return None from pkgutil.get_loader() when __spec__ is missing. 2014-04-19 00:13:23 -06:00
Nick Coghlan
62b4b9eecb Close #20839: pkgutil.find_loader now uses importlib.util.find_spec 2014-03-04 20:39:42 +10:00
Eric Snow
6029e08691 Issue 19944: Fix importlib.find_spec() so it imports parents as needed.
The function is also moved to importlib.util.
2014-01-25 15:32:46 -07:00
Eric Snow
02b9f9d6bb Remove more usage of APIs deprecated by PEP 451. 2014-01-06 20:42:59 -07:00
Eric Snow
37148b27ac Issue #19708: Update pkgutil to use the new importer APIs. 2014-01-04 15:09:53 -07:00
Eric Snow
b523f8433a Implement PEP 451 (ModuleSpec). 2013-11-22 09:05:39 -07:00
Nick Coghlan
862542e500 Close #19409: add missing import in pkgutil 2013-10-27 00:27:39 +10:00
Brett Cannon
e4f41deccf Issue #17177: The imp module is pending deprecation.
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).
2013-06-16 13:13:40 -04:00
Łukasz Langa
6f69251980 Add reference implementation for PEP 443
PEP accepted: http://mail.python.org/pipermail/python-dev/2013-June/126734.html
2013-06-05 12:20:24 +02:00
Nick Coghlan
685bd4a37a Merge fix for #16163 from 3.3 2013-04-14 23:01:11 +10:00
Nick Coghlan
c4e0d982f3 Close issue #16163: handle submodules in pkgutil.iter_importers 2013-04-14 22:30:42 +10:00
Giampaolo Rodola'
2f50aaf2ff modernize some modules' code by using with statement around open() 2013-02-12 02:04:27 +01:00
Andrew Svetlov
f7a17b48d7 Replace IOError with OSError (#16715) 2012-12-25 16:47:37 +02:00
Andrew Svetlov
fd43b4d3e4 replace threw with raised (#16714) 2012-12-19 22:55:40 +02:00
Andrew Svetlov
1f415cf2c2 replace threw with raised (#16714) 2012-12-19 22:54:47 +02:00
Andrew Svetlov
a191959849 Issue #16714: use 'raise' exceptions, don't 'throw'.
Patch by Serhiy Storchaka.
2012-12-18 21:27:16 +02:00