Skip to content
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

Broken import on specific chefkoch.de recipe #666

Closed
philip-n opened this issue Jun 7, 2021 · 6 comments
Closed

Broken import on specific chefkoch.de recipe #666

philip-n opened this issue Jun 7, 2021 · 6 comments
Labels
bug Something isn't working

Comments

@philip-n
Copy link

philip-n commented Jun 7, 2021

Is your feature request related to a problem? Please describe.
When importing a certain recipe from Chefkoch.de, one ingredient was not imported.

Describe the solution you'd like
If there is a (potential) error during import, display some information so that the user can check manually.

Reason: If URL import results in a seemingly correct result (e.g. long list of ingredients and the full textual description), it's easy to assume that everything went well.

Describe alternatives you've considered
none

Additional context
On https://www.chefkoch.de/rezepte/804871184310070/Brokkoli-Bratlinge.html , the eggs in the ingredients list are a hyperlink for some reason. They were missing after import.

@philip-n philip-n added the enhancement New feature or request label Jun 7, 2021
@vabene1111
Copy link
Collaborator

you are right, this should not happen without any kind of notice

@vabene1111 vabene1111 added bug Something isn't working and removed enhancement New feature or request labels Jun 8, 2021
@smilerz
Copy link
Collaborator

smilerz commented Jun 8, 2021

I can look at this and see where the failure is occurring.

If it is in tandoor I'll fix if possible and add a test case for this scenario, otherwise it will need to be handled upstream in recipe_scrapers.

In general though, given the huge number of ways that imports can fail, I'm not 100% sure we can notify if a specific ingredient is missed (or any other failure/attribute for that matter.)

@vabene1111
Copy link
Collaborator

you are probably right. The old importer handled ingredients that were not parsable (which seems to be the case here) by showing the "raw" above a row of empty or wrongly filled inputs. But if recipe-scrapers completely removes those lines we are probably not able to do much about it

@philip-n
Copy link
Author

philip-n commented Jun 8, 2021

@smilerz

In general though, given the huge number of ways that imports can fail, I'm not 100% sure we can notify if a specific ingredient is missed (or any other failure/attribute for that matter.)

I don't think there is a need for specific notifications. Just a best-effort general warning along the lines of "There might have been a problem during import. Please double-check to make sure that all data is correct (e.g. all ingredients listed with correct amounts, full recipe text imported etc)".

@smilerz
Copy link
Collaborator

smilerz commented Jun 8, 2021

I don't think there is a need for specific notifications. Just a best-effort general warning along the lines of "There might have been a problem during import. Please double-check to make sure that all data is correct (e.g. all ingredients listed with correct amounts, full recipe text imported etc)".

The good news is that the error is in tandoor and should be fixed today or tomorrow.
The bad news is that the way the import process works every import would report an error - it tries getting data in one method, if that fails tries another, etc, etc so that approach wouldn't work as there isn't any way to determine if the failure was expected or unusual.

@philip-n
Copy link
Author

philip-n commented Jun 8, 2021

Fair enough! Thanks for looking into it and fixing this 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants