Comments (8)
Have you tried running python manage.py syncdb
in the sample app? There's a manager command defined for that, I've just tried it with sqlite and postgresql and it worked as expected.
from python-social-auth.
Yes I have. I'll clone python-social-auth repo and try to check if the problem persists (maybe there's a problem with my environment; I copied files by hand) and I'll get back to you.
from python-social-auth.
Ok, it's kinda weird, if you clone from git repo - it works, but if you copy files by hand - there's no relation.
Steps made (I'm on Arch, python by default is python 3, so I have to call python2.7)
git clone https://github.com/omab/python-social-auth.git python-social-auth-test
cd python-social-auth-test/
sudo python2.7 setup.py install
cd examples/flask_example
pip2 install -r requirements.txt # failed, couldn't install flask to system wide flask-packages
sudo pip2 install -r requirements.txt
sudo pip2 install psycopg2
python2.7 ./manage.py syncdb
python2.7 ./manage.py runserver
(afterwards tried with postgre)
^ runs ok!
mkdir flask_example
cd flask_example
virtualenv-2.7 --python=/usr/bin/python2.7 --no-site-packages virtualenv
. virtualenv/bin/activate
pip install python-social-auth
# copying files from https://github.com/omab/python-social-auth/tree/master/examples/flask_example ...
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/__init__.py
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/manage.py
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/requirements.txt
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/settings.py
mkdir models && cd models
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/models/__init__.py
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/models/user.py
cd ..
mkdir routes && cd routes
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/routes/__init__.py
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/routes/main.py
cd ..
mkdir templates && cd templates
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/templates/base.html
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/templates/done.html
wget https://raw.github.com/omab/python-social-auth/master/examples/flask_example/templates/home.html
cd ..
pip install -r requirements.txt
python ./manage.py migrate run
python ./manage.py runserver
On http://localhost:5000/complete/..
OperationalError: (OperationalError) no such table: social_auth_usersocialauth u'SELECT social_auth_usersocialauth.id AS social_auth_usersocialauth_id, social_auth_usersocialauth.provider AS social_auth_usersocialauth_provider, social_auth_usersocialauth.uid AS social_auth_usersocialauth_uid, social_auth_usersocialauth.extra_data AS social_auth_usersocialauth_extra_data, social_auth_usersocialauth.user_id AS social_auth_usersocialauth_user_id \nFROM social_auth_usersocialauth \nWHERE social_auth_usersocialauth.uid = ? AND social_auth_usersocialauth.provider = ?\n LIMIT ? OFFSET ?' ('14276842', 'twitter', 1, 0)
Maybe Python-Social-Auth package (via pip) differs from git and I've forgotten some step?
from python-social-auth.
pip package differs (I'm waiting to finish the tests to make a new release), don't run python manage.py migrate run
, use python manage.py syncdb
.
from python-social-auth.
Yeah but there's no syncdb command (in package which is provided via pip):
python ./manage.py syncdb
Command syncdb not found
migrate
runserver Runs the Flask development server i.e. app.run()
shell Runs a Python shell inside Flask application context.
So it's better to install via git for now (I'm not developing anything critical, I just want to keep up with the latest version, which works)? :)
from python-social-auth.
I've released v0.1.1 to pypi, could you try again?
from python-social-auth.
Great, it works now. Thank you!
from python-social-auth.
No problem, I'm closing the issue, reopen if needed.
from python-social-auth.
Related Issues (20)
- cannot import name 'OpenIdConnectAssociation' HOT 1
- Too bad, casually abandoned HOT 2
- Issue with redirecting page after login using Facebbok for django site
- Support for tokens / secrets in database HOT 1
- VK now demands API version
- python-social-auth - FB login issue HOT 3
- Backend AzureADB2COAuth2 requires 'SOCIAL_AUTH_AZUREAD_B2C_OAUTH2_POLICY' but there is no documentation about this anywhere HOT 2
- 401 Client Error: Authorization Required for url: https://api.twitter.com/oauth/request_token
- 401 Client Error: Authorization Required for url: https://api.twitter.com/oauth/request_token
- 401 Client Error: Authorization Required for url: https://api.twitter.com/oauth/request_token
- Allow exception handling during DEBUG mode
- Facebook login popup from Angular + JWT + DRF
- django.db.migrations.exceptions.NodeNotFoundError: Migration listings.0001_initial dependencies reference nonexistent parent node ('owners', '0001_initial')
- base64.encodestring was deprecated and removed in Python 3.9 . Use encodebytes instead.
- auth
- Is there any example/documentation for IDP initiated SSO in SAML backend? HOT 1
- Better document how the partial pipeline should be handeled HOT 1
- Регистрация через соц сети
- GoogleOpenId is not defined in https://github.com/python-social-auth/social-core/blob/4.5.0/social_core/backends/google.py
- linkedin openid complete endpoint request is stuck
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 python-social-auth.