Drop tables on missing resources & table name change handling#713
Drop tables on missing resources & table name change handling#713zachdaniel merged 11 commits intoash-project:mainfrom
Conversation
|
This is definitely a great QOL improvement, but when it comes to generating migrations that can result in such a significant loss of data I hesitate a little bit. I think we should prompt also on table deletion. If they say no, we should record in the snapshot that they opted out and not ask them again in the future. Thoughts? |
|
I think that makes sense. Given how critical migrations are, you really don't want to make any assumptions about what the user wants. I'll work on implementing that! |
|
I've gone through and implemented a confirmation step for dropping tables as well; feedback/suggestions appreciated! |
|
Please run |
|
My apologies about those errors 😅 They should hopefully all be resolved with the new commits! |
|
Looks like code generation required in test:
|
…tables that have been opted out
|
I was pretty stumped for a while since that error didn't originally trigger on my local envoirnment, but I found that the migration generator was defaulting to dropping orphan tables during the check. That's why it kept triggering code generation. The new commit should resolve that; apologies for all the unexpected issues! |
|
🚀 Thank you for your contribution! 🚀 |
Contributor checklist
Leave anything that you believe does not apply unchecked.
Attempts to resolve #224 and #256 with regards to the migration generator, notably with table dropping upon resources missing and prompting the user if the generator detects a potential name change intent.