使用python social auth注册github时出错:内部服务器错误:/sso/social/complete/github/

使用python social auth注册github时出错:内部服务器错误:/sso/social/complete/github/,python,django,github-api,python-social-auth,Python,Django,Github Api,Python Social Auth,我已经在我的项目中实现了与github的注册。以下是使用的管道: SOCIAL_AUTH_PIPELINE = ( 'social.pipeline.social_auth.social_details', 'social.pipeline.social_auth.social_uid', 'accounts.pipeline.user.get_username', 'social.pipeline.social_auth.auth_allowed',

我已经在我的项目中实现了与github的注册。以下是使用的管道:

 SOCIAL_AUTH_PIPELINE = (
    'social.pipeline.social_auth.social_details',
    'social.pipeline.social_auth.social_uid',
    'accounts.pipeline.user.get_username',
    'social.pipeline.social_auth.auth_allowed',
    'accounts.pipeline.user.non_internal_user',
    'social.pipeline.social_auth.associate_by_email',
    'accounts.pipeline.user.populate_additional_info',
    'accounts.pipeline.user.user_accept_terms',
    'social.pipeline.social_auth.social_user',
    'social.pipeline.social_auth.load_extra_data',
    'accounts.pipeline.user.create_user',
    'social.pipeline.social_auth.associate_user',
    'social.pipeline.user.user_details',
)
在github应用程序中生成密钥后,在项目中设置密钥

SOCIAL_AUTH_GITHUB_KEY = 'random403453'
SOCIAL_AUTH_GITHUB_SECRET = 'randomexample3'
在github应用程序中:

My homepage url : https://example.org
My call back url : https://example.org
我得到这个错误

"/opt/virtualenvs/pyapp/lib/python2.7/site-packages/social/backends/oauth.py",
> line 351, in process_error
> data'error')
> AuthFailed: Authentication failed: The code passed is incorrect or expired.
>
> Request repr():
> <WSGIRequest
> path:/sso/social/complete/github/,
> GET:<QueryDict:
{u'state': [u'D6cGrandomHEnt6oLR'], u'code': > [u'9arandom29886f7'], u'redirect_state': > [u'D6crandoma2MQa5HEnt6oLR']}
“/opt/virtualenvs/pyapp/lib/python2.7/site packages/social/backends/oauth.py”,
>第351行,进程中错误
>数据“错误”)
>AuthFailed:身份验证失败:传递的代码不正确或已过期。
>
>请求repr():
>路径:/sso/social/complete/github/,
>获取:[u'D6Random29886F7'],u'redirect_state':>[u'D6Crandoma2MQA5hentHolr']
检查了此url。发现了列出的类似错误。此错误很少发生,我无法重现。如何重现此错误或捕获此错误