I doubt this is an issue with the new import or the new gluon.current tread local object. This is probably to the new use of subfolder in models. Do you have subfolders under models/ ?
On May 5, 7:52 pm, Christopher Steel <[email protected]> wrote: > my menu.py in my plugin no longer show up at the apps index and only > display "in" the plugin directory. Is this due to the new current > scope? Is their a way to get this working again or a "current scope" > toggle ? I have a lot of plugins that use this for menu's so any help > on this is very appreciated. > > Thanks, > > Chris > > example, before using something like > > response.menu+= [bla bla] > > in a plugin added the plugin menu to the main menu and it showed up > at: > > http://127.0.0.1:8000/blank/default/index > > Now it only shows up "in" the plugin, for example here: > > http://127.0.0.1:8000/blank/plugin_uc_language/index > > but no longer shows up here: > > http://127.0.0.1:8000/blank/default/index > > SO it does not work with 1.95.1 (2011-05-05 15:15:00) > but does work with 1.95.1 (2011-04-27 ..:..:..) > > On May 4, 5:29 pm, Bruno Rocha <[email protected]> wrote: > > > > > > > > > I am testing right now, at this point I have 2 apps running with no > > problems! > > > models subfolder, custom importer and current scope are great improvements > > to web2py, I am waiting to rely on this for the app I am working now. > > > Thank you Massimo and Jonathan (of course all the other collaborators), > > @web2py "the framework that evolves every two weeks" > > > -- > > Bruno Rocha > > [ About me:http://zerp.ly/rochacbruno] > > > On Wed, May 4, 2011 at 6:09 PM, Massimo Di Pierro > > <[email protected]>wrote: > > > > Hello everybody.... > > > > Jonathan and I have been working on an internal web2py rewrite that while > > > keeping everything backward compatible will allow you to do this > > > > ==== modules/mymodule.py > > > from gluon import * > > > def f(): return DIV(A(current.request.function,_href=URL())) > > > ==== end > > > > ==== default/controller.py > > > def index(): > > > from mymodule import f > > > return dict(div=f()) > > > ==== end > > > > Thanks to Pierre we can now import modules from the app local folder > > > without local_import and thanks to Jonathan those modules only need to do > > > "from gluon import *" to see everything web2py has to offer. This should > > > make life easier for Eclipse users too. > > > > In models/db.py you no longer need to pass globals() to Auth > > > > auth=Auth(globals(),db) > > > or > > > auth=Auth(db) > > > > both work. > > > > Also error messages in validators (including default error messages) > > > should > > > not be by T(...) by default. > > > > This is now in trunk but we are still working on it. This means trunk may > > > not very stable for the next day or two. > > > Meanwhile help us test it. In particular help us test if we are breaking > > > your apps. > > > > Massimo

