Page MenuHomePhabricator

Fix callers to SuggestedEdits config when that feature is disabled
Closed, ResolvedPublic2 Estimated Story Points

Description

As an outcome of T369277: Provider GrowthSuggestedEdits is not supported on wiktionary sites, we're logging all accesses to the configuration of the SuggestedEdits feature while that feature is disabled ($wgGEHomepageSuggestedEditsEnabled = false;) as is the case on French wiktionary.

Currently, this is logging with debug severity to avoid excessive logspam. So to see it in production logstash, it is necessary to enable the wmdebug extension with "Verbose log" checked.

The goal is to fix all places that access this config without checking if the feature is even enabled, and then to raise the logging severity to warning.

A list of currently known places:

  • \GrowthExperiments\HelpPanelHooks::getPreferredEditor, on Special:Homepage loading
  • \GrowthExperiments\UserImpact\ComputedUserImpactLookup::getEditData, on API request to rest.php/growthexperiments/v0/user-impact/2380
  • ...

Acceptance criteria:

  • the log calls due to the provider being null in \GrowthExperiments\NewcomerTasks\ConfigurationLoader\CommunityConfigurationLoader::loadTaskTypesConfig and \GrowthExperiments\NewcomerTasks\ConfigurationLoader\CommunityConfigurationLoader::loadInfoboxTemplates have warning severity
  • there are now warnings from these calls in logstash

Event Timeline

Change #1178560 had a related patch set uploaded (by Cyndywikime; author: Cyndywikime):

[mediawiki/extensions/GrowthExperiments@master] Skip SuggestedEdits config calls if feature is disabled

https://gerrit.wikimedia.org/r/1178560

Sgs triaged this task as Medium priority.Sep 16 2025, 8:52 AM
Sgs raised the priority of this task from Medium to High.
Sgs updated the task description. (Show Details)
Michael changed the task status from Open to In Progress.Sep 23 2025, 4:57 PM
Urbanecm_WMF subscribed.

I've reviewed the code, moving back to Doing so the changes can be incorporated.

Change #1178560 merged by jenkins-bot:

[mediawiki/extensions/GrowthExperiments@master] Skip SuggestedEdits config calls if feature is disabled

https://gerrit.wikimedia.org/r/1178560

Let's see how this looks when it arrives in production, not sure if we could see a warning from this before that. Is there a beta wiki with GrowthExperiments enabled, but suggested edits disabled, except for beta wikidata?

Even in production, if I understand things correctly, then we're ever only going to maybe see warnings from French Wiktionary.

@Michael , should I go ahead and mark this task as resolved, since logstash hasn’t shown any errors for over a week? Also, should we resolve the associated tasks at the same time, or wait until QA formally closes them? cc : @Sgs

I checked and on 1.46.0-wmf.7, I'm no longer able to trigger any of these errors. Let's resolve this. ✅