blogvault / wpcom-migration

Migration Plugin for WordPress.com Migrations
0 stars 0 forks source link

Detect errors on the site when migration is done #55

Closed markbiek closed 2 weeks ago

markbiek commented 2 months ago

This more of a question/exploration, not something that needs to be implemented yet.

Would it be possible for the migration process to detect critical errors on the destination site? It could display a message to the user like this:

Your migration was a success, but your migrated site is encountering a critical error. It happens! Contact Support to get help fixing those up.

bv-shivamsharma commented 1 month ago

@markbiek Thank you for sharing the feedback, I'll share these requirements with the team and will get back to you.

bv-shivamsharma commented 1 month ago

Hi @markbiek

If the website encounters a critical error, this message will be shown on the migration completion page.

image

image

markbiek commented 1 month ago

Hi @bv-shivamsharma

Is it possible to customize that at all? If possible, the messaging we used above would be great

Your migration was a success, but your migrated site is encountering a critical error. It happens! Contact Support to get help fixing those up.

We'd also like to have "Contact Support" link to the same support contact we listed on other screens.

@fditrapani Do you have any additional feedback here?

bv-shivamsharma commented 1 month ago

Hi @markbiek, no worries, will get the changes deployed.

bv-shivamsharma commented 1 month ago

Hi @markbiek, the changes have been deployed. Can you please have a look?

markbiek commented 1 month ago

I'm testing this now but I think it will be good. Apologies because I misunderstood your original comment and didn't realize the second screenshot was showing exactly what we want!

bv-shivamsharma commented 1 month ago

Hi @markbiek, no worries. Please let me know if you wish to get any changes deployed after you're done with the testing. I'll be more than happy to get those deployed at the earliest.

markbiek commented 1 month ago

I'm having trouble activating this.

I have a migrated site that's in an critical error state (https://markbiek344.wpcomstaging.com/) but the migration status page isn't showing the error (https://migrate.blogvault.net/migration/292c150a8180502ce03bbf1a3b609796).

bv-shivamsharma commented 1 month ago

I checked the logs and it looks like there was a modification on ./wp-content/plugins/index.php to replicate the critical error, however, after migrating the files our system runs a full check to check on the missing or incomplete files, and given, the file ./wp-content/plugins/index.php was modified our system replaced the modified file and got a 200 response code upon destination site health check.

Could you please share the error logs of your website so I can debug this further? I need to know why the critical error is still there on your website.

Update - You could replicate the critical error by adding this line at the end of your wp-config.php file require_once('non_existent_file.php');

markbiek commented 1 month ago

That site is currently running a small plugin that throws a critical error.

bv-shivamsharma commented 2 weeks ago

@markbiek Can we close this issue?

markbiek commented 2 weeks ago

Yup, I think we're good!