Bug: "FOREIGN KEY constraint failed." when upgrading database #64
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I just upgraded from 1.1.0 to 1.2.0, and I'm unable to update my database. I get through migration #10 then get the error "FOREIGN KEY constraint failed."
I've attached two copies of my database in a ZIP file:
The docker logs don't have any further information aside from the error message.
Thanks a lot for providing the two copies of your database.
For some reason your inventory contains the parts from the Colosseum (https://rebrickable.com/sets/10276-1/colosseum/) even though it has been deleted.
There is probably a bug somewhere that doesn't delete properly the parts of a set which needs to be fixed, and then another extra step to ignore parts from sets that have been already deleted but have remnants.
I'm looking into it 🙂
The deletion bug does not seem to exist anymore in the latest code. I'll prepare a workaround for the migration step for version 11.
@matthew in the meantime if you do not wish to wait for the new release, you can manually delete the bogus entries in your database.
If you have direct access to your database file, with:
or through docker, with:
After that, the database upgrade should go through.
(I am obviously missing your sets images since I never added them 😂)
That would explain it! I've been using BrickTracker since 1.0 and I did accidentally add the Colosseum to my list rather than my wishlist.
That worked, thank you!