4 ms·
Check out how things are wired with in this Pyramid cookie cutter. https://github.com/Pylons/pyramid-cookiecutter-starter/blob/latest/%7B%7Bcookiecutter.repo_n
by ergo14 6y ago
Check out how things are wired with in this Pyramid cookie cutter.
https://github.com/Pylons/pyramid-cookiecutter-starter/blob/latest/%7B%7Bcookiecutter.repo_name%7D%7D/%7B%7Bcookiecutter.repo_name%7D%7D/sqlalchemy_models/__init__.py https://github.com/Pylons/pyramid-cookiecutter-starter/blob/...
I think same approach should work well for flask - just tie the session to the request object on first access.
Side note: I think we met on IRC few years ago ;-)
- luhn 6y agoThere is a lot going on in that cookie cutter. The “transaction” library for transaction management, wired into Pyramid with pyramid_tm, wired into SQLAlchemy with zope.sqlalchemy. Works nicely for Pyramid, but I don’t know how that translates to Flask.