Commits

Anonymous committed adad2eb

Fixed the missing module imports.

Comments (0)

Files changed (1)

celerypylons/loader.py

 to_celery = lambda x: x.replace('.', '_').upper()
 
 
+LIST_PARAMS = """CELERY_IMPORTS""".split()
+
 class PylonsSettingsProxy(object):
     """
     Proxies settings from pylons.config
         pylons_key = to_pylons(key)
         try:
             value = config[pylons_key]
-            if len(value.split()) > 1: return value.split()
+            if key in LIST_PARAMS: return value.split()
             return value
         except KeyError:
             raise AttributeError(pylons_key)
         Import task modules.
         """
         # @@ Patch for when user only provides 1 module
-        celery_imports = config.get('celery.imports', [])
-        if isinstance(celery_imports, types.StringTypes):
-            config['celery.imports'] = [celery_imports]
-        self.import_default_modules()
+        print self.import_default_modules()