= Description = ## Please read this page. Lines prefixed with ## such as this one are comments, ## you can remove them (except for those after the "Plan" section.) ## Please follow the instructions given in those comments and the text. ## After creating the bug page, please subscribe to it! We may have questions ## that only you can answer, and if you get email when your bug changes it'll ## be much faster to get it fixed since you can answer the questions! In Moin 1.9.2 (and at the time of reporting on 1.9 main branch), `MoinMoin/userprefs/oidserv.py` uses `getPathinfo` when building its form. This won't work with the updated HTTP request API in Moin 1.9.x. == Steps to reproduce == ## Describe the steps needed to reproduce the bug. If we can't reproduce it, we probably can't fix it. 1. Enable OpenID. 1. Go to a user's setting page. 1. Select `OpenID server`. 1. In the Web server log, the following kind of error is shown: {{{ File ".../lib/python2.5/site-packages/MoinMoin/userprefs/oidserv.py", line 65, in _make_form pi = self.request.getPathinfo() File ".../lib/python2.5/site-packages/MoinMoin/web/contexts.py", line 224, in __getattr__ return super(HTTPContext, self).__getattribute__(name) AttributeError: 'AllContext' object has no attribute 'getPathinfo' }}} == Component selection == ## Where you think is this bug happening ? (general, plugin [plugin name], theme [theme name], ... * `MoinMoin/userprefs/oidserv.py` * `MoinMoin/auth/cas.py` also uses `getPathinfo` == Details == ## If you got a traceback, please save the traceback page as html and attach here: ## [[attachment:traceback.html]] ## if the bug is in this wiki, just kill the table and write: This Wiki. ## If a traceback is not available, please fill in the details here: || '''!MoinMoin Version''' || 1.9.2 || || '''OS and Version''' || Kubuntu 8.04 || || '''Python Version''' || 2.5.2 || || '''Server Setup''' || CGI || || '''Server Details''' || Apache 2.2 || || '''Language you are using the wiki in''' (set in the browser/UserPreferences) || English || == Workaround == ## How to deal with the bug until it is fixed Replace `getPathinfo()` with `path`, I suppose. = Discussion = = Plan = ## This part is for Moin``Moin developers: * Priority: * Assigned to: * Status: hopefully fixed by http://hg.moinmo.in/moin/1.9/rev/f8e67522e80e - please test and provide feedback. We also need an active openid auth maintainer for moin, so if you use it... * I'm thinking about recommending its use for `python.org`, but it occurred to me that the authentication "stacking" would need to be nicer: currently you get a bunch of fields from different components if you have both normal and OpenID authentication enabled (not the provider stuff), and no help on which to fill out when logging in. You'd need the normal authentication (username and password) in order to let users set up their own OpenID presence (with the provider stuff). I guess a feature request and some patches might be needed, so I might look into this. Thanks for the fix, though! -- PaulBoddie <> * did you test the fix? * This seems not to crash now, yes. Thanks! The "OpenID server" settings are a bit strange - an empty table cell and a "Cancel" button - but I imagine that it's supposed to be like that in the default state. I'll look into improving this, possibly. -- PaulBoddie <> * I've discovered another bug in Moin 1.9 when associating OpenID identities with users: strictly a consumer (not a provider) problem but related to usage of the old request API. Here's a quick patch suggestion: {{{ --- a/MoinMoin/userprefs/oid.py Thu May 06 15:36:56 2010 +0200 +++ b/MoinMoin/userprefs/oid.py Sat May 08 18:44:56 2010 +0200 @@ -100,8 +100,8 @@ oidconsumer = consumer.Consumer(request.session, MoinOpenIDStore(request)) query = {} - for key in request.form: - query[key] = request.form[key] + for key in request.values: + query[key] = request.values[key] qstr = {'action': 'userprefs', 'handler': 'oid', 'oid.return': '1'} }}} Since the return from a provider employs URL query parameters, not form data, it seems that `request.form` is inappropriate. -- PaulBoddie <> * Thanks for the patch, committed by: http://hg.moinmo.in/moin/1.9/rev/f7f9d35f9d23 Note: also did similar fixes for auth.cas, we also need tests and an active maintainer for that. ---- ## If you are a moin core developer, replace the category to Category* in these cases: ## Category MoinMoinNoBug - if this is not a bug. ## Category MoinMoinBugConfirmed - if you can confirm the bug on current code. ## Category MoinMoinBugFixed - after the bug is fixed in current code. CategoryMoinMoinBugFixed