Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package trytond_product for openSUSE:Factory 
checked in at 2026-02-05 18:01:08
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/trytond_product (Old)
 and      /work/SRC/openSUSE:Factory/.trytond_product.new.1670 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "trytond_product"

Thu Feb  5 18:01:08 2026 rev:18 rq:1331413 version:7.0.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/trytond_product/trytond_product.changes  
2025-09-15 19:57:16.134092776 +0200
+++ 
/work/SRC/openSUSE:Factory/.trytond_product.new.1670/trytond_product.changes    
    2026-02-05 18:06:48.299728097 +0100
@@ -1,0 +2,5 @@
+Thu Feb  5 11:23:57 UTC 2026 - Axel Braun <[email protected]>
+
+- Version 7.0.4 - Bugfix Release
+
+-------------------------------------------------------------------

Old:
----
  trytond_product-7.0.3.tar.gz

New:
----
  trytond_product-7.0.4.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ trytond_product.spec ++++++
--- /var/tmp/diff_new_pack.0hMR2W/_old  2026-02-05 18:06:48.839750783 +0100
+++ /var/tmp/diff_new_pack.0hMR2W/_new  2026-02-05 18:06:48.843750951 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package trytond_product
 #
-# Copyright (c) 2025 SUSE LLC and contributors
+# Copyright (c) 2026 SUSE LLC and contributors
 # Copyright (c) 2014-2024 Dr. Axel Braun
 #
 # All modifications and additions to the file contributed by third parties
@@ -29,7 +29,7 @@
 
 %define majorver 7.0
 Name:           trytond_product
-Version:        %{majorver}.3
+Version:        %{majorver}.4
 Release:        0
 Summary:        The "product" module for the Tryton ERP system
 License:        GPL-3.0-only

++++++ trytond_product-7.0.3.tar.gz -> trytond_product-7.0.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/CHANGELOG 
new/trytond_product-7.0.4/CHANGELOG
--- old/trytond_product-7.0.3/CHANGELOG 2025-09-03 20:47:05.000000000 +0200
+++ new/trytond_product-7.0.4/CHANGELOG 2026-02-01 11:23:36.000000000 +0100
@@ -1,4 +1,9 @@
 
+Version 7.0.4 - 2026-02-01
+--------------------------
+* Bug fixes (see mercurial logs for details)
+
+
 Version 7.0.3 - 2025-09-03
 --------------------------
 * Bug fixes (see mercurial logs for details)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/COPYRIGHT 
new/trytond_product-7.0.4/COPYRIGHT
--- old/trytond_product-7.0.3/COPYRIGHT 2025-09-03 20:47:05.000000000 +0200
+++ new/trytond_product-7.0.4/COPYRIGHT 2026-02-01 11:23:36.000000000 +0100
@@ -1,6 +1,6 @@
-Copyright (C) 2008-2025 Cédric Krier.
+Copyright (C) 2008-2026 Cédric Krier.
 Copyright (C) 2008-2013 Bertrand Chenal.
