Page MenuHomePhabricator

Regression: mw.hook( 'codeEditor.configure' ) is not fired in graph sandbox
Closed, ResolvedPublic

Description

Special:GraphSandbox (or debug version) stopped working. Quick debugging showed that codeEditor.configure hook is not being called when text changes in the code editor.

See graph.sandbox.js#L21.

Repo
  • Open graph sandbox, type one letter in the text field.
  • Expected: invalidtext:[object Object] error in the upper right panel
  • Actual: nothing

Event Timeline

Yurik created this task.Aug 16 2016, 10:03 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 16 2016, 10:03 PM
Yurik updated the task description. (Show Details)Aug 16 2016, 10:25 PM

Ugh, this was caused by rECED7a95deea76ec: Supply model/format directly to hook.

Graph is pretending that it's *special page* has a JSON content type, but that CodeEditor change no longer outputs wgCodeEditorCurrentLanguage on every page, just the edit view (a good thing IMO). I'll submit a patch.

Change 305140 had a related patch set uploaded (by Legoktm):
Fix CodeEditor usage in GraphSandbox

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

Change 305140 merged by jenkins-bot:
Fix CodeEditor usage in GraphSandbox

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

Change 305145 had a related patch set uploaded (by Yurik):
Fix CodeEditor usage in GraphSandbox

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

Yurik closed this task as Resolved.Aug 16 2016, 11:00 PM
Yurik claimed this task.

Thanks @Legoktm , very well done!

Change 305145 merged by jenkins-bot:
Fix CodeEditor usage in GraphSandbox

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