Thanks!
]]>RESET REMOVE FILES (keep only registered image sizes) 82 % [==========================================================================================================> ] 0:16 / 0:1
Fatal error: Uncaught Error: Call to undefined method SIRSC_Image_Regenerate_Select_Crop::attempt_to_create_metadata() in D:\Sites\mineral\wp-content\plugins\image-regenerate-select-crop\image-regenerate-select-crop.php:2254
Stack trace:
#0 D:\xxxxxxxx\wp-content\plugins\image-regenerate-select-crop\inc\wp-cli.php(414): SIRSC_Image_Regenerate_Select_Crop::general_sizes_and_files_match('40529', false, Array)
I got this error after this wp cli command : wp sirsc resetcleanup 1 all 0
]]>wp cache-warmer start
I get this error:
Error: 'cache-warmer' is not a registered wp command. See 'wp help' for available commands.
So the WP-CLI command is not being registered as it should.
]]>Activating 'download-manager'...
Warning: Some code is trying to do a URL redirect. Backtrace:
#0 /var/www/html/wp-includes/class-wp-hook.php(326): WP_CLI\Utils\wp_redirect_handler('https://mydoma...')
#1 /var/www/html/wp-includes/plugin.php(205): WP_Hook->apply_filters('https://mydoma...', Array)
#2 /var/www/html/wp-includes/pluggable.php(1396): apply_filters('wp_redirect', 'https://mydoma...', 302)
#3 /var/www/html/wp-content/plugins/download-manager/src/Admin/Menu/Welcome.php(32): wp_redirect('https://mydoma...')
#4 /var/www/html/wp-includes/class-wp-hook.php(326): WPDM\Admin\Menu\Welcome->welcomeRedirect('download-manage...')
#5 /var/www/html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#6 /var/www/html/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#7 /var/www/html/wp-admin/includes/plugin.php(730): do_action('activated_plugi...', 'download-manage...', false)
#8 phar:///usr/local/bin/wp-cli/vendor/wp-cli/extension-command/src/Plugin_Command.php(363): activate_plugin('download-manage...', '', false)
#9 phar:///usr/local/bin/wp-cli/vendor/wp-cli/extension-command/src/WP_CLI/CommandWithUpgrade.php(252): Plugin_Command->activate(Array)
#10 phar:///usr/local/bin/wp-cli/vendor/wp-cli/extension-command/src/Plugin_Command.php(916): WP_CLI\CommandWithUpgrade->install(Array, Array)
#11 [internal function]: Plugin_Command->install(Array, Array)
#12 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/CommandFactory.php(100): call_user_func(Array, Array, Array)
#13 [internal function]: WP_CLI\Dispatcher\CommandFactory::WP_CLI\Dispatcher\{closure}(Array, Array)
#14 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/Subcommand.php(497): call_user_func(Object(Closure), Array, Array)
#15 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(441): WP_CLI\Dispatcher\Subcommand->invoke(Array, Array, Array)
#16 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(464): WP_CLI\Runner->run_command(Array, Array)
#17 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1295): WP_CLI\Runner->run_command_and_exit()
#18 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/LaunchRunner.php(28): WP_CLI\Runner->start()
#19 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/bootstrap.php(83): WP_CLI\Bootstrap\LaunchRunner->process(Object(WP_CLI\Bootstrap\BootstrapState))
#20 phar:///usr/local/bin/wp-cli/vendor/wp-cli/wp-cli/php/wp-cli.php(32): WP_CLI\bootstrap()
#21 phar:///usr/local/bin/wp-cli/php/boot-phar.php(20): include('phar:///usr/loc...')
#22 /usr/local/bin/wp-cli(4): include('phar:///usr/loc...')
I guess, when activating in CLI mode the redirect should not be executed. Maybe it’s a good idea to print some post-installation instructions like visit <url> to setup the plugin
. This would be a good fallback.
elementor-hf
custom post type does not appear in WP-CLI exports, while it is accessible through the standard WordPress export functionality.init
hook.functions.php
file to manually register the custom post type when WP-CLI is detected:add_action('init', function() {
if ( defined( 'WP_CLI' ) && WP_CLI ) {
register_post_type('elementor-hf', array(
'label' => 'Header Footer',
'public' => true,
'show_in_rest' => true,
'supports' => array('title', 'editor', 'thumbnail'),
'has_archive' => false,
'rewrite' => array('slug' => 'elementor-hf'),
));
}
});
3. Long-term Concerns: While the above code works, it’s not an ideal long-term solution for theme updates or changes. I want to ensure that the plugin registers its custom post types properly in the WP-CLI environment without needing to override or manually register them.
Request for Assistance:
elementor-hf
post type is consistently available when using WP-CLI, perhaps through a filter or action that ensures it gets registered regardless of the environment?SS – https://prnt.sc/8Pgwe_8i35xi
Thank you for your assistance!
]]>For a few months the site https://hardistyconstruction.com/ has been throwing an error instead of updating. Updating through the admin GUI works fine.
EDIT
Another site, https://reducethechaos.com/ has also been failing. Forgot this when posting. So two environments.
All other updates work fine on this site. The problem seems to be this plugin, this site, and wp-cli. Any other combination succeeds.
Any suggestions for a place to begin troubleshooting?
wp-cli output
/home/melhornconstruct/public_html/hardistyconstruction.com
Enabling Maintenance mode…
Disabling Maintenance mode…
name old_version new_version status
really-simple-ssl 8.3.0.1 9.0.0 Error
I currently do a manual test- ensuring I can login, create a dummy page or post, delete the page/post and check nothing major appears in the dashboard health check. Is this enough test coverage or are there other basic things I could check to test the success of the upgrade? Note, it’s difficult to test functionality of individual plugins as there as so many and they vary from site to site.
What’s the best way to automate these types of tests? I wondered if the above could be successfully done via CLI commands? Or do people recommend using something like Browserstack or another testing tool?
All thoughts appreciated. TIA , P26.
]]>How to recover from this? I hope I don’t have to restore from backup for this because some new contents had gone into the site, and I hope there is another solution other than restoring from backups.
The output from the command recommend to alter the table, but I don’t quite understand how to do it and I think the output from the command is not a complete statement, maybe it’s too long that why it’s only showing partial.
]]>