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

Add support for terminals on Windows #3087

Merged
merged 12 commits into from
Dec 1, 2017

Conversation

blink1073
Copy link
Contributor

No description provided.

@rgbkrk
Copy link
Member

rgbkrk commented Nov 27, 2017

Sweet

if not default_shell and os.name == 'nt':
default_shell = 'cmd.exe'
shell = settings.get('shell_command',
[os.environ.get('SHELL', default_shell)]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tend to do defaults for environment variables like os.environ.get('SHELL') or default_shell, because setting an environment variable to the empty string is equivalent by convention to unsetting it.

@blink1073 blink1073 changed the title Add support for terminals on Windows [WIP] Add support for terminals on Windows Nov 27, 2017
@blink1073
Copy link
Contributor Author

I'm going to hold off on this pending support for Python 2.7 on Windows. cf andfoy/pywinpty#75

@takluyver
Copy link
Member

Up to you, but I'm happy for it to be a Python-3-only feature. Next year we might be looking at doing Notebook 6.0 and requiring Python 3, in any case.

@blink1073
Copy link
Contributor Author

Already mostly done: cf jupyter/terminado#50

@blink1073 blink1073 changed the title [WIP] Add support for terminals on Windows Add support for terminals on Windows Nov 28, 2017
@blink1073
Copy link
Contributor Author

Good to go

@blink1073
Copy link
Contributor Author

Updated to use powershell on Windows if sh is not available, which is what VS Code uses.

@gnestor
Copy link
Contributor

gnestor commented Dec 1, 2017

Thanks @blink1073!

@gnestor gnestor merged commit 7b8759f into jupyter:master Dec 1, 2017
@stonebig
Copy link

stonebig commented Dec 9, 2017

hi, I think I'm hitting this with Jupyterlab-0.30.5 / terminado-0.8.1 / Pywinpty-0.5.1... Could you do a release soon ?

@liuzhousi
Copy link

Sorry to bother.. I think I may encounter the same problem now, as I still could not open the terminal in the latest win10 64bit system. Besides, my environment situation lists below: Python3.6.4, jupyter notebook5.7.8, terminado0.8.2, and pywinpty0.5.5. The detailed problem is: Terminals not available (error was DLL load failed: %This is not a valid Win32 Application.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants