migrated to sqlalchemy and added flask-security and flask-jwt