Shift-enter causes comically slow code-send to terminal
See original GitHub issueEnvironment data
- VS Code version: 1.48.0
- Extension version (available under the Extensions sidebar): 2020.8.101144
- OS and version: Windows 10
- Python version (& distribution if applicable, e.g. Anaconda): Python 3.7.6 64-bit (‘base’: conda)
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): N/A
- Relevant/affected Python packages and their versions: N/A
- Relevant/affected Python-related VS Code extensions and their versions: N/A
- Value of the
python.languageServer
setting: Pylance
[NOTE: If you suspect that your issue is related to the Microsoft Python Language Server (python.languageServer: 'Microsoft'
), please download our new language server Pylance from the VS Code marketplace to see if that fixes your issue]
Expected behaviour
When I press shift-enter, code is sent to the terminal lickety split.
Actual behaviour
We’re partying like it’s 1989, with 1200 baud modems:
Steps to reproduce:
- Write a long line of code.
- With the cursor in the long line of code you just wrote, press shift-enter.
- Have a sad, like sad cat, while waiting on the code to get to the terminal window.
Logs
Output for Python
in the Output
panel (View
→Output
, change the drop-down the upper-right of the Output
panel to Python
)
User belongs to experiment group 'ShowPlayIcon - start'
User belongs to experiment group 'ShowExtensionSurveyPrompt - enabled'
User belongs to experiment group 'DebugAdapterFactory - experiment'
User belongs to experiment group 'PtvsdWheels37 - experiment'
User belongs to experiment group 'UseTerminalToGetActivatedEnvVars - control'
User belongs to experiment group 'LocalZMQKernel - experiment'
User belongs to experiment group 'CollectLSRequestTiming - experiment'
User belongs to experiment group 'CollectNodeLSRequestTiming - experiment'
User belongs to experiment group 'EnableIPyWidgets - experiment'
User belongs to experiment group 'RunByLine - experiment'
User belongs to experiment group 'CustomEditorSupport - control'
User belongs to experiment group 'pythonaacf'
> conda --version
> pyenv root
> python3.7 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> python3.6 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> python3 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> python2 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> python c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> py -3.7 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> py -3.6 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> py -3 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
> py -2 c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)"
Starting Pylance language server.
Error 2020-08-18 18:27:46: Detection of Python Interpreter for Command py and args -3.6 failed as file Python 3.6 not found!
-3.8-32
-3.7-64 does not exist
Error 2020-08-18 18:27:46: Detection of Python Interpreter for Command py and args -2 failed as file Python 2 not found!
-3.8-32
-3.7-64 does not exist
> ~\Anaconda3\Scripts\conda.exe info --json
> ~\Anaconda3\Scripts\conda.exe info --json
> ~\Anaconda3\Scripts\conda.exe info --json
> ~\Anaconda3\Scripts\conda.exe info --json
Python interpreter path: ~\Anaconda3\python.exe
> ~\Anaconda3\Scripts\conda.exe env list
> ~\Anaconda3\Scripts\conda.exe info --json
> ~\Anaconda3\Scripts\conda.exe env list
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import notebook"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py -c "import jupyter"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py jupyter kernelspec --version
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "import urllib.request, json, smtplib, ssl"
> ~\Anaconda3\Scripts\conda.exe info --json
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py pip --version
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "import urllib.request, json, smtplib, ssl"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "from email.mime.text import MIMEText"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "from email.mime.multipart import MIMEMultipart"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py campsite_url = "https://www.recreation.gov/api/camps/availability/campground/234685/month?start_date=2020-08-01T00%3A00%3A00.000Z"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "url = urllib.request.urlopen(campsite_url)"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "campsites = json.loads(url.read().decode())"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py asdasda
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "url = urllib.request.urlopen(campsite_url)
campsites = json.loads(url.read().decode())
asdasda
asdas
"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py sender_email = "aren@arencambre.com"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py receiver_email = "novasource@gmail.com"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py password = "[nice try; I removed it]"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py email_subject = ""
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "message = MIMEMultipart("alternative")"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "message["From"] = sender_email"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "message["To"] = receiver_email"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "email_body_html = ''"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "email_body_plain = ''"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "not_available_strings = ['Reserved', 'Not Available']"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py "for key in campsites['campsites']:
if(campsites['campsites'][key]['availabilities']['2020-08-29T00:00:00Z'] not in not_available_strings and
campsites['campsites'][key]['availabilities']['2020-08-30T00:00:00Z'] not in not_available_strings):
email_body_html += '<p>Found a campsite! <a href="https://www.recreation.gov/camping/campsites/' + str(key) + '">check this</a></p>\n'
email_body_plain += 'site' + key + ' has availability '
email_subject = "Campsite check: CAMPSITE FOUND"
"
> ~\Anaconda3\python.exe c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\pyvsc-run-isolated.py c:\Users\[username]\.vscode\extensions\ms-python.python-2020.8.101144\pythonFiles\normalizeForInterpreter.py for key in campsites['campsites']:
if(campsites['campsites'][key]['availabilities']['2020-08-29T00:00:00Z'] not in not_available_strings and
campsites['campsites'][key]['availabilities']['2020-08-30T00:00:00Z'] not in not_available_strings):
email_body_html += '<p>Found a campsite! <a href="https://www.recreation.gov/camping/campsites/' + str(key) + '">check this</a></p>\n'
email_body_plain += 'site' + key + ' has availability '
email_subject = "Campsite check: CAMPSITE FOUND"
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (2 by maintainers)
Top Results From Across the Web
Screen + vim causes shift-enter to insert 'M' and a newline
Some terminal app (KTerminal, Gnome terminal, virtual console etc) ... do a “cat -v”, press Shift-Enter, then Enter, then Ctrl - D and...
Read more >Shift-Enter导致可笑的慢速码- 发送到终端:Shift-enter causes ...
Shift-enter causes comically slow code-send to terminal 环境数据VS Code version: 1.48.0 Extension version (available under the Extensions sidebar): 2020.8.
Read more >when memory allocator is Async, swapping lobbies on some servers ...
when memory allocator is Async, swapping lobbies on some servers makes the world not load right. ... Shift-enter causes comically slow code-send to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
resolved @arencambre
It is reported as microsoft/vscode#112346, then it got closed as being a duplicate of itself. 🤣