Setting up Flask-SQLAlchemy
At the time you execute create_all, models.py has never been imported, so no class is declared. Thus, create_all does not create any table.
To solve this problem, import models before running create_all or, even better, don't separate the db object from the model declaration.
Trying to set up Flask and SQLAlchemy on Windows but I've been running into issues.
I've been using Flask-SQLAlchemy along with PostgreSQL 9.1.4 (32 bit) and the Psycopg2 package. Here are the relevant bits of code, I created a basic User model just to test that my DB is connecting, and committing.
The three bits of code would come from the __init__.py file of my application, the models.py file and my settings.py file.
When I try opening up my interactive prompt and try the code in the following link out I get a ProgrammingError exception (details in link).
What could be causing this? I followed the documentation and I'm simply confused as to what I'm doing wrong especially considering that I've also used Django with psycopg2 and PostgreSQL on Windows.