Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ponyorm migration tool #16

Open
steinster opened this issue Aug 7, 2013 · 63 comments
Open

ponyorm migration tool #16

steinster opened this issue Aug 7, 2013 · 63 comments
Assignees

Comments

@steinster
Copy link

Hello,

I'm not sure if this is the place to put this question. If there is a better place please let me know.

Is there a DB migration tool for pony orm? Something like alembic for sqlalchemy..

@amalashkevich
Copy link
Member

Hi,
There is no such a tool yet, although we are working on it. Will let you know when it is ready. Thank you for asking.

On Aug 7, 2013, at 11:51 AM, steinster [email protected] wrote:

Hello,

I'm not sure if this is the place to put this question. If there is a better place please let me know.

Is there a DB migration tool for pony orm? Something like alembic for sqlalchemy..


Reply to this email directly or view it on GitHub.

@steinster
Copy link
Author

If you need any help with it I would love to help with the project a bit.

@amalashkevich
Copy link
Member

Thank you, I appreciate it, we'll get in touch.

On Aug 7, 2013, at 7:27 PM, steinster [email protected] wrote:

If you need any help with it I would love to help with the project a bit.


Reply to this email directly or view it on GitHub.

@ghost ghost assigned amalashkevich Aug 30, 2013
@amalashkevich
Copy link
Member

Hi,
We have created the mailing list [email protected]. This is the place to ask questions, share experiences, or discuss the Pony ORM with other users and the Pony ORM developers. You can subscribe to the list at http://ponyorm-list.ponyorm.com
Regards,
Alexey

@guyskk
Copy link

guyskk commented Oct 30, 2015

+1

1 similar comment
@NiklasRosenstein
Copy link

+1

@andreymal
Copy link

Even third-party tools are still not exist?

@nadermx
Copy link

nadermx commented May 12, 2016

Any specific parts I can try and help with getting this done? I need migrations pretty badly at this point

@kozlovsky
Copy link
Member

Right now we are working on release with full JSON support, and after that we will switch to working on migrations. Hope the initial version will be released soon after that..

@Vic020
Copy link

Vic020 commented Jun 20, 2016

+1
get in touch

@hackrole
Copy link

+1, waiting for your staff

@misakar
Copy link

misakar commented Aug 7, 2016

+1

@nadermx
Copy link

nadermx commented Sep 14, 2016

@kozlovsky I saw that you pushed the json update! Any word or any suggestions on how I could contribute with some code in the method you have in mind in order to get migrations done quicker. Having to do manual alter tables and indexing is getting to be cumbersome

@darkf
Copy link

darkf commented Oct 14, 2016

Yeah, this is the main missing feature of Pony right now. It's excellent otherwise, but really needs migrations (preferably automatic).

@pingf
Copy link

pingf commented Oct 19, 2016

really needed!

@sighalt
Copy link

sighalt commented Nov 28, 2016

+1

2 similar comments
@TimothyBramlett
Copy link

+1

@pylover
Copy link

pylover commented Nov 29, 2016

+1

@danielhrisca
Copy link

Any progress with this topic?

@dimi-tree
Copy link

+1

@darkf
Copy link

darkf commented Dec 3, 2016

@amalashkevich @kozlovsky Any status update on this? There are approximately a kajillion people waiting on and +1ing this, it would be nice to see where it's going or if we should migrate (pun intended) to another ORM with this functionality.

@kozlovsky
Copy link
Member

The core migration functionality is done, we need approximately two weeks to release the first version

@darkf
Copy link

darkf commented Dec 4, 2016

Thanks for the update! Good to hear.

@danielhrisca
Copy link

Great news! Thank you for your work!

@famargar
Copy link

Keep us posted!

@kafeg
Copy link

kafeg commented Dec 13, 2016

Hi! Very important feature! Waiting for release)

@kickapoo
Copy link

In my case this is the only thing that block me for full pass to pony.
Please @kozlovsky if you could give another feedback about the current state will be most appriciated.

@kozlovsky
Copy link
Member

At this moment we have some internal branch which can handle simple migrations (like, adding/deleting entities, attributes and relationships). I hope we can push it to GitHub really soon. But before that we need to do some final review during this week.

@johanngomes
Copy link

Hi, @kozlovsky and team. Any news on when we can have this migration functionality? Thanks,

@kozlovsky
Copy link
Member

Hi, I just pushed a new branch orm-migrations with the first version of PonyORM migrations. You can read the description of API here: https://github.com/ponyorm/pony/tree/orm-migrations/pony/migrate

