From 43415ba5717fcdac45c36f6880e90a114dd538ad Mon Sep 17 00:00:00 2001 From: Martin Panter Date: Sat, 7 Nov 2015 05:41:47 +0000 Subject: Issue #18010: Fix pydoc GUI search to handle package exceptions --- Lib/pydoc.py | 5 ++++- Misc/NEWS | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Lib/pydoc.py b/Lib/pydoc.py index d7396f0..9316fff 100755 --- a/Lib/pydoc.py +++ b/Lib/pydoc.py @@ -2244,8 +2244,11 @@ def gui(): if self.scanner: self.scanner.quit = 1 self.scanner = ModuleScanner() + def onerror(modname): + pass threading.Thread(target=self.scanner.run, - args=(self.update, key, self.done)).start() + args=(self.update, key, self.done), + kwargs=dict(onerror=onerror)).start() def update(self, path, modname, desc): if modname[-9:] == '.__init__': diff --git a/Misc/NEWS b/Misc/NEWS index c9dbb46..6f056b2 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -46,6 +46,9 @@ Core and Builtins Library ------- +- Issue #18010: Fix the pydoc GUI's search function to handle exceptions + from importing packages. + - Issue #25515: Always use os.urandom as a source of randomness in uuid.uuid4. - Issue #21827: Fixed textwrap.dedent() for the case when largest common -- cgit v0.12