django-allauth
django-allauth copied to clipboard
Setting ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE to False still asks for password2
When adding ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE = False to settings.py I still get this error:
password2: ["This field is required."]
Are you sure you restarted the instance? What other settings do you have set currently?
I'm experiencing this issue as well. ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE = False is having no effect. Using the following settings:
ACCOUNT_SESSION_REMEMBER = True
ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE = False
ACCOUNT_USERNAME_REQUIRED = True
ACCOUNT_AUTHENTICATION_METHOD = 'email'
ACCOUNT_EMAIL_REQUIRED = True
ACCOUNT_UNIQUE_EMAIL = True
@ebrahimp
What version of django and allauth are you using? Did you see this?
https://stackoverflow.com/questions/38289442/django-all-auth-remove-asking-password-twice-in-signup-form
Try using ACCOUNT_SIGNUP_PASSWORD_VERIFICATION and report back.
It seems like forms.py SignupForm and BaseSignupForm classes and possibly the views.py SignupView class may be the main culprits. If you figure it out, please post the fix here.
Forms.py:
https://github.com/pennersr/django-allauth/blob/master/allauth/account/forms.py
Views.py:
https://github.com/pennersr/django-allauth/blob/master/allauth/account/views.py
@9mido
Yes, I saw that question.
I'm using Django==3.1.4 and django-allauth==0.44.0.
Tried using ACCOUNT_SIGNUP_PASSWORD_VERIFICATION but that didn't work as well.
@ebrahimp Strange I just tried it out myself and did not have any problems with it.
This still doesn't work with both ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE = False ACCOUNT_SIGNUP_PASSWORD_VERIFICATION = False
still having issue with it
still having an issue I'm using Django version 4.1.4 and django-allauth version 0.52.0 I've tried for ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE = False and ACCOUNT_SIGNUP_PASSWORD_VERIFICATION = False but both doesn't work
Ok, so i think there is some confusion as to what this setting does. And i'd like to join the club because as far as I can see... it does nothing! A search for ACCOUNT_SIGNUP_PASSWORD_ENTER_TWICE
yields results in the tests ensuring the user can post just one password. Users here are likely either expecting the default forms to only have one password w/ this setting set to False
OR are still submitting a blank password2 field somehow.
@pennersr this is something that should be removed as a setting OR fully implemented. My suspicion is there was some series of bugs/issues/whatever got us here w/o much intention. You can see the search for password2 yields one hit for 2016 changelog and not much else.
This setting is also notably low value if only ~5 people have commented this kind of thing while it seems to only be used to configure tests to submit only one password.
It works for me. Search the code base for SIGNUP_PASSWORD_ENTER_TWICE
instead.
bah! github's search is garbage. Wonder why the account forms didn't show up for me when i searched for password2.
Cheers!