-
-
Notifications
You must be signed in to change notification settings - Fork 385
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
feat: added error facet for sum of -ose nutriments greater than sugars #8120
Merged
benbenben2
merged 4 commits into
main
from
feat_add_quality_facet_nutrition_sum_of_nutriment_composing_sugar_greater_than_sugar
Feb 24, 2023
Merged
feat: added error facet for sum of -ose nutriments greater than sugars #8120
benbenben2
merged 4 commits into
main
from
feat_add_quality_facet_nutrition_sum_of_nutriment_composing_sugar_greater_than_sugar
Feb 24, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
🧽 Data quality
https://wiki.openfoodfacts.org/Quality
🧬 Taxonomies
https://wiki.openfoodfacts.org/Global_taxonomies
🧪 tests
labels
Feb 18, 2023
…iment_composing_sugar_greater_than_sugar
Codecov Report
@@ Coverage Diff @@
## main #8120 +/- ##
==========================================
+ Coverage 45.42% 45.50% +0.08%
==========================================
Files 102 102
Lines 20230 20261 +31
Branches 4628 4629 +1
==========================================
+ Hits 9189 9220 +31
Misses 9943 9943
Partials 1098 1098
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
stephanegigandet
approved these changes
Feb 24, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect, thank you!
…iment_composing_sugar_greater_than_sugar
typo Co-authored-by: Stéphane Gigandet <stephane@openfoodfacts.org>
Kudos, SonarCloud Quality Gate passed! |
benbenben2
deleted the
feat_add_quality_facet_nutrition_sum_of_nutriment_composing_sugar_greater_than_sugar
branch
February 24, 2023 21:35
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
🧽 Data quality
https://wiki.openfoodfacts.org/Quality
🧬 Taxonomies
https://wiki.openfoodfacts.org/Global_taxonomies
🧪 tests
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Part to #6850 (maybe solve it)
All make commands were successful.
About unit tests:
Remark: code is same logic as for "en:nutrition-sugars-plus-starch-greater-than-carbohydrates" (see lines above changes).
Remark: contrarily to "en:nutrition-saturated-fat-greater-than-fat" (see lines below changes), we did not start with (defined $product_ref->{nutriments}{"sugars_100g"}) ? $product_ref->{nutriments}{"sugars_100g"} : 0 because there are some products where -ose nutriments are given but NOT sugar. Hence, enforcing sugars value to be 0 when it is not defined would generate some false positives.
It seems not to be the case for fat and saturated fat: some_examples_in_mirabelle.
And it is not clear for carbohydrates: see_in_mirabelle
@CharlesNepote may be interested to look at it.