The code is very raw at this point and not intended for production usage yet, we still need to work on it. I think really simple use-cases for PostgreSQL and MySQL should work, but SQLite support is limited, and merge functionality is untested. Adding entity or attribute should work, but, say, changing inheritance hierarchy or modifying a type of relationship will raise NotImplementedError. Anyway, I hope the working version of migrations is close.

@johanngomes
Copy link

Thank you for your update, @kozlovsky !

@hammeronthenet
Copy link

Hi @kozlovsky,
nice!

One question: what's better to install 0.8 version? When do you think 0.8 will be available on pip?

Thank you!

@zxytim
Copy link

zxytim commented Jun 25, 2018

How's migration going now?

@patrickporto
Copy link

In moment has some alternative for schema migrations on PonyORM?

@nadermx
Copy link

nadermx commented Jun 26, 2018

I can confirm that migrations is working, if you want to install it via pip currently do the following

pip install git+git://github.com/ponyorm/pony.git@orm-migrations

All the documentation on how to do migration can be found here

Also if you are using pony with flask blueprints, please note ref another issue

generate_mapping call from app/init.py to some submodule like app/main.py which is not imported when from app import models line of migrate.py module is executed

@japrogramer
Copy link

what is the status of this orm-migrations? when will it be merged upstream.

@dibstern
Copy link

dibstern commented Oct 3, 2018

+1
Pony seems awesome, but I can’t use an ORM without a reliable migrations tool. Super keen for this to be released and to start using Pony

@Elijas
Copy link

Elijas commented Jan 7, 2019

The way I currently solve the migration problem is by partly using a SQL migration script generator (Liquibase at the moment).

I create two schemas with ponyorm, then run them apply them on two different databases, then run the SQL diff tool to generate SQL code (ALTER, etc.)

Any additional migration of data itself is done within the python, around the SQL code

@Elijas
Copy link

Elijas commented Jan 7, 2019

By the way - is a subset of migration scripts already ready for production code? Even that would be great

@japrogramer
Copy link

@Elijas sounds intense. lots of steps to introduce an error.
Would prefer a similar migration layout to the django orm.

@Elijas
Copy link

Elijas commented Jan 8, 2019

@Elijas sounds intense. lots of steps to introduce an error.
Would prefer a similar migration layout to the django orm.

I think so too, but I kinda really want to keep ponyorm :D

To make it less error-prone, I'm currently considering using

Are there any other good alternatives to yoyo? For the schema-migrations, as I'd rather migrate data with pony

@Elijas
Copy link

Elijas commented Jan 8, 2019

I've searched some info about migrations, and why it's a difficult task - I think this article summarizes it best, though you guys might want to look at it, to acquire some sympathy for the @ steinster

@zxytim
Copy link

zxytim commented May 3, 2019

How's migration going now? It's been more than a year since my last check.
Is there any roadmap that migration will be merged into orm branch, or the release of 0.8.0?
Really looking forward to the official release of migration function.
@kozlovsky Is there anything we could do help accelerate this process? How can we help you?

@Elijas
Copy link

Elijas commented May 3, 2019 via email

@sostholmwork
Copy link

Any updates on this? :)

@fluffy-critter
Copy link

Even without a full migration tool, is there a mechanism that can be used to do simple column and foreign key additions to a schema in a fairly DB-independent manner? Like the problem seems to become much simpler if you don’t have to worry about renaming or changing data types or the like.

@hadim
Copy link

hadim commented Jan 19, 2021

I am also waiting for this to be released. The is a critical feature we need to start using pony.

Does anyone here has experience using nomade or yoyo?

@hadim
Copy link

hadim commented Jan 19, 2021

xref with #563

@jbvsmo
Copy link

jbvsmo commented Mar 8, 2021

Yay, anybody else here also stuck with Pony ORM because some previous developer picked it without realizing there is no migration support?

This issue is almost 8 years old. Should we still have hope or move on?

@Elijas
Copy link

Elijas commented Mar 8, 2021

@jbvsmo I'd recommend reaching out in their telegram chats - that's a direct line of communication with the developers, you probably will get your to your answer the fastest this way.

Although in my personal opinion, I wouldn't advise to keep your hope too up high.

@daveflr
Copy link

daveflr commented Nov 3, 2021

Just move one guys

@wwarreniv
Copy link

any update on migrations for pony? We'd love to help out.

@kentaasvang
Copy link

updates?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests