Show More
@@ -18,8 +18,8 b'' | |||
|
18 | 18 | # RhodeCode Enterprise Edition, including its added features, Support services, |
|
19 | 19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ |
|
20 | 20 | |
|
21 | import pylons | |
|
21 | 22 | import rhodecode |
|
22 | from pylons import config | |
|
23 | 23 | |
|
24 | 24 | from celery.loaders.base import BaseLoader |
|
25 | 25 | |
@@ -36,9 +36,11 b' class PylonsSettingsProxy(object):' | |||
|
36 | 36 | """ |
|
37 | 37 | def __getattr__(self, key): |
|
38 | 38 | pylons_key = to_pylons(key) |
|
39 | proxy_config = rhodecode.PYRAMID_SETTINGS or pylons.config | |
|
39 | 40 | try: |
|
40 |
value = |
|
|
41 |
if key in LIST_PARAMS: |
|
|
41 | value = proxy_config[pylons_key] | |
|
42 | if key in LIST_PARAMS: | |
|
43 | return value.split() | |
|
42 | 44 | return self.type_converter(value) |
|
43 | 45 | except KeyError: |
|
44 | 46 | raise AttributeError(pylons_key) |
@@ -57,7 +59,8 b' class PylonsSettingsProxy(object):' | |||
|
57 | 59 | |
|
58 | 60 | def __setattr__(self, key, value): |
|
59 | 61 | pylons_key = to_pylons(key) |
|
60 |
rhodecode.PYRAMID_SETTINGS |
|
|
62 | proxy_config = rhodecode.PYRAMID_SETTINGS or pylons.config | |
|
63 | proxy_config[pylons_key] = value | |
|
61 | 64 | |
|
62 | 65 | def __setitem__(self, key, value): |
|
63 | 66 | self.__setattr__(key, value) |
@@ -90,4 +93,5 b' class PylonsLoader(BaseLoader):' | |||
|
90 | 93 | from rhodecode.config.middleware import make_pyramid_app |
|
91 | 94 | |
|
92 | 95 | # adding to self to keep a reference around |
|
93 |
self.pyramid_app = make_pyramid_app( |
|
|
96 | self.pyramid_app = make_pyramid_app( | |
|
97 | pylons.config, **pylons.config['app_conf']) |
General Comments 0
You need to be logged in to leave comments.
Login now