Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quokka (1.0.222) Plugin under Intellij IDEA gets null pointer exception #463

Closed
dimylik opened this issue Feb 26, 2020 · 1 comment
Closed
Assignees
Labels

Comments

@dimylik
Copy link

dimylik commented Feb 26, 2020

Issue description or question

Sample code

// paste the code you are running here
import slide_out from 'devextreme/ui/slide_out';

const existingParamList = [1,2,3];
const mnemonic=5;
const updatedParam = [...existingParamList, mnemonic];
console.log(updatedParam);
console.log(updatedParam.join(','));

function getSplit(b) {
    return b && b.toString() && [b].join(',').split(',') || [];
}

let a = undefined;

a = [1,2,3];
console.log('xxx', getSplit(a))

a = '1,2,3';
console.log('xxx', getSplit(a))

a = '';
console.log('xxx', getSplit(a))

a = [];
console.log('xxx', getSplit(a))

console.log('xxx', getSplit(undefined))
console.log('xxx', getSplit(null))

console.log('array is', [].toString() ? 'not empty' : 'empty');

console.log('empty array length is', [].join(',').length);

Sample repository link

If the issue can not be reproduced just using the quokka file above
(for example because it requires/imports some files from your project),
please create a small repository where the issue can be reproduced.

Quokka.js Console Output

// paste your quokka console output here
Following exceptions happened soon after this one, most probably they are induced.


2020-02-26T10:06:48.273
java.lang.NullPointerException
	at com.quokka.javascript.session.a.selectionChanged(Unknown Source)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.broadcastSelectionEvent(SelectionModelImpl.java:130)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.fireSelectionChanged(SelectionModelImpl.java:124)
	at com.intellij.openapi.editor.impl.CaretImpl.lambda$doSetSelection$6(CaretImpl.java:1196)
	at com.intellij.openapi.editor.impl.CaretModelImpl.doWithCaretMerging(CaretModelImpl.java:453)
	at com.intellij.openapi.editor.impl.CaretImpl.doSetSelection(CaretImpl.java:1113)
	at com.intellij.openapi.editor.impl.CaretImpl.setSelection(CaretImpl.java:1103)
	at com.intellij.openapi.editor.impl.CaretImpl.setSelection(CaretImpl.java:1095)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.setSelection(SelectionModelImpl.java:101)
	at com.intellij.openapi.editor.impl.EditorImpl.setSelectionAndBlockActions(EditorImpl.java:2664)
	at com.intellij.openapi.editor.impl.EditorImpl.processMouseDragged(EditorImpl.java:2572)
	at com.intellij.openapi.editor.impl.EditorImpl.lambda$runMouseDraggedCommand$14(EditorImpl.java:2422)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:220)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:178)
	at com.intellij.openapi.editor.impl.EditorImpl.runMouseDraggedCommand(EditorImpl.java:2422)
	at com.intellij.openapi.editor.impl.EditorImpl.access$11600(EditorImpl.java:123)
	at com.intellij.openapi.editor.impl.EditorImpl$MyMouseMotionListener.lambda$mouseDragged$0(EditorImpl.java:4174)
	at com.intellij.openapi.application.TransactionGuardImpl.performUserActivity(TransactionGuardImpl.java:195)
	at com.intellij.openapi.editor.impl.EditorImpl$MyMouseMotionListener.mouseDragged(EditorImpl.java:4174)
	at java.awt.Component.processMouseMotionEvent(Component.java:6598)
	at javax.swing.JComponent.processMouseMotionEvent(JComponent.java:3343)
	at java.awt.Component.processEvent(Component.java:6319)
	at java.awt.Container.processEvent(Container.java:2239)
	at java.awt.Component.dispatchEventImpl(Component.java:4899)
	at java.awt.Container.dispatchEventImpl(Container.java:2297)
	at java.awt.Component.dispatchEvent(Component.java:4721)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4552)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)
	at java.awt.Container.dispatchEventImpl(Container.java:2283)
	at java.awt.Window.dispatchEventImpl(Window.java:2746)
	at java.awt.Component.dispatchEvent(Component.java:4721)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:766)
	at java.awt.EventQueue.access$500(EventQueue.java:98)
	at java.awt.EventQueue$3.run(EventQueue.java:715)
	at java.awt.EventQueue$3.run(EventQueue.java:709)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)
	at java.awt.EventQueue$4.run(EventQueue.java:739)
	at java.awt.EventQueue$4.run(EventQueue.java:737)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:736)
	at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:741)
	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:686)
	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:385)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

