From 32d58e026a46a5864aa9c01e0fe4fe1321c9dfb1 Mon Sep 17 00:00:00 2001 From: benbenben2 <110821832+benbenben2@users.noreply.github.com> Date: Sat, 21 Dec 2024 13:55:25 +0100 Subject: [PATCH] fix: nutriscore grade from category change for extra virgin olive oils (#11156) ### What Because the nutriscore has changed recently, **expected_nutriscore_grade:en:** for **Extra-virgin olive oils** category has changed from C to B. See: https://theconversation.com/en-2024-le-nutri-score-evolue-pourquoi-et-que-faut-il-en-retenir-221697 ### Related issue(s) and discussion See @aleene comment in quality-data channel on Slack > Something changed? Nutri score grade from category does not match calculated grade https://world.openfoodfacts.org/product/4088700000472/olive-oil and others --- taxonomies/food/categories.txt | 2 +- tests/unit/dataqualityfood.t | 7 +------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/taxonomies/food/categories.txt b/taxonomies/food/categories.txt index e98c99a74cf12..ae705342c3bfb 100644 --- a/taxonomies/food/categories.txt +++ b/taxonomies/food/categories.txt @@ -59164,7 +59164,7 @@ ciqual_food_code:en: 17270 ciqual_food_name:en: Olive oil, extra virgin ciqual_food_name:fr: Huile d'olive vierge extra expected_ingredients:en: en:olive-oil -expected_nutriscore_grade:en: c +expected_nutriscore_grade:en: b < en:Olive oils en: Olive pomace oils diff --git a/tests/unit/dataqualityfood.t b/tests/unit/dataqualityfood.t index 516bd4f1a9e83..dbe926e9db971 100644 --- a/tests/unit/dataqualityfood.t +++ b/tests/unit/dataqualityfood.t @@ -1210,7 +1210,7 @@ $product_ref = { 'en:olive-oils', 'en:virgin-olive-oils', 'en:extra-virgin-olive-oils' ], - nutrition_grade_fr => "c", + nutrition_grade_fr => "b", nutriscore => { 2023 => {"nutrients_available" => 1,}, }, @@ -1221,11 +1221,6 @@ check_quality_and_test_product_has_quality_tag( 'en:nutri-score-grade-from-category-does-not-match-calculated-grade', 'Calculate nutriscore grade should be the same as the one provided in the taxonomy for this category', 0 ); -check_quality_and_test_product_has_quality_tag( - $product_ref, - 'en:nutri-score-grade-from-category-does-not-match-calculated-grade', - 'Calculate nutriscore grade should be the same as the one provided in the taxonomy for this category', 0 -); # category with expected ingredient. Prerequisite: "expected_ingredients:en: en:olive-oil" under "en:Extra-virgin olive oils" category, in the taxonomy # category with expected ingredient. Missing ingredients