Page MenuHomePhabricator

TypeError: codeEditorMonitorFragment is not a function
Closed, ResolvedPublic

Description

While editing user JavaScript pages on enwiki today, I twice got the error "Uncaught TypeError: $(...).data(...).fn.codeEditorMonitorFragment is not a function: index.php:114", on two different pages. On both of these times CodeEditor failed to load, and when I checked the second time it happened my user scripts had failed to load too. However, it was an intermittent problem - most of the time both CodeEditor and my user scripts loaded just fine.

I assume that on both times that I saw the errors some central piece of JavaScript had failed to load, although I haven't investigated what it might be. It might be that CodeEditor isn't able to run under those conditions anyway, but in that case it might be nice to have a better error message.

Event Timeline

MrStradivarius raised the priority of this task from to Needs Triage.
MrStradivarius updated the task description. (Show Details)
MrStradivarius added a project: CodeEditor.
MrStradivarius subscribed.

I just got the codeEditorMonitorFragment error again while trying to edit Module:Set/testcases (in Chrome, on a different computer), and I noticed that I also had the following error further up in the JavaScript console:

Uncaught TypeError: Array.map is not a function: index.php?title=User:Anomie/previewtemplatelastmod.js&action=raw&ctype=text/javascript:101

Something must have gone pretty badly wrong on this page load for Array.map not to work.

TheDJ triaged this task as High priority.Jun 26 2015, 9:33 AM
TheDJ added a project: JavaScript.
TheDJ set Security to None.

Change 234352 had a related patch set uploaded (by TheDJ):
Make sure that wikieditor context is ready

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

Change 234352 merged by jenkins-bot:
Make sure that wikieditor context is ready

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

matmarex removed a project: Patch-For-Review.
matmarex removed a subscriber: gerritbot.
matmarex subscribed.