Page MenuHomePhabricator

VisualEditorFeatureUse validation errors
Closed, ResolvedPublic

Description

The above change was reverted in https://gerrit.wikimedia.org/r/c/operations/mediawiki-config/+/905979 and the revert was deployed at around 15:15 UTC today. I reverted because the number of VisualEditorFeatureUse validation errors increased and I don't have time to investigate them now. Of note is that there was only one normalised validation error message:

'.event.integration' should be string, '.event.integration' should be equal to one of the allowed values, '.event.editor_interface' should be string, '.event.editor_interface' should be equal to one of the allowed values

@matmarex: Could this have something to do with the recent refactoring of the EditAttemptStep and VisualEditorFeatureUse instruments? [https://gerrit.wikimedia.org/r/q/topic:centralize-editattemptstep]

That sounds likely, thanks for the note. The events in your link are logged with null values for "editor_interface" and "integration", and the refactoring changed how the defaults for these fields are defined.

Event Timeline

Many of the problematic events are logged for features that only exist in ContentTranslation ("cxLink"), so this is probably the problem (or at least one of the problems). I'm not sure if previously we didn't log VisualEditorFeatureUse events in it at all, or if we logged them with some incorrect values for "editor_interface" and "integration". We need to figure out if/how they should be logged.

Event logging in in ContentTranslation was previously prevented by this check:

		if ( ve.init.target && (
			ve.init.target.constructor.static.platformType !== 'desktop'
		) ) {
			// We want to log activity events when we're also logging to
			// EditAttemptStep. The EAS events are only fired from DesktopArticleTarget
			// in this repo. As such, we suppress this unless the current target is at
			// least inheriting that. (Other tools may fire their own instances of
			// those events, but probably need to reimplement this anyway for
			// session-identification reasons.)
			return;
		}

(removed here: https://gerrit.wikimedia.org/r/c/mediawiki/extensions/VisualEditor/+/900759/6/modules/ve-mw/init/ve.init.mw.trackSubscriber.js#b284)

Change 906653 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/WikimediaEvents@master] Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged

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

Change 906653 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged

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

Change 907743 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/WikimediaEvents@wmf/1.41.0-wmf.4] Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged

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

Change 907743 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@wmf/1.41.0-wmf.4] Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged

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

Mentioned in SAL (#wikimedia-operations) [2023-04-13T20:48:40Z] <urbanecm@deploy2002> Started scap: Backport for [[gerrit:907743|Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged (T334157)]], [[gerrit:905751|Stop using redundant $wmg variable for MobileFrontend extension (T119117)]]

Mentioned in SAL (#wikimedia-operations) [2023-04-13T20:50:01Z] <urbanecm@deploy2002> urbanecm and matmarex: Backport for [[gerrit:907743|Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged (T334157)]], [[gerrit:905751|Stop using redundant $wmg variable for MobileFrontend extension (T119117)]] synced to the testservers: mwdebug2001.codfw.wmnet, mwdebug2002.codfw.wmnet, mwdebug1002.eqiad.wmnet, mwdebug1001.eqiad.wmnet

Mentioned in SAL (#wikimedia-operations) [2023-04-13T20:55:07Z] <urbanecm@deploy2002> Finished scap: Backport for [[gerrit:907743|Only log 'visualEditorFeatureUse' events if 'editAttemptStep' events are being logged (T334157)]], [[gerrit:905751|Stop using redundant $wmg variable for MobileFrontend extension (T119117)]] (duration: 06m 26s)