My favorites | Sign in
Project Logo
                
New issue | Search
for
| Advanced search | Search tips
Issue 10: Patch to have django-openid working with python-openid 2.x
7 people starred this issue and may be notified of changes. Back to list
Status:  New
Owner:  ----
Type-Defect
Priority-Medium


Sign in to add a comment
 
Reported by bchesneau, Nov 07, 2007
Latest trunk of django-openid work only with python-openid 1.x. Here is a
patch to have it working against latest stable version of python-openid.
Tested with 2.0.1 version.



django_openidconsumer-python_openid_2.0.diff
11.9 KB   Download
Comment 1 by bchesneau, Nov 07, 2007
this patch you also newforms to validate fields before sending it.
Comment 2 by bchesneau, Nov 13, 2007
new patch. fix yadis import. Could someone reviewed it ?
django_openidconsummer_r19_2.diff
12.3 KB   Download
Comment 4 by bchesneau, Dec 03, 2007
How did you patched it ? useNonce take 4 arguments if you install the patch. 

-benoît
Comment 5 by eric.holscher, Dec 03, 2007
I am having trouble applying your patch (Django/devel newbie). I'm trying patch -p0 <
*thepatch* in the toplevel dir (w/ all the files in it)..

It's giving me errors for some reason...
Comment 6 by eric.holscher, Dec 03, 2007
Using the most resent devel version btw.
Comment 7 by bchesneau, Dec 03, 2007

Apply patch in django_openidconsummer path.

{{{
cd django_openidconsumer
patch -Np0 -i ~/django_openidconsummer_r19_2.diff
}}}


- benoît
Comment 8 by eric.holscher, Dec 03, 2007
Awesome, that worked. Was it the patch command that did it.?

Also I now get the error: complete() takes exactly 3 arguments (2 given)
/usr/lib/python2.5/site-packages/django_openidconsumer/views.py in complete, line 120

I tried making that line 
openid_response =
consumer.complete(dict(request.GET.items()),request.GET['openid.return_to'])

Which I'm assuming is braking something else...
OperationalError at /events/openid/complete/
(1054, "Unknown column 'django_openidconsumer_nonce.server_url' in 'field list'")
/var/lib/python-support/python2.5/MySQLdb/connections.py in defaulterrorhandler, line 35

The old complete() code allowed the return_to param to default to None, now it looks
like it's necessary...

http://openidenabled.com/files/python-openid/docs/2.1.0-rc2/openid.consumer.consumer.Consumer-class.html#complete

Comment 9 by keturn, Dec 07, 2007
ok, I really have _got_ to find a way to make that Consumer.complete documentation
more clear.

That return_to parameter should be the URL (including scheme, host, and path) that
the current HTTP request is responding to.  The purpose is to verify that it is the
same as the signed argument in the OpenID message.  So if you pass in a value from
the query parameters, it ultimately just compares that value to itself, which is not
so useful.
Comment 10 by bchesneau, Dec 20, 2007
have been fixed in django-authopenid :
http://code.google.com/p/django-authopenid/

I don't maintain any more this patch since the author don't seem interrested.
Comment 11 by vivekam101, Mar 03, 2008
'NoneType' object has no attribute 'find'
this is the error when i tried
openid_response = consumer.complete(dict(request.GET.items()), return_to)
can any one help

Comment 12 by bharath.keshav, May 05, 2008
"Which I'm assuming is braking something else...
OperationalError at /events/openid/complete/
(1054, "Unknown column 'django_openidconsumer_nonce.server_url' in 'field list'")
/var/lib/python-support/python2.5/MySQLdb/connections.py in defaulterrorhandler, line 35

The old complete() code allowed the return_to param to default to None, now it looks
like it's necessary...

http://openidenabled.com/files/python-openid/docs/2.1.0-rc2/openid.consumer.consumer.Consumer-class.html#complete
"
Any update on this?? Eric can you please tell me the solution in case if you were
able to solve this?? I am stuck at exactly the same point and I am getting the same
operational error when I give the argument request.GET['openid.return_to'] in the
complete() function.
Comment 13 by brooksjbr, Feb 12, 2009
Was there ever a resolution to this issue? I'm experiencing the same problem.
Comment 14 by alper.cugun, Feb 13, 2009
I installed django-openid and tried it out bubt it bombed on this same issue. Applying the patch mentioned 
above made things only worse. Any resolutions to this or is this project deprecated in favor of django-
authopenid?
Comment 15 by jon.tingvold, Feb 13, 2009
django-authopenid is the only good fix, yes. This project is outdated.
Comment 16 by JasYun.cn, Sep 30, 2009
useNonce() takes exactly 2 arguments (4 given)
why?
Comment 17 by r.r.nederhoed, Oct 10, 2009
It's really a bummer to spend hours to apply these late patches and then to run into
the fact that the project is outdated.
Comment 18 by se...@matveenko.ru, Oct 10, 2009
This one works http://github.com/lig/simpleopenid
Sign in to add a comment

Hosted by Google Code