2020-02-26T10:06:48.605
java.lang.NullPointerException
	at com.quokka.javascript.session.a.selectionChanged(Unknown Source)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.broadcastSelectionEvent(SelectionModelImpl.java:130)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.fireSelectionChanged(SelectionModelImpl.java:124)
	at com.intellij.openapi.editor.impl.CaretImpl.lambda$doSetSelection$6(CaretImpl.java:1196)
	at com.intellij.openapi.editor.impl.CaretModelImpl.doWithCaretMerging(CaretModelImpl.java:453)
	at com.intellij.openapi.editor.impl.CaretImpl.doSetSelection(CaretImpl.java:1113)
	at com.intellij.openapi.editor.impl.CaretImpl.setSelection(CaretImpl.java:1103)
	at com.intellij.openapi.editor.impl.CaretImpl.setSelection(CaretImpl.java:1095)
	at com.intellij.openapi.editor.impl.SelectionModelImpl.setSelection(SelectionModelImpl.java:101)
	at com.intellij.openapi.editor.impl.EditorImpl.setSelectionAndBlockActions(EditorImpl.java:2664)
	at com.intellij.openapi.editor.impl.EditorImpl.processMouseDragged(EditorImpl.java:2572)
	at com.intellij.openapi.editor.impl.EditorImpl.lambda$runMouseDraggedCommand$14(EditorImpl.java:2422)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:220)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:178)
	at com.intellij.openapi.editor.impl.EditorImpl.runMouseDraggedCommand(EditorImpl.java:2422)
	at com.intellij.openapi.editor.impl.EditorImpl.access$11600(EditorImpl.java:123)
	at com.intellij.openapi.editor.impl.EditorImpl$MyMouseMotionListener.lambda$mouseDragged$0(EditorImpl.java:4174)
	at com.intellij.openapi.application.TransactionGuardImpl.performUserActivity(TransactionGuardImpl.java:195)
	at com.intellij.openapi.editor.impl.EditorImpl$MyMouseMotionListener.mouseDragged(EditorImpl.java:4174)
	at java.awt.Component.processMouseMotionEvent(Component.java:6598)
	at javax.swing.JComponent.processMouseMotionEvent(JComponent.java:3343)
	at java.awt.Component.processEvent(Component.java:6319)
	at java.awt.Container.processEvent(Container.java:2239)
	at java.awt.Component.dispatchEventImpl(Component.java:4899)
	at java.awt.Container.dispatchEventImpl(Container.java:2297)
	at java.awt.Component.dispatchEvent(Component.java:4721)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4552)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)
	at java.awt.Container.dispatchEventImpl(Container.java:2283)
	at java.awt.Window.dispatchEventImpl(Window.java:2746)
	at java.awt.Component.dispatchEvent(Component.java:4721)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:766)
	at java.awt.EventQueue.access$500(EventQueue.java:98)
	at java.awt.EventQueue$3.run(EventQueue.java:715)
	at java.awt.EventQueue$3.run(EventQueue.java:709)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)
	at java.awt.EventQueue$4.run(EventQueue.java:739)
	at java.awt.EventQueue$4.run(EventQueue.java:737)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:736)
	at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:741)
	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:686)
	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:385)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

Code editor version

Intellij IDEA 2019.1

OS name and version

Windows

@NikGovorov NikGovorov added the bug label Feb 27, 2020
@NikGovorov NikGovorov self-assigned this Feb 27, 2020
@NikGovorov
Copy link
Member

NikGovorov commented Feb 27, 2020

Thanks for reporting the problem. Unfortunately we could not reproduce the issue but we have released a new version of Quokka for JetBrains IDEs that we expect will fix your problem (v1.0.223). Please let us know if you continue to experience the issue after the update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants