Support » Plugin: WP User Manager - User Profile Builder & Membership » Activating plugin through wp-cli fails

  • Resolved troelskn

    (@troelskn)


    If I install and activate the plugin through the web interface, it appears to work correctly, but doing the same from the wp-cli fails. I suspect it has something to do with options/settings not being initiated properly.

    Here’s the output from wp-cli:

    
    # wp plugin activate wp-user-manager
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Warning: Cannot use a scalar value as an array in /var/app/plugins/wp-user-manager/includes/options.php on line 77
    Plugin 'wp-user-manager' activated.
    Success: Activated 1 of 1 plugins.
    

    If I run wp option list after activation, I get this error:

    
    wp option list
    Fatal error: Uncaught Error: Call to a member function get_names() on null in /var/app/plugins/wp-user-manager/includes/functions.php:104
    Stack trace:
    #0 /var/app/plugins/wp-user-manager/includes/wpum-forms/class-wpum-registration-form.php(216): wpum_get_roles(true)
    #1 /var/app/plugins/wp-user-manager/includes/wpum-forms/class-wpum-registration-form.php(132): WPUM_Registration_Form->get_assigned_role()
    #2 /var/app/plugins/wp-user-manager/includes/wpum-forms/class-wpum-registration-form.php(81): WPUM_Registration_Form->setup_form(Object(stdClass))
    #3 /var/app/plugins/wp-user-manager/includes/install.php(129): WPUM_Registration_Form->__construct(1)
    #4 /var/app/plugins/wp-user-manager/includes/actions.php(286): wpum_install_registration_form()
    #5 /var/app/plugins/wp-user-manager/includes/actions.php(324): wpum_complete_setup()
    #6 /wordpress/wp-includes/class-wp-hook.php(286): wpum_finish_db_setup_after_plugin_init('')
    #7 /wordpress/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array)
    #8 /wordpress/wp-include in /var/app/plugins/wp-user-manager/includes/functions.php on line 104
    Error: The site is experiencing technical difficulties.
    
Viewing 3 replies - 1 through 3 (of 3 total)
  • troelskn

    (@troelskn)

    Further to this. If I create the option keys before activating the plugin, it appears to go better. I end up missing some pages and possibly other things that would have been created during activation.

    Plugin Author WP User Manager

    (@wpusermanager)

    Thanks for the bug report, I’ll get this fixed up in the next version. Are you all activated ok now?

    Plugin Author WP User Manager

    (@wpusermanager)

    ‚ÄčThis has now been fixed in the latest version just released – 2.1.11.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.