Opened 10 years ago

Closed 8 years ago

Last modified 8 years ago

#814 closed defect (fixed)

Move from sqlalchemy-migrate to Alembic

Reported by: Christopher Allan Webber Owned by:
Priority: blocker Milestone: 0.9.0
Component: programming Keywords:
Cc: berkerpeksag Parent Tickets: 5017

Description

sqlalchemy-migrate is unmaintained. This is a pretty big deal generally, but especially because we want to move to Python 3, and we can't without a way forward on migrations. Current sqlalchemy migration mindshare seems to be in Alembic, we should probably move that way?

The biggest barrier here is probably how much Alembic supports sqlite. We could really use someone to look into that.

Change History (15)

comment:1 by berkerpeksag, 10 years ago

Cc: berkerpeksag added

comment:2 by Christopher Allan Webber, 10 years ago

Milestone: 0.8.0
Owner: set to Christopher Allan Webber
Priority: majorblocker
Status: newin_progress

This is pretty much done, but needs to be fully reviewed, and possibly worked on. Berker also is going to complete documentation on how to write tests.

In the meanwhile, this feature is enabled on py3 only. I'll be reviewing it shortly.

comment:3 by Christopher Allan Webber, 9 years ago

Milestone: 0.8.00.9.0

I think the chance of Alembic becoming the default in this release is small, because py3 won't be "fully supported" by then (I could be wrong!) though it should be by 0.9.0.

comment:4 by berkerpeksag, 9 years ago

Is there a timeline for 0.8? I think new installations can use Alembic safely now. Perhaps migrating old installations to Alembic could be a little problem.

comment:5 by berkerpeksag, 9 years ago

Owner: changed from Christopher Allan Webber to berkerpeksag
Summary: Move from sqlalchemy-migrate to Alembic(?)Move from sqlalchemy-migrate to Alembic

comment:6 by Christopher Allan Webber, 9 years ago

Oh, that may be my mistake thinking there was something left to do.

We haven't figured out how to move old installations from sqlalchemy -> alembic, yes. That's a problem that needs to be addressed. Maybe it can still be done in this release. Someone would need to think about what the transition process for users would be, and make sure the codebase handles that transition. IIRC no such thing is handled at the moment...

I would be more than happy to get this closed in 0.8.0 if true, though.

comment:7 by berkerpeksag, 9 years ago

Owner: berkerpeksag removed
Status: in_progressaccepted

comment:8 by berkerpeksag, 9 years ago

Parent Tickets: 5017

comment:9 by Boris Bobrov, 8 years ago

I've pushed branch alembic to the repository, please review and merge to master.

comment:10 by Boris Bobrov, 8 years ago

Status: acceptedreview

comment:11 by Boris Bobrov, 8 years ago

Nope, it was dumb of me to push it like this. Sorry, I had to re-push it and commit ids changed.

comment:12 by Christopher Allan Webber, 8 years ago

It looks like a clean switchover... I just gave it a test and it seems to be working nicely.

I think we can merge, but I want to talk to tsyesika first to see if there's any lingering sqlalchemy-migrate migrations in the wings first. Maybe we can get this merged by tomorrow?

Thanks for all your work on this, berker + breton! I'm looking forward to it finally landing.... :)

comment:13 by Jessica Tallon, 8 years ago

I'm psyched about the switched over, I do have one migration which is to add a few fields to the Activity model, I was waiting until after 0.8.2 was released and the freeze was over before I merge it. It's fairly small though, I can redo it in alembic, lets not hold up this merge :)

Excitedly looks forward to the days where a developer does not have to use sqlalchemy-migrate

comment:14 by Christopher Allan Webber, 8 years ago

Milestone: 0.9.00.8.2
Resolution: fixed
Status: reviewclosed

Alright then! Let's get this switchover party started! :)

Merged... at last! Time to throw a party! :)

comment:15 by Christopher Allan Webber, 8 years ago

Milestone: 0.8.20.9.0

All 0.8.2 tickets are being rolled over to 0.9.0

Note: See TracTickets for help on using tickets.