Alembic 0.3.0 Released

2 views
Skip to first unread message

Michael Bayer

unread,
Apr 5, 2012, 1:50:05 PM4/5/12
to sqlal...@googlegroups.com, sqlalche...@googlegroups.com, sqlalchem...@googlegroups.com
Hello again -

After pushing out 0.2.2 yesterday I continued to do what I first intended, which was to clean up some more of the public API. Yesterday I had the need to write a function in my application that just wanted to check that the current database was up-to-date. There wasn't a clean public API for this, so I set out to make that available as well as just about everything else I could make public. Things that I can't really make public I made sure were underscored. Most of the changes involve making the ScriptDirectory object public - this object gives you access to the script files in your migrations/ directory.

That's pretty much 0.3 in a nutshell, it is absolutely identical to 0.2 except for some internal method names that a few people may have been calling and more documentation. There are backwards compatible names for most of what I think those few individuals might have been calling.

I also threw in the beginning of a public API for autogenerate, in the form of a function called alembic.autogenerate.compare_metadata.

The revised API documentation at http://alembic.readthedocs.org/en/latest/api.html should have plenty of background on everything as well as the http://alembic.readthedocs.org/en/latest/front.html#upgrading-from-alembic-0-2-to-0-3 section. Make sure you shift-refresh on readthedocs as they seem not update cache headers.

Alembic 0.3.0 is at:

http://pypi.python.org/pypi/alembic/

0.3.0
=====
- [general] The focus of 0.3 is to clean up
and more fully document the public API of Alembic,
including better accessors on the MigrationContext
and ScriptDirectory objects. Methods that are
not considered to be public on these objects have
been underscored, and methods which should be public
have been cleaned up and documented, including:

MigrationContext.get_current_revision()
ScriptDirectory.iterate_revisions()
ScriptDirectory.get_current_head()
ScriptDirectory.get_heads()
ScriptDirectory.get_base()
ScriptDirectory.generate_revision()

- [feature] Added a bit of autogenerate to the
public API in the form of the function
alembic.autogenerate.compare_metadata.

Reply all
Reply to author
Forward
0 new messages