I have the following directory structure for my GAE project:
project:
- library:
- lib1.py
- lib2/x.py
- lib2/y.py
- apps:
- app1/app1.py
- app2/app2.py
- app2/async.py
how do I make the library folder visible to any app that will ever be created in the apps dir and its subdirs?
PYTHONPATH specifies a series of folders to start searches for imported modules.
GAE adds the folder that contains app.yaml to your PYTHONPATH.
So assuming that app.yaml is in the root of that structure (ie the folder that contains “library” and “apps”) then any of your apps can import relative to there…