equal
deleted
inserted
replaced
20 |
20 |
21 """Pyramid interface to CubicWeb""" |
21 """Pyramid interface to CubicWeb""" |
22 |
22 |
23 import atexit |
23 import atexit |
24 import os |
24 import os |
25 from warnings import warn |
|
26 |
25 |
27 import wsgicors |
26 import wsgicors |
28 |
27 |
29 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg |
28 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg |
30 from pyramid.config import Configurator |
29 from pyramid.config import Configurator |
237 |
236 |
238 config.include('cubicweb.pyramid.core') |
237 config.include('cubicweb.pyramid.core') |
239 |
238 |
240 if asbool(config.registry.settings.get('cubicweb.bwcompat', True)): |
239 if asbool(config.registry.settings.get('cubicweb.bwcompat', True)): |
241 config.include('cubicweb.pyramid.bwcompat') |
240 config.include('cubicweb.pyramid.bwcompat') |
242 |
|
243 if cwconfig.debugmode: |
|
244 try: |
|
245 config.include('pyramid_debugtoolbar') |
|
246 except ImportError: |
|
247 warn('pyramid_debugtoolbar package not available, install it to ' |
|
248 'get UI debug features', RuntimeWarning) |
|