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

[14.0][MIG] uom #2666

Merged
merged 2 commits into from
Jun 6, 2021
Merged

[14.0][MIG] uom #2666

merged 2 commits into from
Jun 6, 2021

Conversation

RaulOForgeFlow
Copy link

Migration scripts.

I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

@MiquelRForgeFlow MiquelRForgeFlow added this to the 14.0 milestone Apr 19, 2021
@MiquelRForgeFlow MiquelRForgeFlow changed the title [14.0][MIG] uom: migration to v14 [14.0][MIG] uom Apr 19, 2021
@RaulOForgeFlow RaulOForgeFlow force-pushed the 14.0-mig-uom branch 3 times, most recently from 458de52 to bfbf008 Compare April 28, 2021 07:20
@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

Deleting a field entry doesn't mean that the entry is nullified. In this
case, it means the the default value is applied, so we put such value.
@pedrobaeza
Copy link
Member

Added a correction for some uom roundings, so merging.

@pedrobaeza pedrobaeza merged commit 2e21962 into OCA:14.0 Jun 6, 2021
@pedrobaeza pedrobaeza deleted the 14.0-mig-uom branch June 6, 2021 12:14
@@ -39,7 +39,7 @@
<field name="name">qt (US)</field>
</record>
<record id="product_uom_unit" model="uom.uom">
<field name="rounding"/>
<field name="rounding" eval="0.01"/>

Choose a reason for hiding this comment

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

violates _check_category_reference_uniqueness

https://github.com/OCA/OCB/blob/13.0/addons/uom/models/uom_uom.py#L83-L94

File "/home/gcapalbo/k240/migrate_therp/build-14.0/parts/odoo/addons/uom/models/uom_uom.py", line 85, in check_category_reference_uniqueness
raise ValidationError(
("UoM category %s should only have one reference unit of measure.") % (self.env['uom.category'].browse(uom_data['category_id']).name,))
odoo.exceptions.ValidationError: UoM categorie Unitheeft slechts één referentie maateenheid.

Copy link
Contributor

Choose a reason for hiding this comment

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

But this error doesn't have any relation with the rounding. This constrain already existed in v13, and your problem seems more a problem of your db data, which has something wrong and you should solve manually before migrating.

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

Successfully merging this pull request may close these issues.

6 participants