cwconfig.py
branchstable
changeset 4118 8a9a00a9405c
parent 4095 72fd2d4cc782
child 4120 21517d42f2ed
--- a/cwconfig.py	Mon Dec 14 15:35:21 2009 +0100
+++ b/cwconfig.py	Mon Dec 14 16:25:25 2009 +0100
@@ -560,6 +560,15 @@
         self.adjust_sys_path()
         self.load_defaults()
         self.translations = {}
+        # don't register ReStructured Text directives by simple import, avoid pb
+        # with eg sphinx.
+        # XXX should be done properly with a function from cw.uicfg
+        try:
+            from cubicweb.ext.rest import cw_rest_init
+        except ImportError:
+            pass
+        else:
+            cw_rest_init()
 
     def adjust_sys_path(self):
         self.cls_adjust_sys_path()