text:
Fixes #3140 - Test log unavailable

This change addresses item #3140
This changes visible behavior
The following changes are proposed:

Replace \n whith \r\n in the test output string just before appending it to the output. This was done for win32 systems but it shoud be done for any system.
This way the text displayed in the Test Results pane is correctly formatted

Adds test item in the call to appendOutput so that the output of each test is reachable in the left part of the Test Results pane when clicking on the test in the right part of the same pane.

Other Notes/Information
I did not add test yet. I'll be happy to do so but i need some help or documentation.

@gcampbell-msft i added an entry in the CHANGELOG.
I do not understand why do you mean by "give yourself recognition".

@gcampbell-msft i added an entry in the CHANGELOG.
I do not understand why do you mean by "give yourself recognition".

There are many examples in the changelog where people give themselves credit for the fix.
Here is an example:
"Update api.ts to add the onSelectedConfigurationChanged event. #3671 @OrkunTokdemir"

@gcampbell-msft IMHO the CHANGELOG is good as is. No need for me to take credits of such small changes. ;-)

source: gharchive/pull-request

repo: microsoft/vscode-cmake-tools

license: MIT

license_type: permissive

license_source: github-api


text:
Add a "swap" icon

Here is the icon I am currently using to swap comparisons in GitLens:

source: gharchive/issue

authors: eamodio misolori

repo: microsoft/vscode-codicons


text:
Codeblock streaming is not smooth

Get a codeblock in chat response, watch response streaming
There is a lot of flickering- code appears and disappears, and the sizing is inconsistent

I'm guessing there is an issue with https://github.com/microsoft/vscode/pull/205943

Should be fixed/significantly improved by microsoft/vscode#208130

Still seems a bit off, I can help investigate

authors: mjbvz roblourens

repo: microsoft/vscode-copilot-release


text:
Docker-In-Docker Mounts Confussion

https://stackoverflow.com/questions/74145546/docker-in-docker-devcontainer-json-mount-confussion
Docker-In-Docker mounts. Where does "dind-var-lib-docker" come from in :
"mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"],

Creates the Volume. I thought that a volume mount required the volume or it would throw an error.

repo: microsoft/vscode-dev-containers


text:
[R] Add R 4.2 and minor update

Add R 4.2 (released 2022-04-22)
Fix the vscode-R's initialize command (only initialize on interactive vscode-R session)

Thanks!

authors: eitsupi joshspicer


text:
can create background photo

Environment (please complete the following information):

OS (e.g., Windows 10):
Extension version (e.g., 1.2.3):

Describe the bug:

Repro steps:

Expected behavior:

Additional context:

Closing as incomplete. Please feel free to add more information if you have any and we can re-open the issue.

repo: microsoft/vscode-edge-devtools


text:
Julia still needs support for Jupyter:Variables

Applies To

