Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Waterline truncated a join table - this is a MAJOR issue #812
I had an issue on a production server where all data from a join table was dropped. After days of investigation, I found out that waterline generated a delete statement without any where clause on that table.
See the last delete statement that does not have a where clause. This will in fact truncate the table thus removing players from all games.
I traced the code and the following change created this issue: 388473f
I tried commenting the if and while I get an exception because the second delete does not return any result (
Also related to / duplicate of https://github.com/balderdashy/sails-mysql/issues/174
Wow! So this is a known issue for more than a month now. I had a major data loss in production (lost one day since i had to restore a nightly backup) that could have been avoided by simply disclosing the issue on the sails list.
That's it, i'm done with waterline. Thanks for the kick start but, i'm rewriting the codebase to use another lib.