Comments (3)
@qiutzh 你说的是我的网站还是你用我代码部署的?如果是我的网站应该不存在这个问题,而且这两个方式也不是注册,而是登录。
如果你部署的,那么你需要进入管理界面,添加github和微博的接口,具体是在后台的Social applications中添加,这个你可以查一下django-allauth的用法
from izone.
哦,多谢大佬,我是利用代码部署的哈。
from izone.
@Hopetree 博主帮我看下,我这样配置的github第三方登录问题出在哪了呢?
settings.py
AUTHENTICATION_BACKENDS = {
...
'social_core.backends.github.GithubOAuth2',
}
INSTALLED_APPS = [
...
'social_django',
]
TEMPLATES = [
...
'social_django.context_processors.backends',
'social_django.context_processors.login_redirect',
]
SOCIAL_AUTH_GITHUB_KEY = 'xxx'
SOCIAL_AUTH_GITHUB_SECRET = 'xxxxxx'
urls.py
urlpatterns = [
...
path('accounts/github/login/', auth_views.LoginView.as_view(), name='login'),
path('accounts/github/login/callback/', include('social_django.urls', namespace='social')),
]
做了以上这些配置后,然后启动web服务,点击选择github方式登录,还是报了错
Internal Server Error: /accounts/github/login/
allauth.socialaccount.models.SocialApp.DoesNotExist: SocialApp matching query does not exist.
后面我登录到后台,把github的Client id和Secret key填上,添加sites站点后,再次启动点击github登录上面的错误还存在--__--
from izone.
Related Issues (20)
- Segmentation fault (core dumped) HOT 2
- 我在 adminx 添加文章 的时候报了一个错误提示 HOT 1
- docker部署后如何修改模版文件 HOT 1
- pip install xxx error HOT 2
- 有个问题请教一下
- 不懂这个.py的语言。。。
- 请问网站有没有使用说明书,发表个文章好费劲 HOT 1
- 创建数据库表的时候出现了以下错误
- # 后台markdown编辑器改为使用 django-mdeditor HOT 2
- 部署完成后,没有评论功能 HOT 2
- 怎么创建文章呢 HOT 1
- 后台登录
- 请问打开文章之后,没有显示侧面悬浮的文章目录吗 HOT 4
- 多个站点问题 HOT 1
- 网站很棒,换个友链? HOT 4
- SyntaxError: Generator expression must be parenthesized HOT 1
- 启动服务后默认绑定127.0.0.1,请问怎么修改监听地址呢? HOT 1
- 文章撰写的入口在哪呢 HOT 2
- 运行指导是否更新下 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from izone.