Page MenuHomePhabricator

CommunityConfiguration: Use a single term to describe a provider ID
Closed, ResolvedPublic

Description

In MediaWiki-extensions-CommunityConfiguration, client extensions register their providers like this:

"CommunityConfiguration": {
	"Providers": {
		"Mentorship": {
			"store": {
				"type": "wikipage",
				"args": [
					"MediaWiki:GrowthExperimentsMentorship.json"
				]
			},
			"validator": {
				"type": "jsonschema",
				"args": [
					"GrowthExperiments\\Config\\Schemas\\MentorshipSchema"
				]
			},
			"type": "mw-config"
		}
}

Since https://gerrit.wikimedia.org/r/c/mediawiki/extensions/CommunityConfiguration/+/1015078, we're referring to the Mentorship as the ID (key under which the provider is registered), and to whatever the communityconfiguration-LOWERCASE-ID-title (so in this case, communityconfiguration-mentorship-title) message resolves to as the name.

However, this refactor was not done in CommunityConfiguration's frontend and PROVIDER_NAME still refers to the title, not name. This causes confusion, as name means something else in BE and FE. To ensure CommunityConfiguration stays maintainable, this should be fixed.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
KStoller-WMF lowered the priority of this task from High to Medium.Apr 15 2024, 6:19 PM

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

[mediawiki/extensions/CommunityConfiguration@master] Refactor the frontend to use 'providerId' instead of 'providerName'

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

Change #1036617 had a related patch set uploaded (by Sergio Gimeno; author: Sergio Gimeno):

[mediawiki/extensions/CommunityConfiguration@master] Rename remaining ambiguous provider `name` to `providerId`

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

Change #1035322 merged by jenkins-bot:

[mediawiki/extensions/CommunityConfiguration@master] Refactor the frontend to use 'providerId' instead of 'providerName'

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

Change #1036617 merged by jenkins-bot:

[mediawiki/extensions/CommunityConfiguration@master] Rename remaining ambiguous provider `name` to `providerId`

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