Skip to content

error Debug adapter process has terminated unexpectedly #46

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

Closed
keithgb opened this issue Dec 8, 2015 · 13 comments
Closed

error Debug adapter process has terminated unexpectedly #46

keithgb opened this issue Dec 8, 2015 · 13 comments

Comments

@keithgb
Copy link

keithgb commented Dec 8, 2015

On Windows 7 I cannot seem to get the debugger to work.

@daviwil
Copy link
Contributor

daviwil commented Dec 8, 2015

Hi Keith, can you open the DebugAdapter.log file in the following location and copy/paste the error at the very end of the file?

c:\Users\<yourusername>\.vscode\extensions\ms-vscode.PowerShell\bin

Thanks!

@keithgb
Copy link
Author

keithgb commented Dec 8, 2015

​Sure thank you!

​ System.MissingMethodException: Method not found: 'Void
System.Management.Automation.Debugger.SetDebugMode(System.Management.Automation.DebugModes)'.
at
Microsoft.PowerShell.EditorServices.PowerShellContext.Initialize(Runspace
initialRunspace)
at Microsoft.PowerShell.EditorServices.PowerShellContext..ctor()
at
Microsoft.PowerShell.EditorServices.EditorSession.StartSession(IConsoleHost
consoleHost)
at
Microsoft.PowerShell.EditorServices.Host.MessageLoop.d__4.MoveNext()
--- End of stack trace from previous location where exception was
thrown ---
at
System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
Microsoft.PowerShell.EditorServices.Host.MessageLoop.d__1.MoveNext()
--- End of stack trace from previous location where exception was
thrown ---
at
System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at Nito.AsyncEx.AsyncContext.<>c__DisplayClass3.b__1(Task t)
at System.Threading.Tasks.ContinuationTaskFromTask.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was
thrown ---
at
System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at Nito.AsyncEx.AsyncContext.Run(Func`1 action)
at Microsoft.PowerShell.EditorServices.Host.MessageLoop.Start()
at Microsoft.PowerShell.EditorServices.Host.Program.Main(String[]
args)

Keith G. Broussard
[email protected]

On Tue, Dec 8, 2015 at 12:21 PM, David Wilson [email protected]
wrote:

Hi Keith, can you open the DebugAdapter.log file in the following location
and copy/paste the error at the very end of the file?

c:\Users.vscode\extensions\ms-vscode.PowerShell\bin

Thanks!


Reply to this email directly or view it on GitHub
#46 (comment)
.

@daviwil
Copy link
Contributor

daviwil commented Dec 8, 2015

What version of PowerShell are you using? It looks like you aren't using PowerShell v5. Currently only PowerShell v5 is supported though some things may work with earlier versions of PowerShell. If you aren't using v5 then I'm pretty impressed that you've only just hit an issue while trying to debug :)

@keithgb
Copy link
Author

keithgb commented Dec 8, 2015

​you are correct I am on 3.0.

[image: Inline image 2]

I will attempt to install 5 to see if that resolves.

Windows Management Framework 5.0 Production Preview
http://www.microsoft.com/en-us/download/details.aspx?id=48729

Keith G. Broussard
[email protected]

On Tue, Dec 8, 2015 at 12:51 PM, David Wilson [email protected]
wrote:

What version of PowerShell are you using? It looks like you aren't using
PowerShell v5. Currently only PowerShell v5 is supported though some things
may work with earlier versions of PowerShell. If you aren't using v5 then
I'm pretty impressed that you've only just hit an issue while trying to
debug :)


Reply to this email directly or view it on GitHub
#46 (comment)
.

@daviwil
Copy link
Contributor

daviwil commented Dec 8, 2015

Yep, that's the one!

@keithgb
Copy link
Author

keithgb commented Dec 8, 2015

Thanks for the quick response!!

Keith G. Broussard
[email protected]

On Tue, Dec 8, 2015 at 12:58 PM, David Wilson [email protected]
wrote:

Yep, that's the one!


Reply to this email directly or view it on GitHub
#46 (comment)
.

@daviwil
Copy link
Contributor

daviwil commented Dec 17, 2015

I'm going to track this issue over at the PowerShellEditorServices repo with this issue:

PowerShell/PowerShellEditorServices#73

Thanks again for the report!

@daviwil daviwil closed this as completed Dec 17, 2015
@ConnectedReasoning
Copy link

I'm getting this error on a Mac. Where should I look for the log?

@daviwil
Copy link
Contributor

daviwil commented Jun 28, 2016

Hi @ConnectedReasoning, the debugging feature doesn't work on OSX because PowerShell is not supported on that platform. All language and debugging features (aside from syntax highlighting and snippets) need the PowerShell runtime to operate.

@FaffeF
Copy link

FaffeF commented Aug 24, 2016

Still getting this error with PowerShell v6.0.0-alpha.9 installed on OSX El Capitan.

The DebugAdapterClient.log is empty 😿

@daviwil
Copy link
Contributor

daviwil commented Aug 24, 2016

Hey @FaffeF, you may need to install OpenSSL on your Mac for the extension to work correctly. Check out our installation instructions here:

https://github.com/PowerShell/PowerShell/blob/master/docs/learning-powershell/using-vscode.md

Check out the 'NOTE' in the OS X installation instructions for VS Code.

@FaffeF
Copy link

FaffeF commented Aug 25, 2016

OpenSSL was already installed. Updated the extension to 0.7.1 this morning, and suddenly debugging worked!

  • Then it worked again!
  • Then it didn't work (same error, showing me launch.json)
  • Then it worked a lot across different files.
  • Then it failed a lot.
  • After a restart debugging works again...

Log files look like below, with the error the only difference between successful and failed attempts.

Connecting to port: 13596
Connected to socket!

Socket connect ERROR: Error: read ECONNRESET
Socket closed, shutting down.

@daviwil
Copy link
Contributor

daviwil commented Aug 25, 2016

So sometimes it works and sometimes it doesn't work in the same session... That's strange, but it gives me some clues. Let's continue this discussion over on issue #243 because others are seeing similar issues there.

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

No branches or pull requests

4 participants