Pony ORM Release 0.4.5

Pony ORM 0.4.5 is released. You can install it using pip:

    pip install pony

or upgrade it:

    pip install --upgrade pony

if you had the previous version installed.
Also you can download the sources from GitHub: github.com/ponyorm/pony

Pony ORM 0.4.5 Release Notes:

Feature: Now Pony can be easily integrated with Flask. Use Pony’s with_transaction decorator this way:  app.wsgi_app = with_transaction(app.wsgi_app).

Bug fix: Nested calls of functions decorated with @with_transaction didn’t work properly.
Now only the top level function decorated with @with_transaction does commit() or rollback() and releases the database connection. All nested calls ignore @with_transaction decorator.

Each function which works with Pony ORM should be wrapped with @with_transaction decorator. This decorator automatically does commit (or rollback in case of an exception happened inside the function), clears the cache and returns the database connection to the connection pool.

Fix Git issue #4: “Ambiguous column” error when using inheritance

Bug fix: Secondary keys (unique indexes) were not stored in cache.

Enhancement: Collections now have the ‘create’ method which can create and add a new collection item in one step.

Enhancement: Improved __repr__ and __str__ functions for collections.

 

The following updates were included in Pony ORM Release 0.4.4:

Enhancement: Suppress warnings when table already exists for mysql

Bug fix: Many-to-many “Duplicate primary key” error

Enhancement: Some exceptions text was improved