you are doing it correctly for normal django.
its something to do with the Poll model that you are getting from
google app engine
sorry I can't help more than that.
-felix
jseleuco wrote:
> Hi all,
>
> Just started today with the Python, Django and Google app engine and
> having some novice problems as well :)
>
>
> def detail(request, poll_id):
> p = get_object_or_404(Poll, pk=poll_id)
> return render_to_response('polls/detail.html', {'poll': p})
>
>
> The get_object_or_404 method is crashing, which i really dont
> understand why.
>
>
>
>
> Traceback (most recent call last):
> File "C:\Program Files\Google\google_appengine\lib\django\django\core
> \handlers\base.py" in get_response
> 77. response = callback(request, *callback_args, **callback_kwargs)
> File "D:\monopolio\polls\views.py" in detail
> 13. p = get_object_or_404(Poll, pk=poll_id)
> File "C:\Program Files\Google\google_appengine\lib\django\django
> \shortcuts\__init__.py" in get_object_or_404
> 20. return manager.get(*args, **kwargs)
>
> TypeError at /polls/1/
> get() got an unexpected keyword argument 'pk'
>
>
>
>
>
> I've tried to rename 'pk' to other things but always getting the same
> TypeError..
> Im using the Django helper for the 0.96 version, running it on the
> Google app SDK.
>
> What Im missing?
>
> thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" 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/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---