Page MenuHomePhabricator

Declare conditional dependency on WikimediaEvents, and don't try to use schema.Edit unless it's present
Closed, ResolvedPublic1 Estimated Story Points

Description

On opening VisualEditor on a local MediaWiki-Vagrant setup:

"Error: Unknown dependency: schema.Edit" Error: Unknown dependency: schema.Edit
Stack trace:
sortDependencies:156:1
resolve:158:14
mw.loader</<.using:169:189
handleTrackedEvent:1:310
mw.trackSubscribe/<:154:53
jQuery.Callbacks/fire:45:106
jQuery.Callbacks/self.fireWith:46:431
jQuery.Callbacks/self.fire:46:474
mw.track:153:818
:677:426
ve.trackSubscribe/<:1:409
jQuery.Callbacks/fire:45:106
jQuery.Callbacks/self.add:45:664
ve.trackSubscribe:1:285
ve.trackSubscribeAll:1:500
:676:95
:675:165
runScript:161:153
execute/</checkCssHandles:161:638
execute/</cssHandle/<:161:768
jQuery.Callbacks/fire:45:106
jQuery.Callbacks/self.fireWith:46:431
jQuery.Callbacks/self.fire:46:474
addEmbeddedCSS:156:531
addEmbeddedCSS/<:156:1
load.php:150

(long RL URLs trimmed)

and

"VisualEditor failed to load: Error: Module ext.visualEditor.mediawiki has failed dependencies"

Event Timeline

brion created this task.Feb 5 2015, 10:41 AM
brion raised the priority of this task from to Needs Triage.
brion updated the task description. (Show Details)
brion added a subscriber: brion.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptFeb 5 2015, 10:41 AM
brion updated the task description. (Show Details)Feb 5 2015, 10:43 AM
brion set Security to None.

You need to load WikimediaEvents if you've got EventLogging installed for VisualEditor to work.

brion added a comment.Feb 5 2015, 5:22 PM

Interesting, something else must be pulling it in as a dependency...

puppet/modules/role/manifests/mobilefrontend.pp: include ::role::eventlogging

Culprit found. :)

Is there any way we can have a cleaner failure mode here, such as detecting that this other extension that's also needed isn't present and disabling the eventlogging when it won't work?

Jdforrester-WMF renamed this task from VisualEditor on Vagrant gives "Error: Unknown dependency: schema.Edit" in JS console to Declare conditional dependency on WikimediaEvents, and don't try to use schema.Edit unless it's present.Feb 5 2015, 5:54 PM
Jdforrester-WMF triaged this task as Medium priority.

Change 192049 had a related patch set uploaded (by Alex Monk):
Don't try to route any events into schema.Edit if it's not actually installed

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

Patch-For-Review

Krenair claimed this task.Feb 21 2015, 2:45 AM

Change 192049 merged by jenkins-bot:
Don't try to route any events into schema.Edit if it's not actually installed

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

bd808 moved this task from Backlog to Done on the MediaWiki-Vagrant board.Feb 26 2015, 12:50 AM
Jdforrester-WMF edited a custom field.Mar 9 2015, 6:09 PM