From d2e8ec96084a26127907fe1cee2f15871d67b60d Mon Sep 17 00:00:00 2001
From: Julien Olivain <Jullien.Olivain@lacime.etsmtl.ca>
Date: Mon, 18 Feb 2013 16:01:46 -0500
Subject: GRC: adds ability for grc to pull in documentation for blocks from
 other GR modules.

---
 grc/python/extract_docs.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

(limited to 'grc/python/extract_docs.py')

diff --git a/grc/python/extract_docs.py b/grc/python/extract_docs.py
index a7e945c373..33c4043622 100644
--- a/grc/python/extract_docs.py
+++ b/grc/python/extract_docs.py
@@ -31,7 +31,13 @@ def _extract(key):
 		module_name, constructor_name = key.split('_', 1)
 		module = __import__('gnuradio.'+module_name)
 		module = getattr(module, module_name)
-	except: return ''
+        except ImportError:
+                try:
+                        module_name, constructor_name = key.split('_', 1)
+                        module = __import__(module_name)
+                except: return ''
+	except:
+                return ''
 	pattern = constructor_name.replace('_', '_*').replace('x', '\w')
 	pattern_matcher = re.compile('^%s\w*$'%pattern)
 	matches = filter(lambda x: pattern_matcher.match(x), dir(module))
-- 
cgit v1.2.3