The problem appears to be that the file in my project is named
profile.py. There is also a profile.py in the python distribution
itself.

I'm assuming that it is a sandboxing restriction(?), that I can't
import my own profile.py in production (even though it works fine in
the dev appserver).

In production,

import profile
print profile.__file__

Shows it is the profile from the python library.

On Jul 5, 12:29 pm, techboy <scot...@gmail.com> wrote:
> I have a webapp.RequestHandler derived class called Profile, in a file
> profile.py. It operates correctly locally. When I deploy to
> production, it fails. If I simply rename the class to a different
> name, it works in production.
>
>  The logs show this for the failure case.
>
> <type 'exceptions.AttributeError'>: Profile instance has no attribute
> 'initialize'
> Traceback (most recent call last):
>   <...snip...>
>   File "/base/python_lib/versions/1/google/appengine/ext/webapp/
> util.py", line 76, in run_wsgi_app
>     result = application(env, _start_response)
>   File "/base/python_lib/versions/1/google/appengine/ext/webapp/
> __init__.py", line 491, in __call__
>     handler.initialize(request, response)
>
> I can work around this problem obviously but I wonder if anyone could
> speculate why is happening.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to