Skip to content

Instantly share code, notes, and snippets.

@gregimba
Created June 29, 2013 16:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gregimba/5891841 to your computer and use it in GitHub Desktop.
Save gregimba/5891841 to your computer and use it in GitHub Desktop.
In order to properly use pony with flask you need to add a second decorator to your function.
@index.route('/')
@with_transaction
def Show():
db = Database('sqlite', '/Users/grant/Documents/Archer/db.sqlite')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment