consulo / consulo-unity3d

Frameworks: Unity3D
Apache License 2.0
103 stars 10 forks source link

Unity3D Debugging - Evaluate Expression throws have null message Exception #87

Closed TomCoursow closed 7 years ago

TomCoursow commented 8 years ago

I executed a code debug evaluation in consulo because the tooltips are not working on code selection and the watch did show up some parameter error. During evaluation the editor showed up a exception popup.

The code was a property which was get and then called a getter on it with an integer parameter.

Exception details:

Exception have null message
consulo.dotnet.debugger.proxy.DotNetThrowValueException
    at consulo.dotnet.mono.debugger.proxy.MonoMethodProxy.invoke(MonoMethodProxy.java:138)
    at org.mustbe.consulo.csharp.ide.debugger.expressionEvaluator.PropertyEvaluator.invoke(PropertyEvaluator.java:56)
    at org.mustbe.consulo.csharp.ide.debugger.expressionEvaluator.PropertyEvaluator.invoke(PropertyEvaluator.java:34)
    at org.mustbe.consulo.csharp.ide.debugger.expressionEvaluator.FieldOrPropertyEvaluator.invokeFieldOrProperty(FieldOrPropertyEvaluator.java:151)
    at org.mustbe.consulo.csharp.ide.debugger.expressionEvaluator.FieldOrPropertyEvaluator.evaluate(FieldOrPropertyEvaluator.java:124)
    at org.mustbe.consulo.csharp.ide.debugger.CSharpEvaluateContext.evaluate(CSharpEvaluateContext.java:92)
    at org.mustbe.consulo.csharp.ide.debugger.CSharpDebuggerProvider.evaluate(CSharpDebuggerProvider.java:125)
    at consulo.dotnet.debugger.DotNetStackFrame$3.evaluate(DotNetStackFrame.java:243)
    at com.intellij.xdebugger.impl.ui.tree.nodes.WatchNodeImpl$XWatchValue.computePresentation(WatchNodeImpl.java:94)
    at com.intellij.xdebugger.impl.ui.tree.nodes.XValueNodeImpl.<init>(XValueNodeImpl.java:73)
    at com.intellij.xdebugger.impl.ui.tree.nodes.WatchNodeImpl.<init>(WatchNodeImpl.java:44)
    at com.intellij.xdebugger.impl.ui.tree.nodes.WatchesRootNode.addWatchExpression(WatchesRootNode.java:123)
    at com.intellij.xdebugger.impl.frame.XWatchesViewImpl.addWatchExpression(XWatchesViewImpl.java:308)
    at com.intellij.xdebugger.impl.frame.WatchInplaceEditor.doOKAction(WatchInplaceEditor.java:82)
    at com.intellij.xdebugger.impl.ui.tree.TreeInplaceEditor$7.actionPerformed(TreeInplaceEditor.java:212)
    at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1663)
    at javax.swing.JComponent.processKeyBinding(JComponent.java:2882)
    at com.intellij.ui.EditorTextField.processKeyBinding(EditorTextField.java:699)
    at javax.swing.JComponent.processKeyBindings(JComponent.java:2943)
    at javax.swing.JComponent.processKeyEvent(JComponent.java:2845)
    at java.awt.Component.processEvent(Component.java:6310)
    at java.awt.Container.processEvent(Container.java:2236)
    at java.awt.Component.dispatchEventImpl(Component.java:4889)
    at java.awt.Container.dispatchEventImpl(Container.java:2294)
    at java.awt.Component.dispatchEvent(Component.java:4711)
    at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1954)
    at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:806)
    at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:1074)
    at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:945)
    at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:771)
    at java.awt.Component.dispatchEventImpl(Component.java:4760)
    at java.awt.Container.dispatchEventImpl(Container.java:2294)
    at java.awt.Window.dispatchEventImpl(Window.java:2746)
    at java.awt.Component.dispatchEvent(Component.java:4711)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
    at java.awt.EventQueue.access$500(EventQueue.java:97)
    at java.awt.EventQueue$3.run(EventQueue.java:709)
    at java.awt.EventQueue$3.run(EventQueue.java:703)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
    at java.awt.EventQueue$4.run(EventQueue.java:731)
    at java.awt.EventQueue$4.run(EventQueue.java:729)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:892)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:702)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:406)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
    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)
VISTALL commented 8 years ago

Hi. Sorry for delay. Can you provide expression which you evaluated ?

TomCoursow commented 8 years ago

Sadly not because it's code from my company... But it would be somehow like this...

this.EntityManager.GetEntity(entityId).GetValue(xmlId); also tried it without this before that... same problem.

EntityManager would be a C# Property so no pure field declared like this: [Inject] public IEntityManager EntityManager { private get; set; } the rest are parameters from the function.

Maybe it also good to notice that the member belongs to a namespace?

And I encountered that watches are not working in general as long as I seem to execute a function. But only with this code I got a exception popup. The other cases only show a red error in the result of the watch

VISTALL commented 8 years ago

Can you try create simple example? I am working on 2.0 branch(and on my main work too) - and i don't have too much time for searching problem.

Will be grateful if you could. Thanks,

TomCoursow commented 8 years ago

Ok, will try to create an example project if I have time and share it to you if I can reproduce it with that

VISTALL commented 7 years ago

I think obsolete, due second version is out