[ckan-discuss] bug: 'forgot pwd' link gives 404

Rufus Pollock rufus.pollock at okfn.org
Sat Apr 14 14:26:25 BST 2012


On 13 April 2012 14:19, Sean Hammond <sean.hammond at okfn.org> wrote:
> (I've followed up with Egon privately about resetting his password.)
>
> ckan-devs, ckan restricts user names to contain only certain characters:
>
> https://github.com/okfn/ckan/blob/master/ckan/logic/validators.py#L178
>
> But there are some pre-existing users (on thedatahub for example) that
> already have user names that don't meet this restriction (e.g. users
> with OpenID accounts whose user name is a URL.) For those users, if they
> try to edit their profile for example they will always get a message
> that their username is invalid even if they aren't trying to change
> their username. I'm guessing that this same issue is causing the
> password reset form to fail for Egon.

But I kind of think that is a feature rather than a bug in that it
would force people to create a proper username (though that isn't
perfect I admit).

Oh the pain of having allowed pure openid logins back in the day :-)

> I've written a code fix that just skips the usual user name validation
> if the user account is pre-existing and the user name hasn't changed:
>
> https://github.com/okfn/ckan/compare/name-validator-exception-for-preexisting-usernames
>
> Do we want to merge this into master or not?

I think people should really be creating a proper username (though I
understand that better instructions may be needed).

Rufsu

> On Fri, Apr 13, 2012 at 11:30:09AM +0200, Sean Hammond wrote:
>> On Fri, Apr 13, 2012 at 10:49:22AM +0200, Egon Willighagen wrote:
>> > On Fri, Apr 13, 2012 at 10:41 AM, Toby Dacre <toby.okfn at gmail.com> wrote:
>> > > http://thedatahub.org/en/user/reset
>> >
>> > After entering the new password twice, I get to the same page, but
>> > with this warning:
>> >
>> > "{'name': [u'Url must be purely lowercase alphanumeric (ascii)
>> > characters and these symbols: -_']}"
>> >
>> > in a red box...
>> >
>> > Also, the reset does not seem to have worked...
>> >
>> > BTW, my account is:
>> > http://thedatahub.org/en/user/1261b031-57f8-4214-a468-731c30b01b82
>> >
>> > It's associated with an OpenID, but logging in with the OpenID did not
>> > work (that's what I tried first...)
>>
>> Password reset works fine with my normal username, so this is probably a
>> bug that affects only OpenID usernames (or usernames with special
>> characters in them). I'll look into this..
>
> _______________________________________________
> ckan-discuss mailing list
> ckan-discuss at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-discuss



-- 
Co-Founder, Open Knowledge Foundation
Promoting Open Knowledge in a Digital Age
http://www.okfn.org/ - http://blog.okfn.org/



More information about the ckan-discuss mailing list