Page MenuHomePhabricator

TypeError: t.view.scrollIntoView is not a function
Closed, ResolvedPublicBUG REPORT

Description

Seen on https://en.wikipedia.beta.wmflabs.org/w/index.php?title=Polar_bear&action=edit&cm6enable=1
https://logstash.wikimedia.org/app/discover#/doc/logstash-*/logstash-default-1-7.0.0-1-2023.10.10?id=C99PG4sBt3kDdlqnp8a1

at scrollToCaretPosition https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:197:48
at $.fn.textSelection https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=startup&only=scripts&raw=1&skin=vector-2022 line 10 > eval:6:709
at realtimepreview/RealtimePreview.js/RealtimePreview.prototype.toggle https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=startup&only=scripts&raw=1&skin=vector-2022 line 10 > eval:6:468
at OO.EventEmitter.prototype.emit https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=startup&only=scripts&raw=1&skin=vector-2022 line 10 > eval:8:344
at OO.ui.ToggleWidget.prototype.setValue https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:479:109
at OO.ui.ToggleButtonWidget.prototype.setValue https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:649:523
at OO.ui.ToggleButtonWidget.prototype.onAction https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:649:260
at OO.EventEmitter.prototype.emit https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=startup&only=scripts&raw=1&skin=vector-2022 line 10 > eval:8:344
at OO.ui.mixin.ButtonElement.prototype.onClick https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:452:758
at dispatch https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:348:932
at add/elemData.handle https://en.wikipedia.beta.wmflabs.org/w/load.php?lang=en&modules=ext.CodeMirror.v6.WikiEditor%7Cjquery%2Coojs-ui-core%2Coojs-ui-widgets%2Cvue%7Cjquery.ui&skin=vector-2022&version=1w73y:345:565

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
MusikAnimal subscribed.

Definitely CodeMirror 6 testing, as per cm6enable=1 in the URL. https://gerrit.wikimedia.org/r/c/mediawiki/extensions/CodeMirror/+/964998 should fix this, I think.

I guess a general disclaimer to @Jdlrobson though, there may be a fair amount of new errors you see on Beta in the coming weeks. If you see cm6enable=1 in the URL or CodeMirror in the stack trace, rest assured it's been seen and will be addressed. None of this will go to prod for quite some time.

However as I'm typing this I'm realizing maybe we should get rid of cm6enable=1 for the time being, and chose a single wiki on Beta as our testing ground with $wgCodeMirrorV6 set? While I like the idea of being able to test CodeMirror 6 anywhere, this does mean we can get these errors in prod which is maybe not okay (?)

The whole CodeMirror 6 migration is a ways from completion. Maybe cm6enable should be saved for closer to launch date when we actually do want to preemptively test on production.

Hey @MusikAnimal sounds good. I've filtered them out from the shared dashboard.

MusikAnimal claimed this task.

Okay cool. I'll resolve this as this particular bug has been fixed. I'll work with Sammy on changing Beta deployment and/or removing the cm6enable functionality, as needed.