I am using Flask-sqlalchemy, how can I just configure it for no autoflush
. Currently I am doing something like
db = SQLAlchemy()
...
db.init_app(app)
...
db.session.configure(autoflush=False)
But it gives error. How to fix this.
The session_options
parameter can be used to override session options. If provided it’s a dict of parameters passed to the session’s constructor.
db = SQLAlchemy(session_options={"autoflush": False})
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With