You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the formula is
Soluble fiber + insoluble fiber > fiber + 0.001
# sum of nutriments that compose fiber can not be greater than the value of fiber
if (
(defined $product_ref->{nutriments}{fiber_100g})
and (
(
(
(defined $product_ref->{nutriments}{'soluble-fiber_100g'})
? $product_ref->{nutriments}{'soluble-fiber_100g'}
: 0
) + (
(defined $product_ref->{nutriments}{'insoluble-fiber_100g'})
? $product_ref->{nutriments}{'insoluble-fiber_100g'}
: 0
)
) > ($product_ref->{nutriments}{fiber_100g}) + 0.001
)
)
{
push @{$product_ref->{data_quality_errors_tags}},
"en:nutrition-soluble-fiber-plus-insoluble-fiber-greater-than-fiber";
}
An option might be to increase the threshold
Soluble fiber + insoluble fiber > fiber + 0.01
In your example that would not raise a dq error because it would then be equal.
What do you think?
https://world.openfoodfacts.org/product/0076808003901/gluten-free-rotini-barilla
leads to a data quality error, while it shouldn't:
1 + 1 g (the data entered) = 2
but 1.79 + 1.79 > 3.57 (converted values).
This should be rare, it's not a high priority.
The text was updated successfully, but these errors were encountered: