Hi,
I'm trying to follow the google-app-engine-django sample, these are steps
that I did:
1. models.py:
from appengine_django.models import BaseModel
from google.appengine.ext import db
class Poll(BaseModel):
question = db.StringProperty()
pub_date = db.DateTimeProperty('date published')
class Choice(BaseModel):
poll = db.ReferenceProperty(Poll)
choice = db.StringProperty()
votes = db.IntegerProperty()
2. python manage.py shell
3. >>> from mysite.polls.models import Poll, Choice
Then got this error:
WARNING:root:Could not initialize images API; you are likely missing the
Python
"PIL" module. ImportError: No module named _imaging
Python 2.5.4 (r254
<http://code.google.com/p/google-app-engine-django/source/detail?r=254>:67916,
Dec 23 2008, 15:10:54) [MSC v.1310 32 bit
(Intel)] on
win32
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> from mysite.polls.models import Poll, Choice
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "D:\mysite\polls\models.py", line 9, in <module>
class Choice(BaseModel):
File "D:\mysite\appengine_django\models.py", line 131, in __init__
super(PropertiedClassWithDjango, cls).__init__(name, bases, attrs)
File "C:\Program
Files\Google\google_appengine\google\appengine\ext\db\__init_
_.py", line 319, in __init__
_initialize_properties(cls, name, bases, dct)
File "C:\Program
Files\Google\google_appengine\google\appengine\ext\db\__init_
_.py", line 270, in _initialize_properties
attr.__property_config__(model_class, attr_name)
File "C:\Program
Files\Google\google_appengine\google\appengine\ext\db\__init_
_.py", line 2546, in __property_config__
self.collection_name))
DuplicatePropertyError: Class Model already has property choice_set
Anyone know why ?
Thanks
~Ferry
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---