jfinkels / flask-restless

NO LONGER MAINTAINED - A Flask extension for creating simple ReSTful JSON APIs from SQLAlchemy models.
https://flask-restless.readthedocs.io
GNU Affero General Public License v3.0
1.02k stars 301 forks source link

pip install Flask-Restless installs 0.17, and v1b doesn't install flask_sqlalchemy dependency #629

Closed zbrook closed 7 years ago

zbrook commented 7 years ago

NB: this is easily worked around by forcing pip to install the more recent version of Flask-Restless, and then installing flask-sqlalchemy via pip afterward.

Not sure whether to say the documentation at readthedocs or the default version via pip is in error.

Used pip 9.0.1 with Python 3.4. I use pyenv, but reproduced on a machine with just python 2.7 installed and no pyenv.

http://flask-restless.readthedocs.io/en/stable/installation.html advises to install via pip, and the rest of the documentation assume beta v1, but pip installs 0.17.

https://pypi.python.org/pypi/Flask-Restless/ also refers to beta v1.

$ pip --version
pip 9.0.1
$ pip show flask_restless 
Name: Flask-Restless 
Version: 0.17.0

pip install -I flask_restless==1.0.0b1 worked, but still doesn't install dependency flask-sqlalchemy as advertised.

$ pip freeze  
click==6.7
Flask==0.12
Flask-Restless==1.0.0b1
itsdangerous==0.24
Jinja2==2.9.5
MarkupSafe==0.23
mimerender==0.6.0
python-dateutil==2.6.0
python-mimeparse==1.6.0
six==1.10.0
SQLAlchemy==1.1.5
Werkzeug==0.11.15

P.S. Great project -- thank you for creating it.

jfinkels commented 7 years ago

The documentation is a little unclear. Flask-SQLAlchemy is not required to use Flask-Restless. Flask-Restless supports models defined via Flask-SQLAlchemy, but it requires only models defined via SQLAlchemy. I will update the documentation to be clearer about this.

jfinkels commented 7 years ago

Pull request #633 updates the documentation.