django-allauth

Over-riding Django-allauth login/ registration urls with custom url/ pages

依然范特西╮ 提交于 2019-12-09 06:46:26
问题 I have configured django-allauth for login through Facebook, Twitter and Google. However, django-allauth accepts login request only at /accounts/login/ , sign up request only at /accounts/signup/ etc. I have a modal form for login and registration on my home page and I want to use only that. How do I use django-allauth system to allow login ( both social and custom)/ registration etc from the modal form on my home page? I'm looking for mechanism to override django-allauth's urls and

Django-allauth: send welcome email on signup (without verification)

左心房为你撑大大i 提交于 2019-12-09 04:05:40
问题 How can I send a welcome email to a user who signs up on a django app(using django-allauth). If I set ACCOUNT_EMAIL_VERIFICATION = ("mandatory") , it works fine, and the user gets a verification email. But since I dont require any email verification, so the user should simply signup and get a welcome email. settings.py- ACCOUNT_AUTHENTICATION_METHOD = ("email") ACCOUNT_EMAIL_VERIFICATION = ("none") ACCOUNT_SIGNUP_PASSWORD_VERIFICATION = False ACCOUNT_UNIQUE_EMAIL = True ACCOUNT_USERNAME

Custom Form Validation in Django-Allauth

萝らか妹 提交于 2019-12-09 03:13:31
问题 I want to do some extra validation on fields in django-allauth. For example I want to prevent using free email addresses. So I want to run this method on signup def clean_email(self): email_domain = self.cleaned_data['email'].split('@')[1] if email_domain in self.bad_domains: raise forms.ValidationError(_("Registration using free email addresses is prohibited. Please supply a different email address.")) Similarly I want to run custom validation on different fields other than email address.

django-allauth returns error “Reverse … with arguments '()' and keyword arguments '{}' not found”

狂风中的少年 提交于 2019-12-08 06:19:14
问题 EDIT: Kevin's answer below solved my issue. Turns out "allauth does not support namespaces" so I shouldn't have introduced this into my urls.py ORIGINAL POST: I have installed django-allauth exactly as per tutorials https://github.com/pennersr/django-allauth I have a very basic problem here; can't get basic user login/out pages working even before I add in social integration. By navigating to /admin, I clicked "log out", so I am not a logged in user. Now when I visit /accounts/login I am met

Bypass signup form using allauth

帅比萌擦擦* 提交于 2019-12-08 06:18:55
问题 Does anyone know how I would go about bypassing the signup page when using a social account in django allauth? I've got the authentication side of things working with Google but when the user accepts the request from Google, it redirects to a page which asks them to enter their email address before they can log in. But surely it will have retrieved this information from the Google login and should be able to simply log the user in so that they can use the site? How would I go about doing that

How to tell if user's email address has been verified using Django, allauth, rest-auth and a custom user

非 Y 不嫁゛ 提交于 2019-12-08 05:04:30
问题 I'm using Django 2.0.10 with rest-framework, rest-auth and allauth. I have a custom user model. I've got email verification working by using the allauth view. The verification email is sent when a user registers. If I click the link in the email, I'm taken to a page with a button to click to verify the email. This all works without error. However what I can't find out is what this actually does . No field in the user's data seems to change. The behaviour I want is for users to be able to

Django allauth get credentials to make further requests on behalf of the user

匆匆过客 提交于 2019-12-08 02:04:20
问题 I'm working on a Django project that requires user authentication for BitBucket, I have setup allauth such that users can authenticate with Bitbucket, I just don't understand how to make further requests to the Bitbucket API now that the user is authenticated. I understand that allauth is purely for authentication purposes, there is just no documentation on how to access and make further use of the authentication, in this case accessing the credentials (oauth_token) such that I can make

A simple and up-to-date way to implement Facebook login in a Django app

老子叫甜甜 提交于 2019-12-07 23:11:48
问题 This issue is very common in stackoverflow, and there's a lot of different questions and answers about it, yet I couldn't find exactly what I need. First, I'd like to define exactly what I need: the option to let users log in to my app using their Facebook credentials. The app will save a matching classic Django user. I will only need to use the user's profile picture and to make sure that each time the same Facebook user will be related to the matching Django user. Unfortunately, I find it

How does email translation work with django allauth?

让人想犯罪 __ 提交于 2019-12-07 15:11:32
问题 I'm using the most excellent django-allauth to handle authentication. All is well, but I have an issue with the email translations. First, allauth is definitely using my template. I ran: django-admin.py makemessages -l ir -i settings.py This created: my_app/locale/ir/LC_MESSAGES/django.po In django.po, I make this change: templates/account/email/email_confirmation_subject.txt:3 msgid "Confirm E-mail Address" msgstr "FARSI Confirm E-mail Address" Then to test, a user signs up on a page where

My 'access_token' from facebook is “incorrect value”

北城余情 提交于 2019-12-07 12:57:59
问题 I'm using django-rest-auth which is "API extension for Django all-auth". I'm building a mobile app which can signup/login using Facebook token (url: http://localhost:8000/rest-auth/facebook/). get Facebook token using 'expo' export const doFacebookLogin = () => async dispatch => { let { type, token } = await Facebook.logInWithReadPermissionsAsync('194632xxxxxx', { permissions: ['public_profile'] }); if (type === 'cancel') { return dispatch({ type: FACEBOOK_LOGIN_CANCEL }) } doSocialAuthLogin