On Dec 22, 2010, at 8:20 AM, Jonathan Lundell wrote:
> 
> I think that's right, Bruno. The missing-folder logic got factored out, 
> because it wasn't being invoked for any server except Rocket, but it 
> shouldn't run for GAE. However, we still want the sys.path logic, so the fix 
> should look more like this:
> 
> def create_missing_folders():
>    if not request.env.web2py_runtime_gae:
>        for path in ('applications', 'deposit', 'site-packages', 'logs'):
>            path = abspath(path, gluon=True)
>            if not os.path.exists(path):
>                os.mkdir(path)
>    paths = (global_settings.gluon_parent, abspath('site-packages', 
> gluon=True), "")
>    [add_path_first(path) for path in paths]

That should be:

def create_missing_folders():
   if not global_settings.web2py_runtime_gae:
       for path in ('applications', 'deposit', 'site-packages', 'logs'):
           path = abspath(path, gluon=True)
           if not os.path.exists(path):
               os.mkdir(path)
   paths = (global_settings.gluon_parent, abspath('site-packages', gluon=True), 
"")
   [add_path_first(path) for path in paths]

Reply via email to