-
Notifications
You must be signed in to change notification settings - Fork 175
Closed
Description
VS Code About Info:
Version: 1.48.0
Commit: db40434f562994116e5b21c24015a2e40b2504e6
Date: 2020-08-13T08:03:27.059Z
Electron: 7.3.2
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 19.6.0
Python Extension ID: ms-python.python 2020.08.101144
Program to demonstrate issue:
# vscodeerr.py
# Program to demonstrate tcssetattr hang.
# 20200816:KDT - Original.
import sys
import termios
import atexit
from select import poll, POLLIN
old_term = None
fd = None
def setTerm() :
global old_term, fd
fd = sys.stdin.fileno()
new_term = termios.tcgetattr(fd)
old_term = termios.tcgetattr(fd)
# New terminal setting unbuffered, no echo
new_term[3] = (new_term[3] & ~termios.ICANON & ~termios.ECHO)
termios.tcsetattr(fd, termios.TCSANOW, new_term)
# Support normal-terminal reset at exit
atexit.register(setNormal)
p = poll()
p.register(sys.stdin, POLLIN)
def setNormal() :
termios.tcsetattr(fd, termios.TCSAFLUSH, old_term)
# main program
def main() :
setTerm()
print('All okay')
# Start, call main()
main()
Notes:
- VS Code running with Python extension installed, Python 3.8.3 installed and selected as interpreter.
- Code above as only python file.
- launch.js set to current python flle.
- RUN program result:
python3 /Users/kirkthompson/Projects/PythonProjects/VSCodeErr/vscodeerr.py
All okay - DEBUG program result:
Hangs at termios.tcsetattr(fd, termios.TCSANOW, new_term) line.
Pressing Debug Stop button displays VS Code notification "timeout after 1000 ms"
I don't know exactly when VS Code and the extension were updated, but prior to this update, everything worked as expected.
Metadata
Metadata
Assignees
Labels
No labels