Reputation: 65
I am having an application developed in python and google app engine, but when i am try to customize this application then it is giving me compile time error in the previous code which is running fine on live. Code is:
if version in ['beta', 'alpha'] :
type=version
version = memcache.get(type)
if not version:
v = RouterVersions.get_by_key_name(type)
if not v :
logging.error('No version found in RouterModel for %s', type)
self.error(404)
return;
version = v.version
memcache.add(v.type, version)
whenver i am using memcache.add or get property it is giving compile time error "undefined variable from import get". I am not able to know why is it so. I am new to python and google app engine. My application was created in python 2.5 and i am using 2.7 now. Is that the issue or something else ?
Upvotes: 3
Views: 652
Reputation: 16890
Did you perhaps name a file memcache.py? If so remove it and also memcache.pyc.
Upvotes: 8