Last modified: 2014-05-01 23:50:55 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T60286, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 58286 - VisualEditor: Inserting a formula into a block slug throws "Uncaught TypeError: Cannot call method 'getOuterRange' of null"
VisualEditor: Inserting a formula into a block slug throws "Uncaught TypeErro...
Status: VERIFIED FIXED
Product: VisualEditor
Classification: Unclassified
Editing Tools (Other open bugs)
unspecified
All All
: High normal
: VE-deploy-2014-04-24
Assigned To: Ed Sanders
:
: 62797 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-12-10 20:21 UTC by Rummana Yasmeen
Modified: 2014-05-01 23:50 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
screenshot of the error and empty Latex window (124.42 KB, image/png)
2013-12-10 20:21 UTC, Rummana Yasmeen
Details
emtpy <math> tags (101.75 KB, image/png)
2013-12-10 20:24 UTC, Rummana Yasmeen
Details

Description Rummana Yasmeen 2013-12-10 20:21:22 UTC
Created attachment 14049 [details]
screenshot of the error and empty Latex window

Steps to reproduce:

1.Add a bullet list
2.Add a template as a bulleted item
3.Save the page and reopen the editor
4.Go to the next line of the bulleted list (get rid of bullets by pressing return twice)

5.Click on More>Latex

Observed Result:

The latex window is opening up at the right end, where the template is placed.

6.Then if you change the focus by clicking somewhere on the page outside the latex window

Observed Result:

A blank Latex windows is opening up and a uncaught type error appears Uncaught TypeError: Cannot call method 'getOuterRange' of null 

If you save the page and go to edit source , you will see empty <math> tag is getting placed
Comment 1 Rummana Yasmeen 2013-12-10 20:24:30 UTC
Created attachment 14050 [details]
emtpy <math> tags
Comment 2 Rummana Yasmeen 2013-12-10 23:52:11 UTC
Modification in steps to reproduce:

4.There is an empty bullet place cursor there and then go to More>Latex

It can also be reproduced by adding image in step 2.
Comment 3 Roan Kattouw 2013-12-16 21:33:57 UTC
This happens because ve.ui.MWMathInspector.prototype.setup assumes that after calling insertContent() to insert a math node, the selection will cover the math node exactly. But in a block slug, that's not true, because fixupInsertion will have amended the insertion to wrap the math node in a paragraph. Then when the selection does not precisely cover a FocusableNode, focusedNode will be null.
Comment 4 James Forrester 2014-04-17 03:08:23 UTC
*** Bug 62797 has been marked as a duplicate of this bug. ***
Comment 5 James Forrester 2014-04-17 03:27:14 UTC
This code as of Gerrit change #126900 is moving back into VE's repo where it needs to be fixed.
Comment 6 Gerrit Notification Bot 2014-04-18 00:25:51 UTC
Change 126900 had a related patch set uploaded by Esanders:
Create MWLiveExtensionInspector base class

https://gerrit.wikimedia.org/r/126900
Comment 7 Gerrit Notification Bot 2014-04-18 18:23:53 UTC
Change 126900 merged by jenkins-bot:
Create MWLiveExtensionInspector base class

https://gerrit.wikimedia.org/r/126900
Comment 8 Rummana Yasmeen 2014-04-18 21:12:50 UTC
Verified the fix on Betalabs
Comment 9 Gerrit Notification Bot 2014-04-25 00:04:15 UTC
Change 129622 had a related patch set uploaded by Jforrester:
Create MWLiveExtensionInspector base class

https://gerrit.wikimedia.org/r/129622
Comment 10 Gerrit Notification Bot 2014-04-25 00:06:11 UTC
Change 129622 merged by jenkins-bot:
Create MWLiveExtensionInspector base class

https://gerrit.wikimedia.org/r/129622
Comment 11 Rummana Yasmeen 2014-04-30 22:59:27 UTC
Verified the fix in test2
Comment 12 Rummana Yasmeen 2014-05-01 23:50:55 UTC
Verified the fix in production

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links