~ubuntu-branches/ubuntu/quantal/python2.7/quantal-updates

« back to all changes in this revision

Viewing changes to debian/patches/make-pydoc-more-robust.diff

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2011-11-30 19:16:23 UTC
  • mfrom: (36.1.5 sid)
  • Revision ID: package-import@ubuntu.com-20111130191623-ov9hszutdakcsnbz
Tags: 2.7.2-8
* Update to 20111130, taken from the 2.7 branch.
* New patch, ctypes-arm, allow for ",hard-float" after libc6 in ldconfig -p
  output (Loic Minier). LP: #898172.
* debian/rules: Define DPKG_VARS (Alban Browaeys). Closes: #647419).
* Add python-config man page (Johann Felix Soden). Closes: #650181).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
--- a/Lib/pydoc.py
2
 
+++ b/Lib/pydoc.py
3
 
@@ -1964,10 +1964,14 @@
4
 
         if modname[-9:] == '.__init__':
5
 
             modname = modname[:-9] + ' (package)'
6
 
         print modname, desc and '- ' + desc
7
 
+    def onerror(modname):
8
 
+        # Ignore non-ImportError exceptions raised whilst trying to
9
 
+        # import modules
10
 
+        pass
11
 
     try: import warnings
12
 
     except ImportError: pass
13
 
     else: warnings.filterwarnings('ignore') # ignore problems during import
14
 
-    ModuleScanner().run(callback, key)
15
 
+    ModuleScanner().run(callback, key, onerror=onerror)
16
 
 
17
 
 # --------------------------------------------------- web browser interface
18