This has been driving me nuts for the better part of 3 days. I'm trying to organize my Python code, but when I move .py files out of the app's root directory, the production servers seem to be unable to import them. Yet it works perfectly fine on my local dev_appserver.
Say I create a directory called "code" in the app root. I put a file "mymodule.py" in there. (There is also a blank __init__.py in "code" to make sure Python recognizes "code" as a module -- not sure if this is necessary or not, but it's there). Now I can import App Engine modules fine. And I can import any modules that are in the app's root directory. But as soon as I try "import code.mymodule", the Production Server freaks out: <type 'exceptions.ImportError'>: No module named mymodule Traceback (most recent call last): File "/base/data/home/apps/rescue2012/1.330013328833611377/ handler.py", line 4, in <module> import code.mymodule This works just fine on my local development server. It finds "mymodule.py" in "code", creates the .pyc, and uses it perfectly. Am I doing something wrong, or is this a bug in GAE? I know people are including libraries (newer versions of Django, etc.) in their apps, so I'm not the only person trying this. Please reveal my stupidity. Thank you in advance. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~----------~----~----~----~------~----~------~--~---