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

Installation of new version results in duplicates of recipes and ingredients #896

Closed
karthil opened this issue Nov 27, 2024 · 4 comments
Closed

Comments

@karthil
Copy link

karthil commented Nov 27, 2024

The first time you launch after installing a new version, things go fine. The second time you launch the program, you'll be prompted to upgrade/add again. And you'll see at least one duplicate of each recipe and/or ingredient.

image
image

@karthil karthil changed the title Ingredient upgrade results in duplicates of recipes and ingredients Installation of new version results in duplicates of recipes and ingredients Nov 27, 2024
@matty0ung
Copy link
Contributor

Thanks for letting me know about this. The system is supposed to skip over duplicates when it reads in new ingredients, recipes and so on, but it's obviously failing to do so. I'll dig into what's going on and come up with a fix.

@matty0ung
Copy link
Contributor

I think I know what the cause of this is. I know how to fix it, but it's a bit of work to do it cleanly. (It's to do with when one object is owned by another -- eg a Recipe owns its "ingredient addition" records, but not its Style or equipment records. At the moment, we do a special case for each "owned" type, and are missing some special cases. The correct fix is to extend the work we already did on generalising ownership so that it's picked up in the XML and JSON import code.) TLDR is I hope to have a fix in the next week to ten days.

@karthil
Copy link
Author

karthil commented Nov 28, 2024

Thanks a bunch for the update.

@matty0ung
Copy link
Contributor

Hopefully this is fixed in 4.0.12. If not, please don't hesitate to reopen this issue!

(You will see several seeming duplicates of one of the equipment profiles, but that's because they actually have a different value in pre-boil top-up (IIRC). In the long-run we'll take this field off equipment because it's more of a recipe attribute than an equipment one.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants