We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7dac0a2 commit 5a4b968Copy full SHA for 5a4b968
notebook/notebookapp.py
@@ -1206,7 +1206,7 @@ def init_terminals(self):
1206
log("Terminals not available (error was %s)", e)
1207
1208
def init_signal(self):
1209
- if not sys.platform.startswith('win') and sys.stdin.isatty():
+ if not sys.platform.startswith('win') and sys.stdin and sys.stdin.isatty():
1210
signal.signal(signal.SIGINT, self._handle_sigint)
1211
signal.signal(signal.SIGTERM, self._signal_stop)
1212
if hasattr(signal, 'SIGUSR1'):
0 commit comments