-Copyright (C) 2008-2025 B2CK SPRL.
+Copyright (C) 2008-2026 B2CK SPRL.
 Copyright (C) 2004-2008 Tiny SPRL.
 
 This program is free software: you can redistribute it and/or modify
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/PKG-INFO 
new/trytond_product-7.0.4/PKG-INFO
--- old/trytond_product-7.0.3/PKG-INFO  2025-09-03 20:47:08.314790700 +0200
+++ new/trytond_product-7.0.4/PKG-INFO  2026-02-01 11:23:39.465370200 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: trytond_product
-Version: 7.0.3
+Version: 7.0.4
 Summary: Tryton module with products
 Home-page: http://www.tryton.org/
 Download-URL: http://downloads.tryton.org/7.0/
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/tests/test_module.py 
new/trytond_product-7.0.4/tests/test_module.py
--- old/trytond_product-7.0.3/tests/test_module.py      2024-09-15 
23:48:14.000000000 +0200
+++ new/trytond_product-7.0.4/tests/test_module.py      2026-01-31 
14:18:20.000000000 +0100
@@ -130,6 +130,7 @@
         tests = [
             ('Kilogram', 100, 'Gram', 100000, 100000),
             ('Gram', 1, 'Pound', 0.0022046226218487759, 0.0),
+            ('Ounce', 1 / 7, 'Ounce', 1 / 7, 0.14),
             ('Second', 5, 'Minute', 0.083333333333333343, 0.08),
             ('Second', 25, 'Hour', 0.0069444444444444441, 0.01),
             ('Millimeter', 3, 'Inch', 0.11811023622047245, 0.12),
@@ -201,6 +202,7 @@
         tests = [
             ('Kilogram', Decimal('100'), 'Gram', Decimal('0.1')),
             ('Gram', Decimal('1'), 'Pound', Decimal('453.59237')),
+            ('Ounce', Decimal(1 / 7), 'Ounce', Decimal(1 / 7)),
             ('Second', Decimal('5'), 'Minute', Decimal('300')),
             ('Second', Decimal('25'), 'Hour', Decimal('90000')),
             ('Millimeter', Decimal('3'), 'Inch', Decimal('76.2')),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/tryton.cfg 
new/trytond_product-7.0.4/tryton.cfg
--- old/trytond_product-7.0.3/tryton.cfg        2025-05-05 10:54:28.000000000 
+0200
+++ new/trytond_product-7.0.4/tryton.cfg        2025-09-22 21:34:39.000000000 
+0200
@@ -1,5 +1,5 @@
 [tryton]
-version=7.0.3
+version=7.0.4
 depends:
     company
     ir
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/trytond_product-7.0.3/trytond_product.egg-info/PKG-INFO 
new/trytond_product-7.0.4/trytond_product.egg-info/PKG-INFO
--- old/trytond_product-7.0.3/trytond_product.egg-info/PKG-INFO 2025-09-03 
20:47:07.000000000 +0200
+++ new/trytond_product-7.0.4/trytond_product.egg-info/PKG-INFO 2026-02-01 
11:23:38.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: trytond_product
-Version: 7.0.3
+Version: 7.0.4
 Summary: Tryton module with products
 Home-page: http://www.tryton.org/
 Download-URL: http://downloads.tryton.org/7.0/
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/trytond_product-7.0.3/uom.py 
new/trytond_product-7.0.4/uom.py
--- old/trytond_product-7.0.3/uom.py    2025-05-05 10:54:28.000000000 +0200
+++ new/trytond_product-7.0.4/uom.py    2026-01-31 14:18:20.000000000 +0100
@@ -206,25 +206,28 @@
         elif factor or rate:
             raise ValueError("factor and rate not allowed for same category")
 
-        if from_uom.accurate_field == 'factor':
-            amount = qty * from_uom.factor
-        else:
-            amount = qty / from_uom.rate
-
-        if factor and rate:
-            if _accurate_operator(factor, rate) == 'rate':
-                factor = None
+        if from_uom != to_uom:
+            if from_uom.accurate_field == 'factor':
+                amount = qty * from_uom.factor
             else:
-                rate = None
-        if factor:
-            amount *= factor
-        elif rate:
-            amount /= rate
+                amount = qty / from_uom.rate
 
-        if to_uom.accurate_field == 'factor':
-            amount = amount / to_uom.factor
+            if factor and rate:
+                if _accurate_operator(factor, rate) == 'rate':
+                    factor = None
+                else:
+                    rate = None
+            if factor:
+                amount *= factor
+            elif rate:
+                amount /= rate
+
+            if to_uom.accurate_field == 'factor':
+                amount = amount / to_uom.factor
+            else:
+                amount = amount * to_uom.rate
         else:
-            amount = amount * to_uom.rate
+            amount = qty
 
         if round:
             amount = to_uom.round(amount)
@@ -254,27 +257,30 @@
         elif factor or rate:
             raise ValueError("factor and rate not allow for same category")
 
-        format_ = '%%.%df' % uom_conversion_digits[1]
+        if from_uom != to_uom:
+            format_ = '%%.%df' % uom_conversion_digits[1]
 
-        if from_uom.accurate_field == 'factor':
-            new_price = price / Decimal(format_ % from_uom.factor)
-        else:
-            new_price = price * Decimal(format_ % from_uom.rate)
-
-        if factor and rate:
-            if _accurate_operator(factor, rate) == 'rate':
-                factor = None
+            if from_uom.accurate_field == 'factor':
+                new_price = price / Decimal(format_ % from_uom.factor)
             else:
-                rate = None
-        if factor:
-            new_price /= Decimal(factor)
-        elif rate:
-            new_price *= Decimal(rate)
+                new_price = price * Decimal(format_ % from_uom.rate)
 
-        if to_uom.accurate_field == 'factor':
-            new_price = new_price * Decimal(format_ % to_uom.factor)
+            if factor and rate:
+                if _accurate_operator(factor, rate) == 'rate':
+                    factor = None
+                else:
+                    rate = None
+            if factor:
+                new_price /= Decimal(factor)
+            elif rate:
+                new_price *= Decimal(rate)
+
+            if to_uom.accurate_field == 'factor':
+                new_price = new_price * Decimal(format_ % to_uom.factor)
+            else:
+                new_price = new_price / Decimal(format_ % to_uom.rate)
         else:
-            new_price = new_price / Decimal(format_ % to_uom.rate)
+            new_price = price
 
         return new_price
 

Reply via email to