Start withot debugging twice dumps all my env variables on terminal and powershell panics with "System.ArgumentOutOfRangeException" a lot of times
See original GitHub issueEnvironment data
- VS Code version: 1.38.1
- Extension version (available under the Extensions sidebar): 2019.9.34911
- OS and version: Windows 10 Pro, 1903, 10.0.18362.356 (WinBuild.160101.0800)
- Python version: 3.7.4 x64
- Type of virtual environment used (N/A | venv | virtualenv | conda | …):
No conda or sth else, just “vanilla” python.
- Relevant/affected Python packages and their versions: python by itself
- Jedi or Language Server? (i.e. what is
"python.jediEnabled"
set to; more info #3977): jedi false, no language server config key.
Expected behaviour
Actual behaviour
Too long, better hidden
PowerShell 6.2.2
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS C:\Users\my_user_name\Desktop\normal_directory> & 'C:\Users\my_user_name\AppData\Local\Programs\Python\Python37\python.exe' 'c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\ptvsd_launcher.py' '--default' '--nodebug' '--client' '--host' 'localhost' '--port' '53011' 'c:\Users\my_user_name\Desktop\normal_directory\P4.py'
321
(1, 2, 3)
PS C:\Users\my_user_name\Desktop\normal_directory> cd 'c:\Users\my_user_name\Desktop\normal_directory'; ${env:--All my env variables are dumped here, but snip.--
Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 200 Keys:
e Ctrl+Alt+\ . v s c o d e Ctrl+Alt+\ e x t e n s i o n s Ctrl+Alt+\ m s - p y t h o n . p y t h o n - 2 0 1 9 . 9 . 3 4 9 1 1 Ctrl+Alt+\ p y t h o n F i l e s Ctrl+Alt+\ p t v s d _ l a u n c h e r . p y ' Space ' - - d e f a u l t ' Space ' - - n o d e b u g ' Space
' - - c l i e n t ' Space ' - - h o s t ' Space ' l o c a l h o s t ' Space ' - - p o r t ' Space ' 5 3 0 1 5 ' Space ' c : Ctrl+Alt+\
U s e r s Ctrl+Alt+\ J o s e Ctrl+Alt+\ D e s k t o p Ctrl+Alt+\ W I E L A N D T _ J O S E Ctrl+Alt+\ P 4 . p y ' Space Enter
Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -1.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ReallyRender(RenderData renderData, String defaultColor)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Insert(Char c)
at Microsoft.PowerShell.PSConsoleReadLine.SelfInsert(Nullable`1 key, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)
-----------------------------------------------------------------------
PS C:\Users\my_user_name\Desktop\normal_directory> cd 'c:\Users\my_user_name\Desktop\normal_directory'; ${env:--All my env variables are dumped here, but snip.--'; ${env:PYTHONIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFERED}='1'; & 'C:\Users\my_user_name\AppData\Local\Programs\Python\Python37\python.exe' 'c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\ptvsd_launcher.py' '--default' '--nodebug' '--client' '--host' 'localhost' '--port' '53015' 'c:\Users\my_user_name\Desktop\WIELANDT_JOS
Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 200 Keys:
e Ctrl+Alt+\ . v s c o d e Ctrl+Alt+\ e x t e n s i o n s Ctrl+Alt+\ m s - p y t h o n . p y t h o n - 2 0 1 9 . 9 . 3 4 9 1 1 Ctrl+Alt+\ p y t h o n F i l e s Ctrl+Alt+\ p t v s d _ l a u n c h e r . p y ' Space ' - - d e f a u l t ' Space ' - - n o d e b u g ' Space
' - - c l i e n t ' Space ' - - h o s t ' Space ' l o c a l h o s t ' Space ' - - p o r t ' Space ' 5 3 0 1 5 ' Space ' c : Ctrl+Alt+\
U s e r s Ctrl+Alt+\ J o s e Ctrl+Alt+\ D e s k t o p Ctrl+Alt+\ W I E L A N D T _ J O S E Ctrl+Alt+\ P 4 . p y ' Space Enter
Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -5.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ReallyRender(RenderData renderData, String defaultColor)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Insert(Char c)
at Microsoft.PowerShell.PSConsoleReadLine.SelfInsert(Nullable`1 key, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)
-----------------------------------------------------------------------
PS C:\Users\my_user_name\Desktop\normal_directory> cd 'c:\Users\my_user_name\Desktop\normal_directory'; ${env:--All my env variables are dumped here, but snip.--; ${env:PYTHONIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFERED}='1'; & 'C:\Users\my_user_name\AppData\Local\Programs\Python\Python37\python.exe' 'c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\ptvsd_launcher.py' '--default' '--nodebug' '--client' '--host' 'localhost' '--port' '53015' 'c:\Users\my_user_name\Desktop\normal_directory
Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 200 Keys:
e Ctrl+Alt+\ . v s c o d e Ctrl+Alt+\ e x t e n s i o n s Ctrl+Alt+\ m s - p y t h o n . p y t h o n - 2 0 1 9 . 9 . 3 4 9 1 1 Ctrl+Alt+\ p y t h o n F i l e s Ctrl+Alt+\ p t v s d _ l a u n c h e r . p y ' Space ' - - d e f a u l t ' Space ' - - n o d e b u g ' Space
' - - c l i e n t ' Space ' - - h o s t ' Space ' l o c a l h o s t ' Space ' - - p o r t ' Space ' 5 3 0 1 5 ' Space ' c : Ctrl+Alt+\
U s e r s Ctrl+Alt+\ J o s e Ctrl+Alt+\ D e s k t o p Ctrl+Alt+\ W I E L A N D T _ J O S E Ctrl+Alt+\ P 4 . p y ' Space Enter
Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -5.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ReallyRender(RenderData renderData, String defaultColor)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Insert(Char c)
at Microsoft.PowerShell.PSConsoleReadLine.SelfInsert(Nullable`1 key, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)
-----------------------------------------------------------------------
PS C:\Users\my_user_name\Desktop\normal_directory> cd 'c:\Users\my_user_name\Desktop\normal_directory'; ${env:--All my env variables are dumped here, but snip.--; ${env:PYTHONIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFERED}='1'; & 'C:\Users\my_user_name\AppData\Local\Programs\Python\Python37\python.exe' 'c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\ptvsd_launcher.py' '--default' '--nodebug' '--client' '--host' 'localhost' '--port' '53015' 'c:\Users\my_user_name\Desktop\normal_directory\
Oops, something went wrong. Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 200 Keys:
e Ctrl+Alt+\ . v s c o d e Ctrl+Alt+\ e x t e n s i o n s Ctrl+Alt+\ m s - p y t h o n . p y t h o n - 2 0 1 9 . 9 . 3 4 9 1 1 Ctrl+Alt+\ p y t h o n F i l e s Ctrl+Alt+\ p t v s d _ l a u n c h e r . p y ' Space ' - - d e f a u l t ' Space ' - - n o d e b u g ' Space
' - - c l i e n t ' Space ' - - h o s t ' Space ' l o c a l h o s t ' Space ' - - p o r t ' Space ' 5 3 0 1 5 ' Space ' c : Ctrl+Alt+\
U s e r s Ctrl+Alt+\ J o s e Ctrl+Alt+\ D e s k t o p Ctrl+Alt+\ W I E L A N D T _ J O S E Ctrl+Alt+\ P 4 . p y ' Space Enter
Exception:
System.ArgumentOutOfRangeException: The value must be greater than or equal to zero and less than the console's buffer size in that dimension.
Parameter name: top
Actual value was -5.
at System.Console.SetCursorPosition(Int32 left, Int32 top)
at Microsoft.PowerShell.PSConsoleReadLine.ReallyRender(RenderData renderData, String defaultColor)
at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
at Microsoft.PowerShell.PSConsoleReadLine.Insert(Char c)
at Microsoft.PowerShell.PSConsoleReadLine.SelfInsert(Nullable`1 key, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)
-----------------------------------------------------------------------
6 more times the same
-----------------------------------------------------------------------
PS C:\Users\my_user_name\Desktop\normal_directory> cd 'c:\Users\my_user_name\Desktop\normal_directory'; ${env:--All my env variables are dumped here, but snip.--; ${env:PYTHONIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFERED}='1'; & 'C:\Users\my_user_name\AppData\Local\Programs\Python\Python37\python.exe' 'c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\ptvsd_launcher.py' '--default' '--nodebug' '--client' '--host' 'localhost' '--port' '53015' 'c:\Users\my_user_name\Desktop\normal_directory\P4.py'
321
(1, 2, 3)
PS C:\Users\my_user_name\Desktop\normal_directory>
Steps to reproduce:
- Run a python file with
Ctrl + F5
/ “Start Without Debugging”. - Run it again with
Ctrl + F5
/ “Start Without Debugging”. A simple hello world program make it happens.
print("hello world!")
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 - control'
Starting Microsoft Python language server.
> conda --version
> pyenv root
> python3.7 -c "import sys;print(sys.executable)"
> python3.6 -c "import sys;print(sys.executable)"
> python3 -c "import sys;print(sys.executable)"
> python2 -c "import sys;print(sys.executable)"
> python -c "import sys;print(sys.executable)"
> py -3.7 -c "import sys;print(sys.executable)"
> py -3.6 -c "import sys;print(sys.executable)"
> py -3 -c "import sys;print(sys.executable)"
> py -2 -c "import sys;print(sys.executable)"
> ~\AppData\Local\Programs\Python\Python37\python.exe -c "import sys;print(sys.executable)"
> conda info --json
> ~\AppData\Local\Microsoft\WindowsApps\python.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python3.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python3.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python3.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> ~\AppData\Local\Microsoft\WindowsApps\python3.exe c:\Users\my_user_name\.vscode\extensions\ms-python.python-2019.9.34911\pythonFiles\interpreterInfo.py
> conda info --json
> conda --version
Issue Analytics
- State:
- Created 4 years ago
- Comments:5
Top Results From Across the Web
Define variables - Azure Pipelines | Microsoft Learn
Environment variables are specific to the operating system you are using. ... variables get processed at compile time before tasks run.
Read more >Environment variables in Compose | Docker Documentation
When you run docker-compose up with this configuration, Compose looks for the POSTGRES_VERSION environment variable in the shell and substitutes its value in....
Read more >Jenkins Pipeline Environment Variables - The Definitive Guide
Have you run into troubles when you started using Jenkins Environment Variables in your Jenkinsfile ? In this blog post, I show you...
Read more >How to set the hosting environment in ASP.NET Core
ASP.NET Core uses the ASPNETCORE_ENVIRONMENT environment variable to determine the current environment. By default, if you run your application ...
Read more >Environment variables - Numba
This means that the environment variable settings will override the settings obtained from a configuration file (the configuration file is for setting permanent ......
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
Thanks for your answer, @kimadeline !
In fact, closing the Python debug console works, thanks!
Greetings~
PS: closing the python debug console fixed the problem for ever, i can’t understand this ;-;Hi @ChaosGT 👋 thank you for reaching out. Please try one of the workarounds I mentioned above.
In the issue you opened in the VS Code repo you also wrote that sometimes VS Code will become unresponsive, if it happens again please open a separate issue for that.
Thanks!