Tuesday 15 July 2014

python - App engine read DataStore data between modules -



python - App engine read DataStore data between modules -

i have app divided in 5 modules (see beautiful ascii art) each have own directory, this structure

appengine app <--here's dispatch.yaml --------------------- | | | | | | | | | | mod1 mod2 mod3 mod4 mod5 ^ ^ \__here's models |__ here wanna read models .py file __init__.py

the ndb models defined in 1 module (mod1 example) , wanna read info in mod5, official documentation says that's posible, can't it. i'm importing model in ways

#this in mod5 py file import mod1.models # no module named mod1.models path.mod1 import models #no module named path.mod1 mod1 import models #no module named mod1 mod1.models import specific_model #no module named mod1.models path.models import specific_model #no module named path.models

i alter --storage_path setting each module able tu run modules @ same time in launcher, think problem. if leave same directory how can run @ same time modules (i got "operationalerror: database locked" error) clue here?

based on given information, wondering if missing __init__.py file in each of subdirectories. allow python modules usable in directorie. see https://docs.python.org/2/tutorial/modules.html#packages

can share file construction in directories?

python google-app-engine module app-engine-ndb gae-module

No comments:

Post a Comment