The same for me. I have a file called "validators.py" in modules folder. And when I try import it web2py imports gluon/validators.py
2013 m. liepa 9 d., antradienis 19:38:30 UTC+3, Frederick Yankowski rašė: > > I have an app with a modules/utils.py file that I would import into the > controllers as "import utils" and access as "utils.whatever()". That was > working fine until I upgraded to web2py 2.5.1 today. Now my app seems to be > importing the gluon/utils.py module instead of my app-local one. It's then > failing badly for obvious reasons. I tried renaming my local utils.py to > calendar.py and that then got shadowed by some calendar module in sys.path > and also failed. > > The web2py book says "import test looks for the module first in the > current app's modules folder, then in the folders listed in sys.path. > Therefore, app-level modules always take precedence over Python modules. > This allows different apps to ship with different versions of their > modules, without conflicts." > > But that no longer seems to be working as advertised (and as it did > before). > > This seems like serious problem. It's not a backward compatible change, > for sure. I can rename my utils.py to some really obscure name to reduce > the chance of a name collision but that seems bogus. Am I missing > something? Is this not a serious defect? > > -Fred > > -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

