Skip to content

Conversation

@oerp-odoo
Copy link
Owner

xodoo is collection of various scripts intended to be used for odoo. It is based on click-odoo to connect and manage odoo.

Scripts


xodoo-migrate
-------------

Migration tool intended to run various migration scripts for Odoo. It should be used when migration scripts directly on modules do not make sense (e.g. need to generate some customer specific data that is not directly related with any module).

@oerp-odoo oerp-odoo force-pushed the init-migrate-tool branch 2 times, most recently from f3bdf48 to 00dc111 Compare September 17, 2023 06:26
@@ -0,0 +1,74 @@
# Copyright 2018 ACSONE SA/NV (<http://acsone.eu>)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably should update to yours or girteka?

with pytest.raises(
click.ClickException, match=r"Something went wrong migrating '.+':"
):
migration.migrate(env, str(path_mig_2))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why it should fail on env.ref('base.res_partner_category_11').name = 'mig-services-111'?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It won't fail. Maybe test is confusing. I only test if it was not changed. When you get an exception on any of migration scripts, everything is rollbacked.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also note, that test is running both scripts and one of them is intended to fail. So whole transaction is rollbacked.

@oerp-odoo oerp-odoo force-pushed the init-migrate-tool branch 2 times, most recently from 90f7b20 to 533705a Compare September 18, 2023 05:38
``xodoo`` is collection of various scripts intended to be used for odoo.
It is based on ``click-odoo`` to connect and manage odoo.

Scripts
~~~~~~~

xodoo-migrate
-------------

Migration tool intended to run various migration scripts for Odoo. It
should be used when migration scripts directly on modules do not make
sense (e.g. need to generate some customer specific data that is not
directly related with any module).
@oerp-odoo oerp-odoo enabled auto-merge (squash) September 18, 2023 13:56
@oerp-odoo oerp-odoo merged commit 51943c9 into master Sep 18, 2023
@oerp-odoo oerp-odoo deleted the init-migrate-tool branch September 18, 2023 13:59
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

Successfully merging this pull request may close these issues.

3 participants