[X] Notebooks (.ipynb files)
[ ] Interactive Window and/or Cell Scripts (.py files with #%% markers)

What happened?
This is addressed in https://github.com/microsoft/vscode-jupyter/issues/7224 which says its duplicated in https://github.com/microsoft/vscode-jupyter/issues/6548
but neither solves the problem.
https://ibb.co/PFsr9bV
Note in the image that the Jupyter: Variables show that none are defined. The wonderful variable watch only works for .jl files. Not for .ipynb files.
VS Code Version
1.71.2
Jupyter Extension Version
v2022.8.1002431955
Jupyter logs
No response
Coding Language and Runtime Version
Julia 1.8.1
Language Extension Version (if applicable)
No response
Anaconda Version (if applicable)
No response
Running Jupyter locally or remotely?
Local

Issues to watch
https://github.com/microsoft/vscode/issues/166296
https://github.com/microsoft/vscode/issues/165445

authors: micampbell roblourens

repo: microsoft/vscode-jupyter


text:
Why am I prompted to install pip if I need to install ipykernel?

Testing #6821

jupyter extension; python extension
new untitled notebook with Python cells
run cells
Follow prompt to install ipykernel

See below. This one is interesting. When following the prompts I'm given, I should not fail.

Just some feedback, pip is required to install Python packages (its the package manager).
Its similar to installing packages in node, if npm isn't available we cannot install an npm package.

authors: DonJayamanne kieferrm


text:
Huge latency executing all comments since update

Searched, didn't see any open issues about this, but a few closed ones about older versions.
My previous version of VSCode  worked wonderfully but I kept getting those popups about updating.  So mainly in order to get the popups to go away, I downloaded the new version .deb file and installed via dpkg -i.  ...But then I noticed, while running remote Jupyter, that even the simplest commands would take 2 to 4 seconds to complete.  It doesn't even seem to acknowledge that I pressed Shift-Enter for a the first 2 to 4 seconds, even for just a simple print statement.
It wasn't network latency because if I open up a regular Jupyter notebook and connect via ssh port forwarding, commands complete instantaneously  (as my old VSCode version did).
So then I decided to uninstall the new version of VSCode, and go back to the previous version (1.57?),...except now the latency remains even with the old version of VSCode now.  I've tried completely uninstalling (and removing ~/.config/Code) each version and re-installing each from scratch, with no longer any success.
...I appreciate that this may be a difficult issue for you to reproduce.  I would appreciate any suggestions on this.  For now, I'm no longer using VSCode, just going back to regular Jupyter in the browser, but would love to resume VSCode use!
Environment data

VS Code version: 1.60.2
Jupyter Extension version (available under the Extensions sidebar): v2021.8.2041215044
Python Extension version (available under the Extensions sidebar): v2021.9.1246542782
OS (Windows | Mac | Linux distro) and version: Linux, Pop!_OS (Ubuntu variant) 21.04
Python and/or Anaconda version: 3.9.5 (local), 3.8 (Remote)
Type of virtual environment used (N/A | venv | virtualenv | conda | ...): venv
Jupyter server running: Local | Remote | N/A: Remote
Remote SSH: v0.65.8

Expected behaviour
Commands should execute quickly or at least provide an indication (as with normal-Jupyter's "*") that the command was received and is running.
Actual behaviour
Commands take 2 to 4 seconds to even register that they were entered, leaving the user to wonder if they actually pressed Run or Shift-Enter.
Steps to reproduce:
[NOTE: Self-contained, minimal reproducing code samples are extremely helpful and will expedite addressing your issue]

I appreciate that this may be tricky to reproduce.   As I say: I installed the new .deb version.  Then everything was slow.  Then I reverted to the old version (sorry I don't remember but I believe it was 1.57) and everything is STILL slow. Network latency is not an issue as regular Jupyter notebooks still acknowledge and execute commands instantly, only VSCode Jupyter Extension shows this 2 to 4 second latency.

As uninstalling (& removing ~/.config/Code) reinstalling did not remedy the issue,... I am happy to follow additional directions in order to help diagnose this problem.

Logs
Will follow up with logs in 24 to 48 hours.
Output for Jupyter in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Jupyter)

XXX

Thanks for filing @drscotthawley. There is something you can share that would help us a lot. Please follow these instructions to measure execution of the extension when you use a command. The generated .cpuprofile would be super helpful.
I hope you get the chance to get back to us.
Thanks a lot in advance.

...Ok found it via View > Command Pallette... > Developer: Running Extensions.
Attaching CPU profile to this comment.
CPU-20211007T193402.334Z.cpuprofile.txt

authors: DavidKutu drscotthawley


text:
Fix variable view on kernel restart

For #4474
Add restart handling for new variable view. Make sure variable provider is updating on refresh.

Oh no worries. What's the problem with multiple notebooks? Seems to work at least after my change.

Oh no worries. What's the problem with multiple notebooks? Seems to work at least after my change.

Oh no worries. What's the problem with multiple notebooks? Seems to work at least after my change.

So initially I just added a refresh tracker like you did (I will steal your event name changes, they are much better) and hooked it up to the refresh event. But was still seeing issues both with paging and with the refresh event not clearing the variables sometimes (after moving from one file to another).
Honestly I'm a bit embarrassed, my initial work does pretty fine for a single file, but it's not tracking the execution order well. There is no update for execution order when changing a file, so it would refresh on file change but it could refresh with either the execution order from the old file (if you had not executed anything in the new file after switching to it) or with 0 if you had a reset on one file or another. My change now tracks executions on all files and restores the execution count when you change to that file as the active file. Also had to change the ordering a bit on the updateExecutionCount action. This way kernelVariables won't have to change, and it will correctly use the cached list in kernelVariables if the execution count doesn't change.

Oh no worries. What's the problem with multiple notebooks? Seems to work at least after my change.

So initially I just added a refresh tracker like you did (I will steal your event name changes, they are much better) and hooked it up to the refresh event. But was still seeing issues both with paging and with the refresh event not clearing the variables sometimes (after moving from one file to another).
Honestly I'm a bit embarrassed, my initial work does pretty fine for a single file, but it's not tracking the execution order well. There is no update for execution order when changing a file, so it would refresh on file change but it could refresh with either the execution order from the old file (if you had not executed anything in the new file after switching to it) or with 0 if you had a reset on one file or another. My change now tracks executions on all files and restores the execution count when you change to that file as the active file. Also had to change the ordering a bit on the updateExecutionCount action. This way kernelVariables won't have to change, and it will correctly use the cached list in kernelVariables if the execution count doesn't change.

authors: IanMatthewHuff rchiodo


text:
PR Title Source needed?

https://github.com/microsoft/vscode-internalbacklog/issues/1021
Both the latest commit's message and the branch name seem unlikely to be helpful titles. Maybe instead just have an input box with #issuenumber as its preselected text?

@chrmarti I almost always (even before using the PR extension) want to use the latest commit message as the title of my PRs, so this makes sense for me. I hate having the issue number in the title of a PR because it is utterly un-scannable (if I'm quickly looking through commits to try to find something suspicious, a number is meaningless), so I always put the issue number on a new line.
Because of this, I never want to encourage people to put an issue number as the first thing in their commit messages. You can specify a custom PR title, is that sufficient?

I see, then make the last commit's message the default text in an input box and skip the PR Title Source step? The branch name doesn't make more sense than the issue number.

Sounds good to me!

I agree that we should use the last commit message, that is what the GH ui does as well:
Commit message

Default text for pr

Since the selected option is the last commit message, I don't think there is any further work here.

authors: alexr00 chrmarti misolori

repo: microsoft/vscode-pull-request-github


text:
Unable to sign in to Enterprise Server instance

The extension won't sign in to a GitHub Enterprise Server instance that I'm a member of. The logs show this error:
2023-10-10 14:59:30.199 [info] Logging in for the following scopes: read:user repo user:email
2023-10-10 14:59:30.203 [info] Trying device code flow... (read:user repo user:email)
2023-10-10 14:59:30.907 [error] Failed to get one-time code: {"error":"device_flow_disabled","error_description":"Device Flow must be explicitly enabled for this App","error_uri":"https://docs.github.com/enterprise-server@3.9"}

Extension version: v0.74.0
VSCode Version: 1.83.0
OS: MacOS 14.0

I'm not an administrator of the enterprise server, so I don't know if there are admin settings that need to be changed for this extension to work.

Possibly caused by microsoft/vscode#193943?


text:
Allow "Create Pull Request Suggestions" to submit suggestions directly instead of Pending suggestions

It would be nice if there was a button like "Create Pull Request Suggestions" but instead of creating "Pending" comments, it would actually submit the comments.

This is the button I am referring to ^
I have had a lot of issues where I have been unable to convert the pending suggestions to actual suggestions. Maybe it has something to do with this bug in any case I would rather submit the changes directly instead of creating pending ones.
It would be nice if it could use the commit message or ask for a message that could be used to identify the batch of suggestions that was submitted

unable to convert the pending suggestions to actual suggestions

Can you share a bit more about this? Is this the right flow?

Check out the PR
Change the code
Hit the "Create Pull Request Suggestions" button
"Pending" comments get created
What happens when you try to submit the review?

I fixed the issue with suggestions that would get stuck pending. It's available in the lastest release.


text:
pylint giving an astroid error with Python 3.12 when run from VSCode Pylint extension

I've just updated a PC I'm developing a particular project on to Python 3.12.  I did a pip freeze to save my requirements, deleted the .venv directory.  I  created a new .venv using Python 3.12, activated it, and did a 'pip install -r requirements.txt'.  When I fired up VSCode to this workspace, I find that I'm getting a message of
c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py: Fatal error while checking 'c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py'. Please open an issue in our bug tracker so we address this. There is a pre-filled template that you can use in 'C:\Users\olory\AppData\Local\pylint\pylint\Cache\pylint-crash-2023-10-04-01-57-47.txt'.
in the Problems tab.   This does not, however appear to be merely a pylint error, as if I run pylint manually against this source from an activated command line, pylint runs fine.  I've restarted VSCode, uninstalled and reinstalled the Pylint extension, and I get the same result.
The referenced template is attached:
pylint-crash-2023-10-04-01-57-47.txt
This the dump of the Pylint output window:
2023-10-04 01:57:26.171 [info] Name: Pylint
2023-10-04 01:57:26.171 [info] Module: pylint
2023-10-04 01:57:26.171 [info] Python extension loading
2023-10-04 01:57:26.171 [info] Waiting for interpreter from python extension.
2023-10-04 01:57:26.171 [info] Python extension loaded
2023-10-04 01:57:26.171 [info] Server run command: c:\Users\olory\Projects\set_contest.venv\Scripts\python.exe c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\tool\lsp_server.py
2023-10-04 01:57:26.171 [info] Server: Start requested.
2023-10-04 01:57:31.286 [info] CWD Server: c:\Users\olory\Projects\set_contest
2023-10-04 01:57:31.286 [info] Settings used to run Server:
[
{
"cwd": "c:\Users\olory\Projects\set_contest",
"workspace": "file:///c%3A/Users/olory/Projects/set_contest",
"args": [],
"severity": {
"convention": "Information",
"error": "Error",
"fatal": "Error",
"refactor": "Hint",
"warning": "Warning",
"info": "Information"
},
"path": [],
"interpreter": [
"c:\Users\olory\Projects\set_contest\.venv\Scripts\python.exe"
],
"importStrategy": "useBundled",
"showNotifications": "off",
"extraPaths": []
}
]
2023-10-04 01:57:31.286 [info] Global settings:
{
"cwd": "C:\Program Files\Microsoft VS Code",
"workspace": "C:\Program Files\Microsoft VS Code",
"args": [],
"severity": {
"convention": "Information",
"error": "Error",
"fatal": "Error",
"refactor": "Hint",
"warning": "Warning",
"info": "Information"
},
"path": [],
"interpreter": [],
"importStrategy": "useBundled",
"showNotifications": "off",
"extraPaths": []
}
2023-10-04 01:57:31.286 [info] sys.path used to run Server:
c:\Users\olory\Projects\set_contest
c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs
c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\tool
C:\Users\olory\AppData\Local\Programs\Python\Python312\python312.zip
C:\Users\olory\AppData\Local\Programs\Python\Python312\DLLs
C:\Users\olory\AppData\Local\Programs\Python\Python312\Lib
C:\Users\olory\AppData\Local\Programs\Python\Python312
c:\Users\olory\Projects\set_contest.venv
c:\Users\olory\Projects\set_contest.venv\Lib\site-packages
2023-10-04 01:57:31.361 [info] c:\Users\olory\Projects\set_contest.venv\Scripts\python.exe -m pylint --version
2023-10-04 01:57:31.361 [info] CWD Linter: c:\Users\olory\Projects\set_contest
2023-10-04 01:57:44.830 [info]
pylint 2.17.4
astroid 2.15.5
Python 3.12.0 (tags/v3.12.0:0fb18b0, Oct  2 2023, 13:03:39) [MSC v.1935 64 bit (AMD64)]
2023-10-04 01:57:44.830 [info] Version info for linter running for C:\Users\olory\Projects\set_contest:
pylint 2.17.4
astroid 2.15.5
Python 3.12.0 (tags/v3.12.0:0fb18b0, Oct  2 2023, 13:03:39) [MSC v.1935 64 bit (AMD64)]
2023-10-04 01:57:44.831 [info] SUPPORTED pylint>=2.12.2
FOUND pylint==2.17.4
2023-10-04 01:57:44.847 [info] [Trace - 1:57:44 AM] Sending request 'textDocument/codeAction - (1)'.
2023-10-04 01:57:44.929 [info] [Trace - 1:57:44 AM] Received notification 'window/logMessage'.
2023-10-04 01:57:44.929 [info] c:\Users\olory\Projects\set_contest.venv\Scripts\python.exe -m pylint --reports=n --output-format=json --clear-cache-post-run=y --from-stdin c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py
2023-10-04 01:57:44.929 [info] [Trace - 1:57:44 AM] Received notification 'window/logMessage'.
2023-10-04 01:57:44.929 [info] CWD Linter: c:\Users\olory\Projects\set_contest
2023-10-04 01:57:47.673 [info] [Trace - 1:57:47 AM] Received notification 'window/logMessage'.
2023-10-04 01:57:47.673 [info] Exception on node <ImportFrom l.10 at 0x25ce4400440> in file 'c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py'
Traceback (most recent call last):
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\pylint\checkers\imports.py", line 858, in _get_imported_module
return importnode.do_import_module(modname)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\nodes_base_nodes.py", line 146, in do_import_module
return mymodule.import_module(
^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\nodes\scoped_nodes\scoped_nodes.py", line 530, in import_module
return AstroidManager().ast_from_module_name(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\manager.py", line 232, in ast_from_module_name
return self.ast_from_file(found_spec.location, modname, fallback=False)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\manager.py", line 124, in ast_from_file
return AstroidBuilder(self).file_build(filepath, modname)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\builder.py", line 144, in file_build
module, builder = self._data_build(data, modname, path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\builder.py", line 204, in _data_build
module = builder.visit_module(node, modname, node_file, package)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\rebuilder.py", line 254, in visit_module
[self.visit(child, newnode) for child in node.body],
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\astroid\rebuilder.py", line 609, in visit
visit_method = getattr(self, visit_name)
^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'TreeRebuilder' object has no attribute 'visit_typealias'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\pylint\utils\ast_walker.py", line 91, in walk
callback(astroid)
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\pylint\checkers\imports.py", line 549, in visit_importfrom
imported_module = self._get_imported_module(node, basename)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Users\olory.vscode\extensions\ms-python.pylint-2023.6.0\bundled\libs\pylint\checkers\imports.py", line 883, in _get_imported_module
raise astroid.AstroidError from e
astroid.exceptions.AstroidError
2023-10-04 01:57:47.674 [info] [Trace - 1:57:47 AM] Received notification 'window/logMessage'.
2023-10-04 01:57:47.674 [info] file:///c%3A/Users/olory/Projects/set_contest/src/set_contest/set_contest.py :
[
{
"type": "fatal",
"module": "set_contest.set_contest",
"obj": "",
"line": 1,
"column": 0,
"endLine": null,
"endColumn": null,
"path": "src\set_contest\set_contest.py",
"symbol": "astroid-error",
"message": "c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py: Fatal error while checking 'c:\Users\olory\Projects\set_contest\src\set_contest\set_contest.py'. Please open an issue in our bug tracker so we address this. There is a pre-filled template that you can use in 'C:\Users\olory\AppData\Local\pylint\pylint\Cache\pylint-crash-2023-10-04-01-57-47.txt'.",
"message-id": "F0002"
}
]

The bundled pylint does not support 3.12. You can either set the “pylint.importStrategy” to ‘fromEnvironment’ or set “pylint.path” to point to the pylint binary in your env,

OK, setting pylint.importStrategy to fromEnvironment worked.
I'll note that the note appearing at the top of the extension Detail tab: "The bundled pylint is only used if there is no installed version of pylint found in the selected python environment." seems to imply that fromEnvironment is effectively the default.  Is it possible that that was the default (possibly before pylint.importStrategy was a setting?) and the note at the top wasn't updated when that changed?
Is it likely that before long the bundled pylint will be updated to something 3.12-compatible?

The text needs to be updated.

authors: karthiknadig oloryn

repo: microsoft/vscode-pylint


text:
Unable to debug tests: Invalid message: Found duplicate in "env": PATH

Type: Bug

Plugin Versions
Python: v2024.2.1
Python Debugger: v2024.2.0
Behaviour
Expected vs. Actual
Expected: When selecting "debug test" from test runner or the editor, the debugger should start.
Actual: Debugger fails to start. Popup dialog with message "Invalid message: Found duplicate in "env": PATH." is displayed.
Steps to reproduce:

Open a new folder in VS Code
Add a single file with a dummy unit test like this:

import unittest

class SomeTest(unittest.TestCase):
    def test_anything(self):
        self.assertTrue(True)

Configure Python tests
Try to debug the test

Diagnostic data

Python version (& distribution if applicable, e.g. Anaconda): 3.8.10
Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): Global
Value of the python.languageServer setting: Default

Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)

2024-03-12 17:28:25.416 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.421 [debug] starting server as TCP
2024-03-12 17:28:25.421 [debug] starting server as TCP
2024-03-12 17:28:25.423 [info] Using launch configuration in workspace folder.
2024-03-12 17:28:25.423 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.423 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.464 [debug] Activation Commands received undefined for shell cmd, resource c:\UserData\z003emnm\temp\duplicate_env_repro\test1 and interpreter C:\Python38\python.exe
2024-03-12 17:28:25.472 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.473 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.473 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.478 [debug] CreateEnv Trigger - turned off in settings
2024-03-12 17:28:25.616 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.634 [debug] Extension ms-python.debugpy accessed getActiveEnvironmentPath with args: undefined
2024-03-12 17:28:25.639 [debug] Extension ms-python.debugpy accessed resolveEnvironment with args: {"id":"C:\\PYTHON38\\PYTHON.EXE","path":"C:\\Python38\\python.exe"}
2024-03-12 17:28:25.647 [debug] Found cached env for C:\Python38\python.exe
2024-03-12 17:28:25.668 [debug] Extension ms-python.debugpy accessed resolveEnvironment with args: "C:\\Python38\\python.exe"
2024-03-12 17:29:10.882 [debug] Clearing context for python dependencies not installed: ms-python.python.Python
2024-03-12 17:29:10.883 [debug] Found cached env for C:\Python38\python.exe

Output for Python Debugger

```
2024-03-12 17:26:32.337 [info] Name: Python Debugger
2024-03-12 17:26:32.337 [info] Module: debugpy
2024-03-12 17:27:29.664 [info] DAP Server launched with command: C:\Python38\python.exe c:\Users\z003emnm\.vscode\extensions\ms-python.debugpy-2024.2.0-win32-x64\bundled\libs\debugpy\adapter
2024-03-12 17:28:25.647 [info] DAP Server launched with command: C:\Python38\python.exe c:\Users\z003emnm\.vscode\extensions\ms-python.debugpy-2024.2.0-win32-x64\bundled\libs\debugpy\adapter
```

User Settings

languageServer: "Pylance"

testing
• unittestArgs: ["-v", "-s", ".", "-p", "test_*.py"]
• unittestEnabled: true

experiments
• enabled: false

Extension version: 2024.2.0
VS Code version: Code 1.87.0 (019f4d1419fbc8219a181fab7892ebccf7ee29a2, 2024-02-27T23:41:44.469Z)
OS version: Windows_NT x64 10.0.19045
Modes:

System Info

Item
Value

CPUs
11th Gen Intel(R) Core(TM) i7-11850H @ 2.50GHz (16 x 2496)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: enabled_ondirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okskia_graphite: disabled_offvideo_decode: enabledvideo_encode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: enabled

Load (avg)
undefined

Memory (System)
31.67GB (19.24GB free)

Process Argv
. --crash-reporter-id ad5562b9-4802-4e9d-83ef-990f176f3ed1

Screen Reader
no

VM
0%

A/B Experiments
vsliv368cf:30146710
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscoreces:30445986
vscod805cf:30301675
binariesv615:30325510
vsaa593cf:30376535
py29gd2263:30899288
c4g48928:30535728
azure-dev_surveyone:30548225
vscrp:30673768
962ge761:30959799
pythongtdpath:30769146
welcomedialog:30910333
pythonidxpt:30866567
pythonnoceb:30805159
asynctok:30898717
pythontestfixt:30902429
pythonregdiag2:30936856
pyreplss1:30897532
pythonmypyd1:30879173
pythoncet0:30885854
pythontbext0:30879054
accentitlementsc:30887149
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
pydisww1:30981707
cppperfcontrol:30979541
8082a590:30971561
fegfb526:30981948
bg6jg535:30979843
dsvsc020:30976470

I know there also exists https://github.com/microsoft/vscode-python/issues/10722, but as the debugger is now a separate extension I was not sure if this should now be handled in this repo?

I tried to reproduce this issue on a second Windows machine (Windows 11), but there it worked fine.
The problem occurs on my work laptop with Windows 10.
What I also tried so far:

Cleaned all contents from user settings.json: no success
Disabled all extensions, only enabled Python and Python Debugger extension: no success

There is no .env file in the workspace:
C:.
│   test_something.py
│
├───.vscode
│       settings.json
│
└───__pycache__
        test_something.cpython-38.pyc

For reference, here is my full user settings.json:

User settings.json

{
    "workbench.startupEditor": "none",
    "workbench.editorAssociations": {
      "*.ipynb": "jupyter-notebook"
    },
    "notebook.cellToolbarLocation": {
      "default": "right",
      "jupyter-notebook": "left"
    },
    "terminal.integrated.defaultProfile.windows": "Command Prompt",
    "cmake.configureOnOpen": false,
    "csharp.suppressDotnetInstallWarning": true,
    "python.formatting.provider": "black",
    "[python]": {
      "editor.defaultFormatter": "ms-python.black-formatter",
      "editor.formatOnType": true
    },
    "files.exclude": {
      "**/__pycache__": true,
      "**/*.pyc": true
    },
    "testOnSave.testCommand": "",
    "python.defaultInterpreterPath": "C:\\Python38\\Scripts\\python.exe",
    "explorer.confirmDragAndDrop": false,
    "editor.formatOnSave": true,
    "workbench.iconTheme": "vscode-icons",
    "plantuml.server": "...",
    "plantuml.render": "PlantUMLServer",
    "remote.SSH.remotePlatform": {
      "dev-ec2": "linux",
      "ssm-dev-ec2": "linux"
    },
    "redhat.telemetry.enabled": false,
    "vsicons.dontShowNewVersionMessage": true,
    "java.configuration.runtimes": [
      {
        "name": "...",
        "path": "..."
      }
    ],
    "maven.settingsFile": "C:\\ProgramData\\chocolatey\\lib\\maven\\apache-maven-3.8.6\\conf\\settings.xml",
    "java.configuration.maven.userSettings": "C:\\ProgramData\\chocolatey\\lib\\maven\\apache-maven-3.8.7\\conf\\settings.xml",
    "testOnSave.languageId": "",
    "editor.stickyScroll.enabled": true,
    "git.autofetch": true,
    "markdown.validate.enabled": true,
    "git.confirmSync": false,
    "eslint.workingDirectories": ["frontend"],
    "workbench.colorTheme": "Default Dark+",
    "prettier.printWidth": 160,
    "[html]": {
      "editor.defaultFormatter": "esbenp.prettier-vscode"
    },
    "sonarlint.rules": {
      "python:S107": {
        "level": "off"
      }
    },
    "java.configuration.maven.globalSettings": "C:\\ProgramData\\chocolatey\\lib\\maven\\apache-maven-3.8.7\\conf\\settings.xml",
    "java.configuration.updateBuildConfiguration": "automatic",
    "boot-java.rewrite.reconcile": true,
    "java.format.settings.url": "...",
    "[json]": {
      "editor.defaultFormatter": "esbenp.prettier-vscode"
    },
    "maven.terminal.useJavaHome": true,
    "explorer.confirmDelete": false,
    "[typescript]": {
      "editor.defaultFormatter": "esbenp.prettier-vscode"
    },
    "prettier.singleQuote": true,
    "pylint.importStrategy": "fromEnvironment",
    "editor.renderWhitespace": "trailing",
    "robot.variables": {},
    "editor.guides.bracketPairs": "active",
    "editor.detectIndentation": false,
    "window.zoomLevel": -1,
    "[markdown]": {
      "editor.defaultFormatter": "esbenp.prettier-vscode"
    },
    "jupyter.askForKernelRestart": false,
    "[jsonc]": {
      "editor.defaultFormatter": "esbenp.prettier-vscode"
    },
    "robot.completions.keywords.prefixImportName": true,
    "continue.telemetryEnabled": false,
    "continue.enableTabAutocomplete": false,
    "mypy-type-checker.importStrategy": "fromEnvironment",
    "mypy-type-checker.args": ["--ignore-missing-imports", "--implicit-optional"],
    "accessibility.signals.terminalQuickFix": {
      "sound": "on"
    },
    "markdownlint.config": {
      "MD024": {
        "siblings_only": true
      }
    },
    "python.experiments.enabled": false
  }

In addition, the config setting for Python: Env File is set to: ${workspaceFolder}/.env (both in User and in Workspace settings).
If there is any additional information that I can provide to help find the root cause, please let me know.

With the following launch.json debugging works:
{
  // Use IntelliSense to learn about possible attributes.
  // Hover to view descriptions of existing attributes.
  // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
  "version": "0.2.0",
  "configurations": [
    {
      "name": "Python Debugger: Debug Test",
      "purpose": ["debug-test"],
      "type": "debugpy",
      "request": "launch",
      "program": "${file}",
      "console": "integratedTerminal"
    }
  ]
}

Changing console to internalConsole makes the issue reappear.
Should'nt this have been fixed via https://github.com/microsoft/vscode-python/pull/21033?

Hello! Sorry for the delay but are you still experiencing this issue?

Hi! Yes, the issue still exists. The workaround with the modified launch.json and the use of "console": "integratedTerminal" is still required.
I am using the current version 1.93.1:
Version: 1.93.1 (system setup)
Commit: 38c31bc77e0dd6ae88a4e9cc93428cc27a56ba40
Date: 2024-09-11T17:20:05.685Z
Electron: 30.4.0
ElectronBuildId: 10073054
Chromium: 124.0.6367.243
Node.js: 20.15.1
V8: 12.4.254.20-electron.0
OS: Windows_NT x64 10.0.19045

Just to add a datapoint: I have the same issue. I'm also on Win10, but my launch.json has "console": "integratedTerminal" yet still gives the error.

I found what caused the issue for me. There was an incorrect entry in the Path environment variable in windows. There was a folderpath which contained a /, which is forbidden under windows. (Going from the name, it was caused by GlazeWM, but I'm not pointing fingers.)
After removing the entry, I could debug tests again.
Hope that is helpful for some of you; maybe the error message could be improved to reflect this possible error source.

Thanks @rwijtvliet for the hint. Unfortunately that is not the case for me; at least by running echo $env:PATH in the activated virtual environment I use for the project I could not find any entry with a / in it.

authors: DudeNr33 eleanorjboyd rwijtvliet

repo: microsoft/vscode-python-debugger


text:
High CPU load and Intellisense not working

Originally posted by @werdeil in https://github.com/microsoft/vscode-python/issues/11350#issuecomment-619850168
I have the same issue, it happened each time I opened vscode, and the Intellisense is not working.
It seems to come from a error on jediProxy (according to the appended log)
-1587978994800.log

Although it doesn't look like it, try the using setting python.jediEnabled: true. Is this a one time thing?

Disabling the setting removes the high CPU load and the intellisense works again...

To answer @MikhailArkhipov, this happens with python.jediEnabled: true

Hello @werdeil,
Can you confirm that your high CPU usage and Intellisense issue happen with version 2020.4.74986 of the extension? If yes, does it also happen with an earlier version of the extension, for example 2020.3.71113?
Thank you!

issue happen with version 2020.4.74986 of the extension

yes it is with this version

does it also happen with an earlier version of the extension, for example 2020.3.71113

I don't know how I can downgrade to a previous version but willing to test if you give me how to do it.

Note: seems that extension version 2020.4.76186 doesn't have the issue, I've re enable Reid and no high CPU load...

You can follow the prompts from "Extensions: Install Specific Version of Extension..." in the command palette:

Or you can open the extensions side bar, click on the settings for the Python extension and pick "Install Another Version...":

I tested with extension version 2020.3.71113 and didn't get the high CPU load issue.

Thank you for giving it a try!
Do you have some sample code I could use to try and replicate your issue?

I'm sorry I didn't answer: it is difficult to give you some code examples whiteout giving you the whole private repository. Here are some infos I can give you to maybe narrow it:

I'm on MacOS 10.15.5
with python in a virtualenv with Python 3.7.6
main libs installed (see requirements.txt)

it happened whenever I try to save a file, could this be linked to pylint?
Today on vscode 1.46;0 and python extension v2020.6.88468 I add the issue again. But the python.jediEnabled option is no longer available, I guessed it is now Python : Language Server option, at least it solved it for a while.
Tell me if I can do anything to help

The jediProxy error posted is just a sign that we're using deprecated methods not that anything's broken (see https://github.com/microsoft/vscode-python/issues/10632).

it happened whenever I try to save a file, could this be linked to pylint?

Maybe? Can't say for sure without a minimal test repo. You can try disabling linting and see if it changes anything.

But the python.jediEnabled option is no longer available, I guessed it is now Python : Language Server option, at least it solved it for a while.

Does it mean that when python.languageServer is set to Jedi the problem doesn't appear at all? Can you try using the Microsoft Python Language Server instead (by setting python.languageServer to Microsoft)?

You can try disabling linting and see if it changes anything.

Disabling linting doesn't change anything still high CPU load.

Does it mean that when python.languageServer is set to Jedi the problem doesn't appear at all?

No it is the contrary, with jedi enabled the issue appears every time, with the python.languageServer set to Microsoft it solves the CPU load issue but listing is not working as expected.

Does your project involve/has symlinks?

FYI - I also see this problem.  I had not updated any of my VSCode extensions in a few months.  I didn't have this problem until I updated to the latest version of the Python VSCode extension a few days ago.
I'm on MacOS 10.15.5
with python in a virtualenv with Python 3.6.10
and I now have extension version v2020.6.91350.
For me, the high CPU load from completion.py seems to start as soon as I start typing a method name, possibly only on certain objects / classes.  That is, as I type
foo.get_

I do not get any autocompletion / Intellisense suggestions.  I hear the CPU fan kick into high gear.  Running top shows that the /Users/tombry/.vscode/extensions/ms-python.python-2020.6.91350/pythonFiles/completion.py process is at 100% CPU.  Then I finish typing without the help of Intellisense, for example,
foo.get_some_value(arg1, arg2)

The high CPU load continues for a couple of minutes after I stop typing.
I can confirm that if I configure the extension to use
"python.languageServer": "Microsoft"

instead of the default (Jedi), then I can type that same foo.get_some_value line, and Intellisense gives me autocompletion suggestions, and the CPU load does not spike.  I have not used it long enough to determine whether that setting causes other problems.
If you're still looking for a minimal example, I can do a little testing later.  I'm working on a proprietary code base, so I can't just send it to you.  I could check whether there are specific classes or files that seem to trigger the problem and whether I can create a smaller sample repository of code that you could use to reproduce the code locally.

Does your project (or imported libraries) involve/have symlinks?

Checking with find . -type l
My project has a couple of symlinks, but they resolve to (empty) folders in my dev environment.
There are a lot of symlinks under our node_modules dependencies for the UI / javascript portion of our application, but I assume that the Python extension is smart enough to ignore all of that.
The only other symlinks are the ones for the Python binary in our venv, which we normally keep at the root of the project workspace:
$ ls -l venv/bin/python*
lrwxr-xr-x  1 tombry  staff   9 Apr 28 07:55 venv/bin/python -> python3.6
lrwxr-xr-x  1 tombry  staff   9 Apr 28 07:55 venv/bin/python3 -> python3.6
lrwxr-xr-x  1 tombry  staff  24 Apr 28 07:55 venv/bin/python3.6 -> /opt/local/bin/python3.6

Does your project (or imported libraries) involve/have symlinks?

I have the same problem when I use Jedi. I have in my workspace a folder with several symbolic links.

After removing all the folders that had symbolic links from my workspace the autocomplete  works, and completion.py process don't have high CPU consumption anymore. In my case it didn't help because the code I wanted to use in the autocomplete is in these folders with symbolic links. But it seems that or problem has to do with symbolic link.

I did another test by copying the contents of the symbolic links, with the command:
cp -Lr folder-with-symlinks folder-without-symlinks
rm -rf folder-with-symlinks

The use of cpu remained high. So the problem may be the large amount of code inside the folder and not the symlinks.

Hi everyone,
We have recently released a new and more performant language server called Pylance which likely solves the high CPU issue.
You can download it from the marketplace and install it alongside the core Python extension. Because our team's development efforts have shifted to support the new language server, we'd encourage you to try it out.
Thank you!

@kimadeline I tested Pylance and don't have high CPU consumption. However, the autocomplete in imports does not recognize folders configured in python.autoComplete.extraPaths. Any solution to this problem?

I tested Pylance and don't have high CPU consumption. However, the autocomplete in imports does not recognize folders configured in python.autoComplete.extraPaths. Any solution to this problem?
Thank you!

@kimadeline as I said in https://github.com/microsoft/vscode-python/issues/11439#issuecomment-659856775, if we are using the Jedi, the problem occurs even if there are no symlinks. It seems to be more related to a large code base and not to symlinks.

I was referring to

However, the autocomplete in imports does not recognize folders configured in python.autoComplete.extraPaths.

Which sounded like a Pylance problem, not a Jedi problem.
Regarding the large codebase part, we do have an open issue to use newer Jedi APIs (#10632 as mentioned in https://github.com/microsoft/vscode-python/issues/11439#issuecomment-650349394 above), but I would recommend using Pylance in the meantime.

@kimadeline I say why you renamed the issue name to High CPU load and Intellisense not working if there are a lot of symlinks. It looked like that this problem of high CPU consumption occurs only because of symlinks. It may even be because of the symlinks as well, but I think the main cause is the large amount of code.

Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on then we will be happy to re-open this issue to pick up where we left off.

authors: MikhailArkhipov brettcannon idgserpro karrtikr kimadeline tombry werdeil wesleybl

repo: microsoft/vscode-python


text:
TypeError: this.context.getEnvironmentVariableCollection is not a function

Type: Bug
I'm running code version 1.81.1 and python 3.11.3 using Arch linux. I've tried the pre-release and release version of the python extension with identical results. The python extension won't load properly, the log shows an error as soon as I open any python workspace:

2023-08-17 10:19:17.604 [error] [
  'Failed to activate a workspace, Class name = g, completed in 256ms, has a falsy return value, Arg 1: , Return Value: undefined',
  [TypeError: this.context.getEnvironmentVariableCollection is not a function
  	at _.activate (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:440573)
  	at /home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2386
  	at Array.map ()
  	at g.activateWorkspace (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2376)]
]
A lot of stuff won't work (including the "Python: Report Issue..." command, but also basic stuff like auto completion, Ctrl+Click to jump to definitions, ...). I'm not sure if the cause of this is actually the error above, but I couldn't find anything else that looked suspicious. There were no issues before I recently updated from version 1.79.2 to 1.81.x.
I did not find any other reports that look similiar to this, so I'd guess it's an issue somewhere on my side. However, I was unable to find a solution, so I still ended up filing an issue to receive some support.
Extension version: 2023.15.12221007
VS Code version: Code 1.81.1 (6c3e3dba23e8fadc360aed75ce363ba185c49794, 2023-08-11T08:12:48.924Z)
OS version: Linux x64 6.4.10-arch1-1
Modes:

System Info

Item
Value

CPUs
Intel(R) Core(TM) i5-8500 CPU @ 3.00GHz (6 x 3900)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: disabled_offdirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okvideo_decode: enabledvideo_encode: disabled_softwarevulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: disabled_off

Load (avg)
0, 1, 1

Memory (System)
31.10GB (22.67GB free)

Process Argv

Screen Reader
no

VM
0%

DESKTOP_SESSION
undefined

XDG_CURRENT_DESKTOP
undefined

XDG_SESSION_DESKTOP
undefined

XDG_SESSION_TYPE
tty

A/B Experiments
vsliv368cf:30146710
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
vserr242cf:30382550
pythontb:30283811
vshan820:30294714
vstes263cf:30335440
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
vsaa593:30376534
vsclangdf:30486550
c4g48928:30535728
dsvsc012:30540252
pynewext54:30695312
azure-dev_surveyone:30548225
vscccc:30803845
3biah626:30602489
89544117:30613380
showlangstatbar:30737416
03d35959:30757346
pythoncmv:30756943
fixshowwlkth:30771522
showindicator:30805244
i26e3531:30792625
asynctok:30810527
dsvsc013:30795093
dsvsc014:30804076
diffeditorv2:30812749

Two things:

Can you please provide the output?

Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)

XXX

Try setting "python.experiments.optOutFrom": ["pythonTerminalEnvVarActivation"] in User settings and reload window.

The issue should also go away if you update your Python extension pre-release version to the latest.

Sure, here is the additional information:

Full output for `Python` in the `Output` panel after starting code and opening a Python project:
2023-08-18 08:11:44.024 [info] Experiment 'pythonaacf' is active
2023-08-18 08:11:44.024 [info] Experiment 'pythonDiscoveryModuleWithoutWatcher' is active
2023-08-18 08:11:44.024 [info] Experiment 'pythonTensorboardExperiment' is active
2023-08-18 08:11:44.025 [info] Test server listening.
2023-08-18 08:11:44.026 [info] Python interpreter path: /bin/python
2023-08-18 08:11:44.296 [error] [
  'Failed to activate a workspace, Class name = g, completed in 276ms, has a falsy return value, Arg 1: <Uri:/home/user/git/path/to/the/currently/open/pythonfile.py>, Return Value: undefined',
  [TypeError: this.context.getEnvironmentVariableCollection is not a function
  	at _.activate (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:440573)
  	at /home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2386
  	at Array.map (<anonymous>)
  	at g.activateWorkspace (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2376)]
]
2023-08-18 08:11:44.296 [error] Failure during activation. [TypeError: this.context.getEnvironmentVariableCollection is not a function
	at _.activate (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:440573)
	at /home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2386
	at Array.map (<anonymous>)
	at g.activateWorkspace (/home/patrick/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2376)]
2023-08-18 08:11:44.296 [error] sendStartupTelemetry() failed. [TypeError: this.context.getEnvironmentVariableCollection is not a function
	at _.activate (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:440573)
	at /home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2386
	at Array.map (<anonymous>)
	at g.activateWorkspace (/home/user/.vscode/extensions/ms-python.python-2023.15.12221007/out/client/extension.js:2:2376)]
2023-08-18 08:11:44.829 [info] Starting Pylance language server.
2023-08-18 08:11:45.515 [info] LINTING: Skipping linting from Python extension, since Flake8 extension is installed and enabled.

When setting "python.experiments.optOutFrom": ["pythonTerminalEnvVarActivation"] an additional line 2023-08-18 08:15:42.235 [info] Experiment 'pythonTerminalEnvVarActivation' is inactive shows up in the log, but otherwise everything is unchanged.

Indeed, this error does not show up anymore if I switch to the release version v2023.14.0. The actual issue that "nothing" is working properly (e.g. no auto-completion, unable to jump to definitions via ctrl+click, ... - all the stuff one uses an IDE for) is still there (which was the reason I checked out the prerelease in the first place). So I guess the cause for that is a different issue - but without any error logs anywhere, I guess I'll have to search further myself.
At least I was able to report some error in the pre-release version then...

The issue was fixed here in the Python extension pre-release, but unfortunately that pre-release is only applicable on VS Code insiders: https://github.com/microsoft/vscode-python/pull/21799.
So I'm making another fix to backport this fix to VS Code stable: https://github.com/microsoft/vscode-python/pull/21846. Thanks for reporting!

Please try updating your Python extension to latest pre-release version (with "python.experiments.optOutFrom": ["pythonTerminalEnvVarActivation"] still being there), and see if you still run into the issue.

I Just ran into the exact same problem, and the error did go away just fine with the latest pre-release version.
However, I am still experiencing the no auto-completion/reference jumping like @Patschke.
Same x64 Linux kernel and VS Code version on my side.

@ThibautHH Thanks for verifying. Could you open a new issue for auto-completion using Python: Report Issue command? We'll be happy to have a look.

authors: Patschke ThibautHH karrtikr


text:
module not getting installed

Type: Bug
i am trying to install mediapipe module that is a python library and i had already installed it but isnt showing up , i even tried to install it again , it shows me this message " ERROR: Could not find a version that satisfies the requirement mediapipe (from versions: none)
ERROR: No matching distribution found for mediapipe " please help
VS Code version: Code 1.87.0 (019f4d1419fbc8219a181fab7892ebccf7ee29a2, 2024-02-27T23:41:44.469Z)
OS version: Windows_NT x64 10.0.22631
Modes:

System Info

Item
Value

CPUs
AMD Ryzen 7 5800H with Radeon Graphics          (16 x 3194)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: enabled_ondirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okskia_graphite: disabled_offvideo_decode: enabledvideo_encode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: enabled

Load (avg)
undefined

Memory (System)
13.86GB (2.17GB free)

Process Argv
--crash-reporter-id 762c749b-bf84-43c5-877a-f6b6a51d199b

Screen Reader
no

VM
0%

Extensions (60)

Extension
Author (truncated)
Version

flutter-snippets
ale
3.0.0

shell
bbe
0.3.0

htmlplay
bia
0.0.10

blackbox
Bla
1.2.62

tf2snippets
cha
0.1.0

doxdocgen
csc
1.4.0

dscodegpt
Dan
3.2.1

dart-code
Dar
3.84.0

flutter
Dar
3.84.0

vscode-eslint
dba
2.4.4

gitlens
eam
14.8.2

prettier-vscode
esb
10.1.0

figma-vscode-extension
fig
0.3.3

vscode-firefox-debug
fir
2.9.10

code-runner
for
0.12.1

kotlin
fwc
0.2.34

copilot
Git
1.171.0

copilot-chat
Git
0.13.0

vscode-flutter-files
gor
4.8.1

gc-excelviewer
Gra
4.2.59

vscode-test-explorer
hbe
2.21.1

better-cpp-syntax
jef
1.17.2

Kotlin
mat
1.7.1

csharp
ms-
2.18.16

vscode-dotnet-runtime
ms-
2.0.2

vscode-edge-devtools
ms-
2.1.5

debugpy
ms-
2024.2.0

isort
ms-
2023.10.1

python
ms-
2024.2.1

vscode-pylance
ms-
2024.2.2

jupyter
ms-
2024.2.0

jupyter-keymap
ms-
1.1.2

jupyter-renderers
ms-
1.0.17

vscode-jupyter-cell-tags
ms-
0.1.8

vscode-jupyter-slideshow
ms-
0.1.5

remote-containers
ms-
0.348.0

remote-ssh
ms-
0.109.0

remote-ssh-edit
ms-
0.86.0

remote-wsl
ms-
0.86.0

cmake-tools
ms-
1.17.17

cpptools-extension-pack
ms-
1.3.0

remote-explorer
ms-
0.4.3

test-adapter-converter
ms-
0.1.9

bdfd-bds
Nig
2.1.0

java
red
1.28.1

vscode-php-test-explorer-docker
sat
1.0.5

sonarlint-vscode
Son
4.3.0

tensorbox
Ten
1.0.2

vscode-css-custom-properties
Toc
0.0.5

pdf
tom
1.2.2

cmake
twx
0.0.17

vscode-lldb
vad
1.10.0

tensorflow-snippets
vah
0.3.3

intellicode-api-usage-examples
Vis
0.2.8

vscodeintellicode
Vis
1.2.30

vscode-java-debug
vsc
0.56.2

vscode-java-dependency
vsc
0.23.5

vscode-java-pack
vsc
0.25.15

vscode-java-test
vsc
0.40.1

vscode-maven
vsc
0.44.0

(1 theme extensions excluded)

A/B Experiments
vsliv368cf:30146710
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscoreces:30445986
vscod805cf:30301675
binariesv615:30325510
vsaa593:30376534
py29gd2263:30899288
c4g48928:30535728
azure-dev_surveyone:30548225
vscrpc:30673769
2i9eh265:30646982
962ge761:30959799
pythongtdpath:30769146
welcomedialog:30910333
pythonidxpt:30866567
pythonnoceb:30805159
asynctok:30898717
pythontestfixt:30902429
pythonregdiag2:30936856
pyreplss1:30897532
pythonmypyd1:30879173
pythoncet0:30885854
pythontbext0:30879054
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
pydisww1:30959800
cppperfnew:30979542
d34g3935:30971562
edj9j583:30969295
a89i1917:30973842
78248357:30976999
dsvsc020:30976470

@PaarthSuwi What is the version of python you are tying to install mediapipe on? if it is python 3.12 on windows it looks like they don't have it available for that yet. Try python 3.11.
This issue has nothing to do with python extension.

@karthiknadig yes I tried it on the 3.11 still the same message I'll look into it again

If you continue to run into this issue please file it on https://github.com/google/mediapipe/issues
Closing this, since it is not related to python extension.

authors: PaarthSuwi karthiknadig


text:
Starting the Python REPL when using miniconda fails to start

Environment data

VS Code version: 1.39.1
Extension version (available under the Extensions sidebar): October 2019
OS and version: Windows 10
Python version (& distribution if applicable, e.g. Anaconda): 3.7.4
Type of virtual environment used (N/A | venv | virtualenv | conda | ...): Miniconda

Expected behaviour
REPL starts and activates conda
Actual behaviour
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.

Try the new cross-platform PowerShell https://aka.ms/pscore6

PS D:\Training\Impractical Python Projects> conda activate jupyter
conda : The term 'conda' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ conda activate jupyter
+ ~~~~~
    + CategoryInfo          : ObjectNotFound: (conda:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS D:\Training\Impractical Python Projects> & C:/Users/rchiodo.REDMOND/AppData/Local/Continuum/miniconda3/envs/jupyter/python.exe
Python 3.7.4 (default, Aug  9 2019, 18:34:13) [MSC v.1915 64 bit (AMD64)] :: Anaconda, Inc. on win32

Warning:
This Python interpreter is in a conda environment, but the environment has
not been activated.  Libraries may fail to load.  To activate this environment
please see https://conda.io/activation

Steps to reproduce:

Start Python REPL from the command palette after selecting a python interpreter

-1570836003181.log

Did you specify "pyhton.condaPath" in settings?

All I did was pick something with the selection picker at the bottom. I believe that specifies pythonPath, not condaPath?

Hmm, not reproing anymore. The conda environment starts just fine.

authors: karthiknadig rchiodo


text:
Connect to raw kernel with command line args instead of connection file

For #11883

[x] Pull request represents a single change (i.e. not fixing disparate/unrelated things in a single PR).
[x] Title summarizes what is changing.
[x] Has a news entry file (remember to thank yourself!).
[x] Appropriate comments and documentation strings in the code.
[ ] Has sufficient logging.
[ ] Has telemetry for enhancements.
[ ] Unit tests & system/integration tests are added/updated.
[ ] Test plan is updated as appropriate.
[ ] package-lock.json has been regenerated by running npm install (if dependencies have changed).
[ ] The wiki is updated with any design decisions/details.

Hey did you try a nightly run? Can't seem to find it. Was curious if it worked or not.

@rchiodo Just queued it up. Just didn't do that until after lunch. I'm going to submit regardless as I think it's a good change anyways. Fingers crossed that it fixes the windows flakes as well.


text:
Prevent updates to cell text when stauts of cell has changed

For #7844

[x] Pull request represents a single change (i.e. not fixing disparate/unrelated things in a single PR)
[x] Title summarizes what is changing
[x] Has a news entry file (remember to thank yourself!)
[x] Appropriate comments and documentation strings in the code
[n/a] Has sufficient logging.
[n/a] Has telemetry for enhancements.
[no] Unit tests & system/integration tests are added/updated
[n/a] Test plan is updated as appropriate
[n/a] package-lock.json has been regenerated by running npm install (if dependencies have changed)
[n/a] The wiki is updated with any design decisions/details.

Codecov Report

Merging #7973 into master will decrease coverage by 0.74%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #7973      +/-   ##
==========================================
- Coverage   59.26%   58.52%   -0.75%
==========================================
  Files         498      498
  Lines       22306    21945     -361
  Branches     3581     3576       -5
==========================================
- Hits        13220    12843     -377
- Misses       8263     8270       +7
- Partials      823      832       +9

Impacted Files
Coverage Δ

...nt/datascience/jupyter/invalidNotebookFileError.ts
0% <0%> (-75%)
:arrow_down:

.../client/datascience/jupyter/jupyterConnectError.ts
0% <0%> (-66.67%)
:arrow_down:

...science/jupyter/jupyterKernelPromiseFailedError.ts
0% <0%> (-50%)
:arrow_down:

...ent/datascience/jupyter/jupyterWaitForIdleError.ts
0% <0%> (-50%)
:arrow_down:

src/client/common/utils/platform.ts
64.7% <0%> (-23.53%)
:arrow_down:

src/client/language/characters.ts
12% <0%> (-21.34%)
:arrow_down:

src/client/testing/codeLenses/main.ts
60% <0%> (-17.78%)
:arrow_down:

src/client/datascience/cellFactory.ts
72.34% <0%> (-17.32%)
:arrow_down:

src/client/common/platform/pathUtils.ts
66.66% <0%> (-5.56%)
:arrow_down:

src/client/linters/pydocstyle.ts
84.61% <0%> (-5.13%)
:arrow_down:

... and 33 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b6545e3...258a8d3. Read the comment docs.

authors: DonJayamanne codecov-io


text:
marketplace

Issue Type: Bug
i have just downloaded visual studio on my mac . And it does not want to download anything from the marketplace .
VS Code version: Code 1.47.2 (17299e413d5590b14ab0340ea477cdd86ff13daf, 2020-07-15T18:18:50.054Z)
OS version: Darwin x64 19.5.0

System Info

Item
Value

CPUs
Intel(R) Core(TM) i5-3317U CPU @ 1.70GHz (4 x 1700)

GPU Status
2d_canvas: enabledflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmetal: disabled_offmultiple_raster_threads: enabled_onoop_rasterization: disabled_offprotected_video_decode: unavailable_offrasterization: enabledskia_renderer: disabled_off_okvideo_decode: enabledviz_display_compositor: enabled_onviz_hit_test_surface_layer: disabled_off_okwebgl: enabledwebgl2: enabled

Load (avg)
2, 2, 1

Memory (System)
4.00GB (0.02GB free)

Process Argv
-psn_0_397409

Screen Reader
no

VM
0%

Extensions: none

Please follow these steps

Help -> Toggle Developer Tools -> Network
Then check for any network failed requests while browsing and installing the extensions if found all requests fails then its probably a proxy or DNS issue at your end.
To confirm its a DNS issue check if you can access this page https://ms-python.gallerycdn.vsassets.io/extensions/ms-python/python/2019.8.29288/1565127378610/Microsoft.VisualStudio.Services.Icons.Default, if you cannot please try configuring your DNS like pointing to 1.1.1.1 as suggested here? https://1.1.1.1/dns/. Otherwise please contact your network administrator.
If it is not a network issue, please share the logs from the following locations

Help -> Toggle Developer Tools -> Console
View -> Command Pallette... -> Toggle Shared Process -> Console
View -> Open View… -> Log (Shared)
View -> Open View… -> Log (Window)

repo: microsoft/vscode


text:
Proxy Authentication dialog does not work properly

VSCode Version: 1.48
OS Version: Xubuntu 18.04

Proxy authentication dialog does not work properly. After filling login and pass fields clicks on buttons Ok or Cancel do nothing and dialog does not close after that. You can only close the dialog with close button.
Steps to Reproduce:

Open VS Code 1.48 with proxy authentication
Try to fill login and pass fields and click on Ok or Cancel buttons.

Does this issue occur when all extensions are disabled?: Yes

Proxy authentication dialog does not work properly. After filling login and pass fields clicks on buttons Ok or Cancel do nothing and dialog does not close after that. You can only close the dialog with close button.

I have the same issue on Win32-x64

Same Issue with Manjaro x86-64.
Also there is rendering problem with dialog window in 70% of time: wrong paddings and dissapearing file menu.

/duplicate of #104603 which offers a workaround

authors: gjsjohnmurray nihlete orthoxerox vacvvn


text:
Wrong display on integrated terminal

Issue Type: Bug
See screenshot. The text should be left aligned, but several lines of the display is broken. The only possible factor I can say is the existence of CJK characters in the terminal (sadly, all CJK characters in the screenshot are redacted because of personal information).
In the first 4 our of 5 broken lines, Chinese characters are displayed double (e.g. ＸＹＺ becomes ＸＸＹＹＺＺ).
Scrolling up/down don't appear to improve the display.

VS Code version: Code 1.48.2 (a0479759d6e9ea56afa657e454193f72aef85bd0, 2020-08-25T10:13:11.295Z)
OS version: Windows_NT x64 10.0.19041

System Info

Item
Value

CPUs
AMD Ryzen 5 3600 6-Core Processor               (12 x 2396)

GPU Status
2d_canvas: enabledflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onoop_rasterization: disabled_offprotected_video_decode: unavailable_offrasterization: enabledskia_renderer: disabled_off_okvideo_decode: enabledviz_display_compositor: enabled_onviz_hit_test_surface_layer: disabled_off_okwebgl: enabledwebgl2: enabled

Load (avg)
undefined

Memory (System)
15.93GB (6.56GB free)

Process Argv

Screen Reader
no

VM
0%

Extensions (7)

Extension
Author (truncated)
Version

asciidoctor-vscode
asc
2.8.3

php-intellisense
fel
2.3.14

vscode-phpfmt
kok
1.0.30

python
ms-
2020.8.103604

powershell
ms-
2020.6.0

rewrap
stk
1.13.0

vscode-sftp
sun
1.1.1

This issue seems to originate from an upstream component and is not something VSCode can fix by making a change to our code. As such, I will go ahead and close it. Please try to reproduce in Windows Terminal and report to microsoft/terminal with repro steps.
Thanks for understanding.

authors: Tyriar lwchkg


text:
Add a setting to configure the size of the area the breakpoints are added

Currently there is too much space in the area we add breakpoints. Is it really necessary?

I could fit two breakpoints there haha

I did not find a way to configure it.

This is just the size of the editor glyph margin. There can be other things there not only breakpoints (for example quick fixes).
This is designed behavior of the editor thus closing.

authors: AllanOricil isidorn


text:
Double click to edit port cell

Testing #117250
Could be useful instead of having to use the context menu.

This is not a pattern we use in other places. For example, double clicking an item in the file explorer doesn't let you rename.

@alexr00 yes, debug: function breakpoints, variables. We are not using it in places where clicking has another action like opening.


text:
Downloading a file with no extension from browser automatically adds ".txt"

When downloading the compiled file (.out/app) in step 6, the downloaded file on my laptop is called app.txt. Something added the .txt extension automatically.
I'm using Edge 88 on macOS.
from @bamurtaugh @ItalyPaleAle

I investigated into this and this is just how Chrome (and thus Edge) behaves and I am not sure if we can introduce a workaround for this.
Since in this case we fall back to the simple download operation here
More about how chrome handles this can be found here https://developers.google.com/web/updates/2011/08/Downloading-resources-in-HTML5-a-download
So in short, we fall back to Chrome and Chrome decides to add .txt to a file with no extension
fyi @bpasero

Do you think it might make sense to create an archive (like a ZIP) of all files downloaded from Codespaces?  This would not just solve the issue of the extension, but would also make the download potentially smaller, and would fix other issues like https://github.com/microsoft/vscode/issues/112099
Just a thought :)

@ItalyPaleAle might make sense. Other software usually downloads as zip when there is more than one file to download.
If a user is just downloading one file, then putting it in a zip might just add one extra step...

We closed this issue because we don't plan to address it in the foreseeable future. If you disagree and feel that this issue is crucial: we are happy to listen and to reconsider.
If you wonder what we are up to, please see our roadmap and issue reporting guidelines.
Thanks for your understanding, and happy coding!

well, you may have closed the issue, but the issue with Edge appending .txt to files without an extension is not solved by that. I actually have to fall back to IE to download such files. Seems you have buries IE a little too early

authors: ItalyPaleAle VSCodeTriageBot WRFan isidorn


text:
vscode in WSL cant update: Unable to download server on client side

VS Code Version: 1.54.1
OS Version: Windows build 19042 WSL2 (Ubuntu 18.04)

Steps to Reproduce:

Type code in WSL

Does this issue occur when all extensions are disabled?: Yes

it looks like the server is not reachable

Same problem here
VSCode + WSL not working after update

duplicate of https://github.com/microsoft/vscode-remote-release/issues/4648

authors: aeschli dragonH maple3142


text:
VS Code Is Wondeful!

Issue Type: Just Say Thanks!
Dear VS Code Dev Girls&Guys,
Kudos! your IDE is becoming amazing!
and it keeps get better and better all the time,
so i stopped coding for few minutes to thanks you for this magnificent IDE
hope you get big bonus for this achievement!
sorry for spamming your bug queue...
Shahar
VS Code version: Code 1.56.0 (cfa2e218100323074ac1948c885448fdf4de2a7f, 2021-05-04T22:09:06.405Z)
OS version: Windows_NT x64 10.0.19042

@shahar-le thank you for the feedback 🌷

authors: egamma shahar-le


text:
Disable "Clear Recently Opened" menu item

It is easy to inadvertedly click on the menu item residing at File > Open Recent > Clear Recently Opened and lose a list containing many projects.
The proposed feature would be a setting to disable or remove that option.

Alternatively, add an "Are you sure?" modal dialog.

Yes, I'd wondered about that too. It was a bit of a shock when all the projects disappeared when I missed the More... row above the Clear Recently Opened row.

authors: gjsjohnmurray mikejpoole


text:
lose changes when closing the editor - jupyter notebooks

Does this issue occur when all extensions are disabled?: Yes/No

VS Code Version: 1.59.0
OS Version: Windows 10

I've been using vscode to modify notebooks. I copy an existing file, change the name, make the modifications, they are saved in the output cells, but when I close the editor and reopen the file the changes I made are lost.
I have the option afterDelay enabled.

@kellycastrof if you scroll to the top of the document and then close/reopen, do you get the changes back?

authors: kellycastrof rebornix


text:
Non-existent debugger configuration

Does this issue occur when all extensions are disabled?: Yes

VS Code Version: 1.60.2 (user setup)
OS Version: Windows 10 Pro x64

Steps to Reproduce:

Click on Debug symbol
Click "Run and Debug" drop down

Yet my configuration only has
{
  // Use IntelliSense to learn about possible attributes.
  // Hover to view descriptions of existing attributes.
  // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
  "version": "0.2.0",
  "configurations": [
    {
      "type": "pwa-node",
      "request": "launch",
      "name": "Launch Program",
      "skipFiles": [
        "<node_internals>/**"
      ],
      "program": "${file}"
    }
  ]
}

Every project has a mysterious "Run Script: dev"
It is very similar to issue #121148 .
I tried

Deleting and recreating launch.json
Examined my user settings
Deleting everything under C:\Users<userid>\AppData\Roaming\Code\Local Storage

I tried testing it on my fastify instance with the assumption its trying to npm dev. I keep getting an error "Could not read source map for internal...." and then nodemon logs (clean exit - waiting for changes before restart). I already have a debug script that works but this option keeps popping up everywhere.

Yes, this is a dynamic launch config which js-debug contributes to debug an npm script. I'm not sure why it would appear on every project, from testing and a reading of the source it should only appear when it's been used in a workspace (everything debug stores is StorageScope.WORKSPACE).
Maybe there should be a way to clear dynamic configs, however. Perhaps a 🗑 icon in the debug quick access/quickpick?


text:
Nit: searching for markdown in language picker

In a new file, click the "select language" text and search for "md" in the language picker. There isn't an exact match for markdown and the first result is Batch which is a bit annoying. Other language choices in this list seem to have the file extension in the (parentheses), should it read "Markdown (md)" for a better match?

FYI: Those are language identifiers in the parentheses not extensions, see language identifiers.

This is a consequence of https://github.com/microsoft/vscode/issues/106886 where we decided to not show the extensions for brevity. I think then we introduced meta as a property to allow to find an item without requiring that data to be visible in the picker.
But maybe meta should show the portion that matches in case there is a match? Here we get a match from .cmd because that is what Batch is registered for.

On a slightly related note, it seems weird to me that the top level actions appear sorted with languages as soon as you start searching:

authors: ArturoDent bpasero sana-ajani


text:
VsCode will not close while trying to re-establish remote connection

Does this issue occur when all extensions are disabled?: No, but can't get a remote without the extension :)

Version: 1.62.2 (system setup)
Commit: 3a6960b964327f0e3882ce18fcebd07ed191b316
Date: 2021-11-11T20:56:38.428Z
Electron: 13.5.2
Chrome: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.19044

Steps to Reproduce:

Connect to a codespace
Wait for it to suspend and vscode enters a trying to reconnect state (which won't succeed as the remote is gone)
Attempt to close vscode via the X button
No response from the X button, a lot of modals popping up

Possibly related to https://github.com/microsoft/vscode/issues/136358

Please try updating (.3 released today) and see if it works now

Still mostly repros in 1.62.3, it does actually close when it gets to the error toast, but still goes through a lot of modals in the meantim

e:

@Tyriar is this related to #136358 or is codespaces blocking exit?

its stays in the reconnecting loop!
Is there a possibility that we can downgrade to 1.62.2 ?
Thanks!

@chrmarti @aeschli any ideas? The fix for the candidate was pretty straightforward; just swallow any errors that come about from the terminal shutting down. So I doubt this is related to the terminal.

I looked at the window logs when this happens, and it looks like it might still be a terminal veto issue? I'm on 1.62.3.
[2021-11-19 10:49:54.466] [renderer1] [error] {"isTrusted":true}
[2021-11-19 10:49:54.466] [renderer1] [info] [remote-connection][Management   ][a1114…][reconnect] starting reconnecting loop. You can get more information with the trace log level.
[2021-11-19 10:49:54.466] [renderer1] [info] [remote-connection][Management   ][a1114…][reconnect] resolving connection...
[2021-11-19 10:49:54.477] [renderer1] [info] [remote-connection][ExtensionHost][cd6ec…][reconnect] received socket close event (wasClean: false, code: 1006, reason: ).
[2021-11-19 10:49:54.478] [renderer1] [error] {"isTrusted":true}
[2021-11-19 10:49:54.478] [renderer1] [info] [remote-connection][ExtensionHost][cd6ec…][reconnect] starting reconnecting loop. You can get more information with the trace log level.
[2021-11-19 10:49:54.478] [renderer1] [info] [remote-connection][ExtensionHost][cd6ec…][reconnect] resolving connection...
[2021-11-19 10:58:51.557] [renderer1] [warning] [lifecycle] onBeforeShutdown is taking a long time, pending operations: veto.terminal
[2021-11-19 10:58:54.865] [renderer1] [warning] [lifecycle] onBeforeShutdown is taking a long time, pending operations: veto.terminal
[2021-11-19 10:58:59.350] [renderer1] [warning] [lifecycle] onBeforeShutdown is taking a long time, pending operations: veto.terminal
[2021-11-19 10:59:03.798] [renderer1] [warning] [lifecycle] onBeforeShutdown is taking a long time, pending operations: veto.terminal

From what I can tell, it looks like the terminal veto check is hanging rather than throwing, so the try/catch solution might not be fully helping if it's not getting that far.

Looking into it now. The warning seems to show after 5 seconds:
https://github.com/Microsoft/vscode/blob/0413d4a596931d8b3634e76382109adc94e8a81a/src/vs/workbench/services/lifecycle/electron-sandbox/lifecycleService.ts#L101-L103

I think the root cause is the message to the persist the terminals to the remote side is going out but never getting a reply since the Codespace is suspended.

Mostly seems to reproduce with a test resolver window and killing the server.

Apparently https://github.com/microsoft/vscode/commit/5af09003bc2339612703e7f5bb1a97d97136ac07 never made it to the main branch which fixes my test resolver repro, but the issue says that it repro's in both 1.62.2 and 1.62.3 so it must be a different problem. Will keep looking.

@Tyriar All RPC calls done to the remote side will simply be queued up when the window is disconnected. These RPC calls will not throw an error as long as there is not a permanent connection error. That is how our reconnection is implemented, it happens transparently to the RPC proxy users.
The state of the connection can be spied on using:
const connection = this.remoteAgentService.getConnection();
if (connection) {
	this._register(connection.onDidStateChange((e) => { console.log(e); }));
}

My personal suggestion would be to never include awaited RPC calls in the veto or shutdown path, because veto and shutdown should not take arbitrary time. It is possible that an RPC call takes up to 3 hrs until reconnection gives up.

@alexdima thanks for the info, do you know if there an easy way to reproduce this case out of sources?

My personal suggestion would be to never include awaited RPC calls in the veto or shutdown path, because veto and shutdown should not take arbitrary time.

This is how the process revive stuff works in the terminal, it's disabled in web because of this limitation. I don't think persisting the terminal contents constantly is really an option due to the amount of changes that happen in the terminal. We could also do it similar to hot exit where it gets debounced, but that's a lot of disk IO for every command run in the terminal when it works pretty well now.

do you know if there an easy way to reproduce this case out of sources?

I'm sorry, I don't quite know how to reproduce this specific case. From the OP:

Connect to a codespace
Wait for it to suspend and vscode enters a trying to reconnect state (which won't succeed as the remote is gone)

What I would expect here is that the Codespaces resolver would observe that the codespace is suspended and would either wake it up or throw a permanent reconnection error which would end our reconnection loop.

To simulate this from source, I think source changes would need to be done to the test resolver.  Maybe this child process can be killed after a setTimeout of 5s and maybe the doResolve method can then proceed to always return the previous value it returned. But I am not 100% sure if this behavior would match the Codespaces resolver. The best would be to repro this with the Codespaces resolver and take a look at the window logs to see what it returns from its resolve call.

I pushed a fix to allow waiting a maximum of 2 seconds for the persistence, this should only ever be hit on very high latency connections or when the remote is reconnecting like in this issue.

I'm not sure if I hit the exact cases described here, but I was able to get out of the codespace by using the x while a dialog was showing.

authors: Tyriar alexdima alexr00 cmbrose jkeech roblourens vuppalaprasanth


text:
JS: element innerText property doesn't pop in member list if select by class

Does this issue occur when all extensions are disabled?: Yes

VS Code Version:  1.63.2
OS Version:  W10 v21H1 x64

Steps to Reproduce:
For the below code, start typing "inner" for the "x." element -> only "InnerHTML" shows, but for the "z." element both "innerText" and "innerHTML" show in the member list.
<html>
<button class="copyLink">copy this link</button>
<script>
let z = document.querySelector('button'); z.
let x = document.querySelector('.copyLink'); x.
</script>
</html>

Hover over the types for z and x. VS Code can infer that z is a HTMLButtonElement but does not know the more specific element type of x so it is just Element. Not every type of element returned by that querySelector would have an innerText property
If you know the types of the elements you are retrieving though, just add a cast:
/** @type {HTMLElement} */ let x = document.querySelector('.copyLink')

So, VSC doesn't know how to understand the code for a class identifier in the querySelector method, but it does for an element?  How does VSC know that x even has an "InnerHTML" property if it doesn't know exactly what kind of element is it?  This is why I reported it has a bug.  I'd expect both to properly understand the element type.
Thanks, @mjbvz  for the detailed explanation.

authors: JustinWebDev mjbvz


text:
Markdown: Suggest GitHub-style line number fragments in link auto-complete for source code files

Appreciate Markdown support and support for line number fragments (e.g. #L3) in links to source code files as supported on GitHub.
For example, the following link works great in a Markdown doc both on GitHub and in VS Code and navigates you to the right line of code:
[MyClass](../../../src/MyFile.cs#L23)

I just saw @mattbierner on YouTube talking about potential auto-complete suggestions for links in markdown including section fragments for text files. Wouldn't it great if this auto-complete included suggested line number fragments for e.g. C# class definitions and other significant symbols when linking to a source code file? This would save going to those files to find line numbers of class definitions etc and greatly help when documenting code.
For example, if in ../../../src/MyFile.cs a class called MyClass were defined on line 23, auto-complete could offer #L23 as a fragment with the line's contents displayed to the right in a different colour. Effectively the auto-complete suggestions could mirror the source code file's outline view items with appropriate line number fragments for each.
Thanks for considering this!

This seems like a good candidate for an extension


text:
editor.wordSeparaters do not work well with specific characters

This problem still occurs even if you disable all extensions. This problem was confirmed in LaTeX file.
editor.wordSeparaters do not work well with specific characters
When editor.wordSeparators is configured as follows, ． (U+FF0E) doesn't work well as a separaters. This problem is also seen in ， (U+FF0C).
  "editor.wordSeparators": "`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?，．",
//                                              Added these: ^ ^

In Japanese, writing ． at the end of the sentence indicates the end of the sentence, like a period. ， is used like a comma. Especially, it is inconvenient that the suggestion is not displayed after the separater because the text is typed after ． or ，.
As an example, I gave some demonstrations to the following sentence.
こんにちは．先生

Demo 1
Place the cursor. The entire text will be shaded. Should be separated by ．.

Demo 2
Continue to type lestters and call suggestions (Ctrl+Space). In advance, I created 先生 and teacher as a snippet.
{
  "Teacher in Japanese": {
    "prefix": "せんせい",
    "body": "先生",
    "description": "先生: Teacher in Japanese"
  },
  "Teacher in English": {
    "prefix": "teacher",
    "body": "Teacher",
    "description": "Teacher in English"
  }
}

Suggestions are not displayed. Even if you press Ctrl+D, No suggestions are displayed.

Demo 3
Execute Ctrl+Backspace (deleteWordLeft) and Ctrl+D (editor.action.addSelectionToNextFindMatch).

Ctrl+Backspace

Ctrl+D

These seem to work well.
For Markdown
I also tried Markdown.
If you do the same with Markdown with all extensions disabled, this problem will not occur but, if you enable Markdown All in One, you will have similar problems. For that reason, it was difficult to know where this problem came from and to determine where to submit this issue.
If the issue with Markdown is due to the extension, please let me know.
I don't know what the results will be for other languages.
Version
  Version: 1.65.2 (user setup)
  Commit: c722ca6c7eed3d7987c0d5c3df5c45f6b15e77d1
    Date: 2022-03-10T14:33:55.248Z
Electron: 13.5.2
Chromium: 91.0.4472.164
  Node.js: 14.16.0
      V8: 9.1.269.39-electron.0
      OS: Windows_NT x64 10.0.19043

@Yarakashi-Kikohshi In VS Code, there are two conceptual "word definitions". The first one is derived from the setting editor.wordSeparators and the second one is defined via a mechanism called language configuration by extensions and is programming language specific.

1. occurrence highlighting
This comes up when clicking on a word and the language doesn't have a semantic occurrence highlighting registered. This uses the language configuration word definition.
2. suggestions
Suggestions also use the language configuration word definition.
3. Delete word Left, Select next find match with word toggle on
These two commands use the configured editor.wordSeparators

This is the current built-in word definition for markdown:
https://github.com/microsoft/vscode/blob/3e5c7e2c570a729e664253baceaf443b69e82da6/extensions/markdown-basics/language-configuration.json#L55
And this is the current built-in word definition for LaTeX:
https://github.com/microsoft/vscode/blob/3e5c7e2c570a729e664253baceaf443b69e82da6/extensions/latex/latex-language-configuration.json#L110

@alexr00 Given LaTeX is similar to markdown, forwarding to you to investigate if the LaTeX word definition could be improved using some new concepts that markdown is using.

Thank you for the very clear explanation, @alexdima !

I had assumed that the three behaviors that I mentioned in the demonstration came from editor.wordSeparators, but now I understand that the first and second come from "the language configuration word definition". I also learned that "the language configuration word definition" is defined for each language.
Given the above, I can guess that Markdown All in One is the cause of the same problem with LaTeX when Markdown All in One is enabled.
I don't mean to be nosy, but...
You may need to change the title for this issue. In the current title, it looks like a problem with editor.wordSeparators, but it's actually a problem with "the language configuration word definition".

@alexr00 Given LaTeX is similar to markdown, forwarding to you to investigate if the LaTeX word definition could be improved using some new concepts that markdown is using.

@alexdima, @alexr00  I am the maintainer of vscode-latex-basics used by vscode/extensions/latex. I am pretty confident that we could use these new concepts for LaTeX word definition. If they are fine for markdown, they should be for LaTeX too.

@jlelong thanks for taking a look at this! Once you're confident of the new word definition please let me know and I'll copy it into vscode/extensions/latex. Or, feel free to make a PR that does the same I will take a look!

To really make sure the new word definition is fine, I suggest a two step approach

I make a PR in vscode-latex-basics and make a reference to it here so that people involved in this issue can test it.
Once step 1 is completed, I will make a PR against vscode. I will keep you posted.

I appreciate the thoroughness. Sounds good!

Here is the PR for the LaTeX language jlelong/vscode-latex-basics/pull/19. It would be really helpful if people using LaTeX could test this PR before it finds its way into VS Code.

@alexr00
It seems that this issue has already been fixed, so I think it's okay to close it.

authors: Yarakashi-Kikohshi alexdima alexr00 jlelong


text:
Test: Git commit editor input

Refs: #30562

[ ] macOS @isidorn
[ ] linux @TylerLeonhardt
[x] windows @Tyriar

Complexity: 5
Authors: @joaomoreno, @lszomoru
Create Issue

This milestone we have polished and merged a long standing community contribution that enables using a full size editor as a commit message input. This new experience is controlled using two new settings: git.useEditorAsCommitInput (default value is true), git.terminalGitEditor (default value is false).
Prerequisites

Open VS Code Insiders and ensure that the settings are set to their default values:

git.useEditorAsCommitInput is set to true
git.terminalGitEditor is set to false

Commit message editor

Open VS Code Insiders and open a folder/workspace that contains a git repository
Make a change to one or more files from the folder/workspace and switch to the "Source Control" viewlet
Leave the commit input empty, and click on the "Commit" button

Confirm that a new editor with the COMMIT_EDITMSG document gets opened
Confirm that while the document is opened:

Commit button is disabled
Commit input is empty and read-only. Typing a message displays a hover that the input is read-only.
Commit related commands are not shown in the Command Palette
Commit related commands are disabled in the ... -> Commit submenu in the SCM viewlet

Close the COMMIT_EDITMSG editor

Confirm that an information notification is shown that the commit operation was cancelled
Confirm that the changes were not committed

Leave the commit input empty, and click on the "Commit" button
In the opened editor enter a commit message (try single line, multi line, etc.). When done, close the editor

Confirm that the changes were committed with the provided message

Terminal integration

Open VS Code Insiders and open a folder/workspace that contains a git repository
Make a change to one or more files from the folder/workspace
Open a new integrated terminal window, and execute git commit

Confirm that your configured GIT_EDITOR is being used (ex: vim)

Close the integrated terminal window
Open Setting and set the git.terminalGitEditor setting to true
Open a new integrated terminal window, and execute git commit

Confirm that a new editor tab is opened with the COMMIT_EDITMSG document

In the opened editor enter a commit message (try single line, multi line, etc.). When done, close the editor

Confirm that the changes were committed with the provided message

Legacy functionality

Open VS Code Insiders and open a folder/workspace that contains a git repository
Open Setting, set the git.useEditorAsCommitInput setting to false
Reload the window
Make a change to one or more files from the folder/workspace and switch to the "Source Control" viewlet
Leave the commit input empty, and click on the "Commit" button

Confirm that the quick input is being shown

Press ESCAPE to cancel the operation

Confirm that the operation has been cancelled and the changes were not committed

Leave the commit input empty, and click on the "Commit" button

Confirm that the quick input is being shown

Enter a message in the quick input and press ENTER

Confirm that the changes are committed with the provided message

Cool work 👏
To be honest since 5 years I had VS Code configured as the git commit input, so I was sort of living this experience...

authors: isidorn lszomoru


text:
Source Control show list of files changes, but there is none

I freshly clone the project from BitBucker, and load the project with Visual Studio Code. The Source Control showing list of images files change and deleted.
I'd googling and tried all the possible solution, and it still doesn't resolve the issue.
P/S: The original source committed are from MacOS, and I cloned the project to my local Window OS.

@gahhon, have you opened the repository in Visual Studio or Visual Studio Code?

Hey @lszomoru, this issue might need further attention.
@gahhon, you can help us out by closing this issue if the problem no longer exists, or adding more information.

@gahhon, great observation. I have tried to clone a git repository that has a file with a : in the path and I received an error message in VS Code that originated in git
error: invalid path 'hello: world.txt'
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'

This is not an issue with VS Code but an issue with Windows. On Windows there are a set of characters that are reserved when it comes to paths, : being one of them. If you would like to contribute to this repository from a Windows machine I would suggest that you rename these files (ex: use - instead of :) so that the repository can be correctly cloned on a Windows machine.

authors: VSCodeTriageBot gahhon lszomoru


text:
Add something like editor.cursorWidth for underline cursor style

I really like the underline cursor style, however it is too thin to my liking. I suggest adding a setting like editor.cursorWidth which works for the underline cursor style to make it thicker.

This feature request has not yet received the 20 community upvotes it takes to make to our backlog. 10 days to go. To learn more about how we handle feature requests, please see our documentation.
Happy Coding!

authors: ItsSunnyMonster VSCodeTriageBot


text:
Pictures not showing in live viewer

Type: Bug
Hello. I have been using this app for a while and I have tried everything in order to see my work beside my code but it doesn't seem like it is working. everytime I look with my live preview, I cannot see my pictures I put. I can see the pictures when I open from my file but not in here. I hope you can fix it or tell me how I can fix it. Thank you
VS Code version: Code 1.74.2 (e8a3071ea4344d9d48ef8a4df2c097372b0c5161, 2022-12-20T10:29:14.590Z)
OS version: Windows_NT x64 10.0.19044
Modes:
Sandboxed: No

System Info

Item
Value

CPUs
11th Gen Intel(R) Core(TM) i5-1135G7 @ 2.40GHz (8 x 2419)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: disabled_offdirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okskia_renderer: enabled_onvideo_decode: enabledvideo_encode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: disabled_off

Load (avg)
undefined

Memory (System)
7.80GB (2.58GB free)

Process Argv
--crash-reporter-id 7a8d2e99-da9f-4323-ad5c-41dbe99b660d

Screen Reader
no

VM
0%

Extensions (11)

Extension
Author (truncated)
Version

prettier-vscode
esb
9.10.3

live-server
ms-
0.4.4

java
red
1.13.0

LiveServer
rit
5.7.9

intellicode-api-usage-examples
Vis
0.2.6

vscodeintellicode
Vis
1.2.29

vscode-java-debug
vsc
0.47.0

vscode-java-dependency
vsc
0.21.1

vscode-java-pack
vsc
0.25.7

vscode-java-test
vsc
0.37.1

vscode-maven
vsc
0.40.2

A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492cf:30256860
vslsvsres303:30308271
pythonvspyl392:30443607
vserr242cf:30382550
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263cf:30335440
pythondataviewer:30285071
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593:30376534
pythonvs932:30410667
cppdebug:30492333
vsclangdf:30486550
c4g48928:30535728
dsvsc012cf:30540253
azure-dev_surveyone:30548225
vsccc:30610678
pyindex848:30577860
nodejswelcome1cf:30587006
282f8724:30602487
gswce1:30612156
iaj6b796:30613358
f6dab269:30613381
fim-prod:30623723

You mean that it doesn't work with Live Server extension?
If yes - then recheck that you have proper config according to the extension's docs and if everything is correct then report issue in extension's repo.

This issue is caused by an extension, please file it with the repository (or contact) the extension has linked in its overview in VS Code or the marketplace for VS Code. See also our issue reporting guidelines. If you don't know which extension is causing the problem, you can run Help: Start extension bisect from the command palette (F1) to help identify the problem extension.
Happy Coding!

authors: Bozz31 IllusionMH VSCodeTriageBot


text:
Make proper deprecation of Robot Framework extensions.

I I just saw that many Robot Framework extensions (such as Robot Framework Intellisense) are deprecated in favor of the Robot Code extension.
I think this is misleading.
The most used and active extension for Robot Framework right now is the Robot Framework Language Server (I'm the current author for it), so, either those extensions should just be marked as deprecated without a favorite or they should be marked as deprecated in favor of Robot Framework Language Server...

This is fixed already.