With 1.96.1, Auth was rewritten to use the new thread local 'current' object as the environment instead of passing globals() to Auth. However, the 'current' object does not include URL (and other web2py global objects), so auth.environment.URL doesn't exist. It looks like openid_auth.py already imports everything from gluon.html (which includes URL), though, so in openid_auth.py, try replacing all occurrences of auth.environment.URL, self.environment.URL, and environment.URL with just URL, and see if that fixes the problem. If so, please submit the updated openid_auth.py as a patch. Anthony
On Saturday, July 9, 2011 11:28:55 PM UTC-4, Brian M wrote: > So I thought I'd mess around with using OpenID for authentication and > followed the info Will provided in an older > post<https://groups.google.com/forum/#!topic/web2py/So79E4FDWLk>. > Unfortunately, I'm getting an error: > > Traceback (most recent call last): > > File "C:\Users\Brian\Documents\development\web2py\stable\web2py_src > v1.97.1\web2py_src\web2py\gluon\restricted.py", line 192, in restricted > > exec ccode in environment > > File "C:/Users/Brian/Documents/development/web2py/stable/web2py_src > v1.97.1/web2py_src/web2py/applications/myapp/models/db.py" > <http://localhost:8000/admin/default/edit/update_checking/models/db.py>, line > 55, in <module> > > openid_login_form = OpenIDAuth(auth) > > * * > > File "C:\Users\Brian\Documents\development\web2py\stable\web2py_src > v1.97.1\web2py_src\web2py\gluon\contrib\login_methods\openid_auth.py", line > 95, in __init__ > > self.login_url = auth.environment.URL(r=request, f='user', args=['login']) > > AttributeError: 'thread._local' object has no attribute 'URL' > > > Does anyone know what's going wrong? I'm running the latest stable web2py > from source with Python 2.7 (windows) and sqlite. >