Conversation
|
One thing that probably breaks with this change is exporting a site with broken code (like a broken plugin, for example). To mitigate this, we could consider passing the Jeroen mentioned that:
I don't entirely understand why this is the case… SQL files can only be imported into existing websites. Those files don't need to contain an entire database; we simply execute the SQL statements in the file. As for export, I also don't understand what scenario we're talking about when we say "corrupt/empty/incomplete database". I understand how broken code could be problematic, but I already suggested a potential solution to that previously… @Automattic/yolo, I welcome your input |
|
Using The changes in this PR makes sense to me and I like Fredrik's suggestion of adding Thanks for the changes @fredrikekelund !, |
|
@sejas @fredrikekelund, what happens when you try to import database dump using |
|
Closing this per our discussion in Slack p1734445093481979/1734431651.518169-slack-C04GESRBWKW |
We currently run the CLI commands on
before_wp_load. There's a brief discussion in #4 (comment) about why we do that, which boils down to ensuring these commands work even when the WP installation is broken. However, messing with the normal WP load order like we do here (we "manually" load thesqlite-database-integrationplugin) can be problematic. For example, it caused the following bug in Studio: https://github.com/Automattic/dotcom-forge/issues/10054I need to do some more testing before we can determine if we should land this change or not, but I've confirmed that this PR fixes https://github.com/Automattic/dotcom-forge/issues/10054.
Any input from @sejas and @wojtekn is very welcome! @sejas and I already paired over this, so you're already very familiar with the problem 😊