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
Some foods don't have an FDC ID, especially produces (In this example Lime Peel)
fdc_id is not nullable which throws a validation error if you try to add a food without it.
Make the field nullable for foods that don't have one
The text was updated successfully, but these errors were encountered:
mikhail5555
changed the title
FDC ID is not allowed to be nullable for new food import
FDC ID is not allowed to be empty for new food import
Sep 6, 2023
Issue:
Some foods don't have an FDC ID, especially produces (In this example Lime Peel)
fdc_id is not nullable which throws a validation error if you try to add a food without it.
https://github.com/TandoorRecipes/open_data_plugin/blob/master/models.py#L114
In some other models it seems to be nullable:
https://github.com/TandoorRecipes/open_data_plugin/blob/master/models.py#L82
Request:
Response:
Screenshot:
Proposed solution:
Make the field nullable for foods that don't have one
The text was updated successfully, but these errors were encountered: