def run(): """ This method runs the flask app using manager command after adding the routes using the methods in routes folder """ add_resources(app) register_blueprints(app) app.run()
def run(): # import pdb; pdb.set_trace() """ This method runs the flask app using manager command after adding the routes using the methods in routes folder """ add_resources(app) app.register_blueprint(api_blueprint) register_blueprints(app) app.run()
def run(): register_blueprints(app) app.run()
from flask import Flask from flask_migrate import Migrate, MigrateCommand from flask_script import Manager from app.main import create_app, db from app.main.routes import add_resources, register_blueprints from app.main.models import * from app.main import api, api_blueprint app = create_app(os.getenv("FLASK_ENV") or "dev") app.app_context().push() manager = Manager(app) migrate = Migrate(app, db, render_as_batch=True) manager.add_command("db", MigrateCommand) add_resources(app) app.register_blueprint(api_blueprint) register_blueprints(app) #app = Flask(__name__) # @app.route('/') # def hello_world(): # return 'Hello World! Parth' @manager.command def run(): """ This method runs the flask app using manager command after adding the routes using the methods in routes folder """ add_resources(app)