Ticket #161 (closed enhancement: fixed)

Opened 2 years ago

Last modified 2 years ago

Dictionary access method screws over django users

Reported by: http://fitzsimmons.ca/ Assigned to:
Priority: major Milestone:
Keywords: Cc:
Project: python-openid OpenID Protocol:
Series: 2.x.x Web Browser:

Description

This code, from message.py doesn't allow django users to simply pass something like request.GET into the server decodeRequest function.

for key, value in args.iteritems():
    if isinstance(value, list):
        raise TypeError("query dict must have one value for each key, "not lists of values.  Query is %r" % (args,))

Something like

for key in args.iterkeys(): 
    if isinstance(args[key], list):

would increase compatibility.

Change History

05/20/08 12:16:01 changed by http://j3h.us/

  • project set to python-openid.
  • series set to 2.x.x.

05/29/08 11:37:56 changed by https://keturn.myopenid.com/

  • status changed from new to closed.
  • resolution set to fixed.

The fact that Django's QueryDict?.items() behaves differently than QueryDict?.iteritems() is what I call a Django bug, see http://code.djangoproject.com/ticket/7331 . But in the meantime, we can use items() instead.