Skip to content

terminal process exited with code:1 #1404

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
ajpaul18 opened this issue Jul 7, 2018 · 13 comments · Fixed by #1411
Closed

terminal process exited with code:1 #1404

ajpaul18 opened this issue Jul 7, 2018 · 13 comments · Fixed by #1411

Comments

@ajpaul18
Copy link

ajpaul18 commented Jul 7, 2018

Issue Type: Bug

During VS Code startup,Powershell Terminal exits with the following errors

  1. Terminal process exited with code :1
  2. The language service could not be started

Extension version: 1.7.0
VS Code version: Code - Insiders 1.23.0-insider (a656d397e424173c86f32703e0c0293bd8084da0, 2018-05-03T00:07:45.778Z)
OS version: Windows_NT ia32 10.0.17134

System Info
Item Value
CPUs Intel(R) Xeon(R) CPU W3565 @ 3.20GHz (8 x 3192)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: disabled_software
video_decode: enabled
video_encode: enabled
vpx_decode: enabled
webgl: enabled
webgl2: enabled
Memory (System) 11.99GB (5.32GB free)
Process Argv C:\Program Files (x86)\Microsoft VS Code Insiders\Code - Insiders.exe
Screen Reader no
VM 40%
@TylerLeonhardt
Copy link
Member

Thanks for this. I noticed your VSCode version is quite behind... Can you upgrade to the latest and try again?

@rjmholt
Copy link
Contributor

rjmholt commented Jul 7, 2018

Hi @ajpaul18, thanks for opening an issue. This looks like a startup crash in EditorServices, but we'll need to collect more information to work out what the root problem is.

Out of curiosity, does red text flash in the console before the crash occurs? If so, the best way to work out what it says is a screen recorder (like a screen to GIF recorder). (Making that diagnosis easier is on the list of things to improve!)

@rjmholt
Copy link
Contributor

rjmholt commented Jul 7, 2018

Oh, yeah, like @tylerl0706 says, also worth upgrading VSCode!

@ajpaul18
Copy link
Author

ajpaul18 commented Jul 9, 2018

image
image

I have updated to july 2018. Still the console crashes.
@rjmholt There is no red text flashing in the console before the crash, the console crashes immediately in startup.

@rkeithhill
Copy link
Contributor

rkeithhill commented Jul 9, 2018

I believe the issue is that your home dir is named Night's Watch. That single quote inside a single quoted path to the script is causing a parse error. BTW this impacts not only the script path but also the BundledModulesPath, LogPath and SessionDetailsPath.

We would either need to double-up single quotes or switch to using double quotes. Using double quotes is problematic because of unintentional interpolation. Perhaps we preprocess these four paths to "escape" (double) the single quotes.

@rjmholt
Copy link
Contributor

rjmholt commented Jul 9, 2018

@ajpaul18 No need for red text, that message is the important bit.

We should probably do some string escaping for the start script call

@ajpaul18
Copy link
Author

ajpaul18 commented Jul 9, 2018

Yes,the user name is the problem. i tried installing in another user account , it worked fine.

@rkeithhill
Copy link
Contributor

We should be able to fix this though.

@ajpaul18
Copy link
Author

ajpaul18 commented Jul 9, 2018

Update the regex in the start script?

@rkeithhill
Copy link
Contributor

rkeithhill commented Jul 9, 2018

It fails before it even starts the start script. This needs to be fixed in the extension where we launch powershell.exe with those args. I'm working on a fix right now but I don't have a good test case for this. Perhaps you could test it for me? Nevermind, figured out an easy way to test it (without renaming my home dir or creating a new user).

@rkeithhill
Copy link
Contributor

rkeithhill commented Jul 9, 2018

OK, have a fix. If you would like to try it out. Download this zip and extract the two files into your ~\.vscode\extensions\ms-vscode.powershell-1.7.0\out\src\features dir. I would back up the two existing files first (process.js and session.js), so you can revert if needed.

updated-js-files.zip

I you try this, please let us know if it fixes the issue for you.

@ajpaul18
Copy link
Author

ajpaul18 commented Jul 9, 2018

@rkeithhill & @tylerl0706 .. Thanks guys, the fix works.
That issue was so annoying. Glad you guys could help me. Cheers mates

@ajpaul18 ajpaul18 closed this as completed Jul 9, 2018
@rkeithhill
Copy link
Contributor

Let's let the PR merge automatically close this issue. :-)

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

Successfully merging a pull request may close this issue.

4 participants