-
Notifications
You must be signed in to change notification settings - Fork 410
Description
The locals are not loading in the debugger (in this case, not always).
Environment
- Operating System: Win10
- JDK version:
- Visual Studio Code version: 1.41.1
- Java extension version: 0.55.1
- Java Debugger extension version: 0.24.0
Steps To Reproduce
sample project reproducing the error
demo of problem
- Debug the test
- Put a breakpoint on
when(restHighLevelClient.indexAsync(any(), any(), any())) - After the breakpoint is hit, enable Caught Exceptions
- F5
- Wait for the exception, inspect the debugger window
Current Result
Expected Result
Variables to load
Additional Informations
Exception from Java Server Log
!ENTRY java-debug 4 0 2020-02-26 10:06:40.711
!MESSAGE [error response][variables]: Failed to get variables. Reason: com.sun.jdi.InvalidStackFrameException
!STACK 0
com.microsoft.java.debug.core.DebugException: Failed to get variables. Reason: com.sun.jdi.InvalidStackFrameException
at com.microsoft.java.debug.core.adapter.AdapterUtils.createCompletionException(AdapterUtils.java:255)
at com.microsoft.java.debug.core.adapter.handler.VariablesRequestHandler.handle(VariablesRequestHandler.java:118)
at com.microsoft.java.debug.core.adapter.DebugAdapter.lambda$dispatchRequest$0(DebugAdapter.java:87)
at java.base/java.util.concurrent.CompletableFuture.uniComposeStage(CompletableFuture.java:1106)
at java.base/java.util.concurrent.CompletableFuture.thenCompose(CompletableFuture.java:2235)
at com.microsoft.java.debug.core.adapter.DebugAdapter.dispatchRequest(DebugAdapter.java:86)
at com.microsoft.java.debug.core.adapter.ProtocolServer.dispatchRequest(ProtocolServer.java:118)
at com.microsoft.java.debug.core.protocol.AbstractProtocolServer.lambda$new$0(AbstractProtocolServer.java:78)
at io.reactivex.internal.observers.LambdaObserver.onNext(LambdaObserver.java:60)
at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.drainNormal(ObservableObserveOn.java:200)
at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.run(ObservableObserveOn.java:252)
at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:61)
at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:52)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: com.sun.jdi.InvalidStackFrameException
at org.eclipse.jdi.internal.MirrorImpl.defaultReplyErrorHandler(MirrorImpl.java:294)
at org.eclipse.jdi.internal.StackFrameImpl.getValues(StackFrameImpl.java:142)
at org.eclipse.jdi.internal.StackFrameImpl.getValue(StackFrameImpl.java:78)
at com.microsoft.java.debug.core.adapter.variables.VariableUtils.listLocalVariables(VariableUtils.java:153)
at com.microsoft.java.debug.core.adapter.handler.VariablesRequestHandler.handle(VariablesRequestHandler.java:109)
... 16 more

