Page MenuHomePhabricator

Regression: No longer able to insert characters using CharInsert gadget based on extension after 1.25wmf14 roll-out.
Closed, ResolvedPublic

Description

CONFIRMED - Same thing happens on www.mediawiki.org as it did on en.wikisource.org

Open any page to edit mode and try to insert any character from the CharInsert bar to the textarea.

The character selected is not inserted and it seems the "focus" goes to the top of the page instead. Here's what IE's F12 reports upon insertion attempt.

function anonymous(evt) {
mw.toolbar.insertTags('₡', '', ''); evt.preventDefault(); return false;
}

SCRIPT5007: Unable to get property 'insertTags' of undefined or null reference
File: Function code (722), Line: 2, Column: 1

SCRIPT5009: 'insertTags' is undefined
File: index.php, Line: 138, Column: 13

Event Timeline

GOIII raised the priority of this task from to Needs Triage.
GOIII triaged this task as Unbreak Now! priority.
GOIII updated the task description. (Show Details)
GOIII added a project: CharInsert.
GOIII set Security to None.
GOIII subscribed.

No fault apparent using Firefox 34.0 (& 35.0 - browser auto-updated during trial; unexpected two-for-one result) under GNU/Linux; both logged-out and in.

No loss of focus observed either.

Could the choice of browser/referrer-id be the sensitive issue here?

Londonjackbooks reported the issue but I don't know what browser she's running.

Are you sure you're all caught up cache-wise to today's 1.25wmf14 roll-out?

Fwiw... this page describes the message I get under CodeEditor @ test.wikipedia.org when checking the core CharInsert .js .

Probably caused by 1dd14dcec0dfb69a8e9763b380e2b151e0da9634.

The gadget needs to be made dependent on mediawiki.toolbar in the gadgets definition:

charinsert-core[ResourceLoader|hidden|rights=hidden|dependencies=mediawiki.action.edit,mediawiki.toolbar,jquery.textSelection,user]|charinsert-core.js|charinsert-core.css
In T86715#975167, @TTO wrote:

Probably caused by 1dd14dcec0dfb69a8e9763b380e2b151e0da9634.
( Optimise loading of mediawiki.toolbar module )
The gadget needs to be made dependent on mediawiki.toolbar in the gadgets definition:

charinsert-core[ResourceLoader|hidden|rights=hidden|dependencies=mediawiki.action.edit,mediawiki.toolbar,jquery.textSelection,user]|charinsert-core.js|charinsert-core.css

Bingo! Adding that dependency rectified the problem on en.wikisource.org. Thank You very much.

I don't have that level of access for any other of the affected projects however.

TTO claimed this task.

I'll ask a shell user to check which other projects are affected.

GOIII closed this task as Resolved.
GOIII claimed this task.
GOIII lowered the priority of this task from Unbreak Now! to Medium.

Reminder that all the Wikipedia's get the 1.25wmf14 roll-out tomorrow. The issue won't present itself until then

Change 184836 had a related patch set uploaded (by TTO):
Re-add mediawiki.toolbar as a dependency of mediawiki.action.edit

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

Patch-For-Review

Change 184836 merged by jenkins-bot:
Re-add mediawiki.toolbar as a dependency of mediawiki.action.edit

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