[web2py] Create databases folder
Isn't web2py supposed to create the databases, sessions, uploads, etc folders if they don't exist? -- Thadeus
Re: [web2py] Create databases folder
2011/2/4 Thadeus Burgess thade...@thadeusb.com Isn't web2py supposed to create the databases, sessions, uploads, etc folders if they don't exist? in which case? running from terminal I do: ## $ python web2py.py -S myapp -M -P web2py Enterprise Web Framework Created by Massimo Di Pierro, Copyright 2007-2011 Version 1.91.6 (2011-01-30 18:30:25) Database drivers available: SQLite3, pymysql, CouchDB application myapp does not exist, create (y/n)?y ## web2py created the files for me: ### $ pwd ../web2py/applications/myapp $ ls ABOUT controllers databases __init__.py LICENSE modules sessions uploads cache cron errors languagesmodels private static views if I delete i.e session folder ## $ rm -R sessions/ $ ls ABOUT controllers databases __init__.py LICENSE modules static views cache cron errors languagesmodels private uploads # then I run web2py again ## $python web2py.py -a 1234 ## Sessions folder is created for me ## $ ls ABOUT controllers databases __init__.py LICENSE modules sessions uploads cache cron errors languagesmodels private static views ### I tried with database and upload, all running fine using web2py from trunk.
Re: [web2py] Create databases folder
I now removed ['cache','cron','uploads','databases','sessions'] ran web2py and it created all folders for me.
Re: [web2py] Create databases folder
Nope not working for me. A raw checkout of a branch, there is no NEWINSTALL file, nor a welcome.w2p file since we don't need it. The app only contains controllers, cron, languages, models, modules, static, tests, views, __init__.py. From this state, when starting web2py just by python web2py.py. Navigate to the app in firefox or other web browser, and it crashes because it cannot connect to the sqlite database 5 times, this is because the databases folder does not exist from a raw checkout of our app, and web2py does not seem to be creating any of the folders. If I navigate into my app directory, and run ``mkdir databases`` then navigate to the app, everything is fine, and web2py ends up making the uploads, private, cache, sessions, and errors folders. -- Thadeus On Fri, Feb 4, 2011 at 12:06 PM, Bruno Rocha rochacbr...@gmail.com wrote: I now removed ['cache','cron','uploads','databases','sessions'] ran web2py and it created all folders for me.
Re: [web2py] Create databases folder
On Feb 4, 2011, at 1:19 PM, Thadeus Burgess wrote: Nope not working for me. A raw checkout of a branch, there is no NEWINSTALL file, nor a welcome.w2p file since we don't need it. The app only contains controllers, cron, languages, models, modules, static, tests, views, __init__.py. From this state, when starting web2py just by python web2py.py. Navigate to the app in firefox or other web browser, and it crashes because it cannot connect to the sqlite database 5 times, this is because the databases folder does not exist from a raw checkout of our app, and web2py does not seem to be creating any of the folders. If I navigate into my app directory, and run ``mkdir databases`` then navigate to the app, everything is fine, and web2py ends up making the uploads, private, cache, sessions, and errors folders. Odd. The admin.create_missing_app_folders() call in main.wsgibase should be creating the folder. Could you throw a couple of strategic debug prints into that function and see what's going on?