How to fix usability accounts

From Wikimedia Usability Initiative

If a feature is not available for a given Usability N account but is for Usability M, the following causes are possible:

  • User JS/CSS out of sync
  • Preference has disappeared
    • Check values of wgWikiEditorEnabledModules and wgVectorEnabledModules in Firebug console. If the modules you're interested in are set to true, preferences are not the problem
    • Fire up sql enwiki on fenari and run SELECT up_user, up_property, up_value FROM user, user_properties WHERE up_user=user_id AND user_name='Usability N'; to get a list of all preferences for that user. If the preference you're looking for isn't in the list, add it with INSERT INTO user_properties (up_user, up_property, up_value) VALUES (12345, 'prefname', 1);
    • Fire up php /home/wikipedia/common/wmf-deployment/maintenance/eval.php --wiki=enwiki and type User::newFromName('Usability N')->invalidateCache();
    • If it still doesn't work, log the user out and back in. It's possible that the preferences row has disappeared again, in which case you'll need to add it again. If possible, do that when the user is logged out

$user->invalidateCache(); In eval.php