Questions tagged [visual-studio-code]

Visual Studio Code (VS Code) is a text editor for Linux, Mac, and Windows. Use this tag ONLY IF your question is ABOUT it, not just because you happen to be using it. You can also use this tag for unofficial binaries of the open source portion of the code (such as VSCodium). It includes support for debugging, Git, extensions and rich development experiences such as intelligent code completion. It is mainly developed by Microsoft, and built on Electron.

Filter by
Sorted by
Tagged with
0 votes
0 answers
4 views

c# dev kit is not compatibale with windows 7

I installed Vs Code on my old PC which can't support win 10 so I had to download version 1.70.2. now I want to practice c# on it but the extensions "dev kit" and "Intellicode for c#&...
49 votes
7 answers
39k views

How to use VS Code as merge and diff tool in SourceTree?

This question and some others discuss how this could work on a Mac, but I couldn't find documentation from Microsoft or Atlassian on a way to do this on Windows without trying to make it the global ...
19 votes
3 answers
5k views

VSCode - Is it possible to always show the current function name or scope somewhere at the top?

It would be very useful for editing JavaScript or TypeScript to always see the current function name at the top (like Xcode does for example). Sometimes when editing a long function (or having larger ...
27 votes
9 answers
57k views

why is my github copilot not working all of a sudden?

I have been using copilot for a while now, and one fine day on opening VSCode this error appeared. "[ERROR] [default] [2022-04-09T08:38:10.995Z] GitHub Copilot could not connect to server. ...
0 votes
0 answers
35 views

"code" command does not work in Powershell

"code" command for VSCode does not work on Windows Have freshly reinstalled VSCode Confirmed permission of the scripts: https://learn.microsoft.com/en-us/previous-versions//bb613481(v=vs....
0 votes
2 answers
35 views

How does VS Code recognize URLs in text (strings)?

I find that VS Code does really good URL recognition / extraction- better than any methods found in the internet. Since VS Code is opensource, where can I find the code? Probably regex rules. I ...
8 votes
2 answers
639 views

vscode + vim plugin: CTRL+P no longer works

I've used vscode with the vim plugin for years. All of a sudden I can no longer open files using CTRL+P. Looks like the plug-in intercepts this combination and moves the cursor up instead.
6 votes
5 answers
7k views

How to recognize env variables in typescript when using vite?

export const EnvironmentProvider: React.FC<EnvironmentProps> = ({ children }) => ( <EnvironmentContext.Provider value={{ APP_NAME: import.meta.env.VITE_APP_NAME, GQL_URI: import....
5 votes
2 answers
5k views

Why did my git user.name and user.email mysteriously get deleted?

I tried checking in my code tonight in Visual Studio Code and saw this message. I first staged my changes then hit "Commit" like I always do! QUESTION 1 - Why would these values be suddenly ...
1 vote
1 answer
137 views

VSCode python module debug with nested directories

I am trying to debug a module in a directory structure as follows cwd ├── project_directory | | __init__.py | ├──dir1 | ├── __init__.py | ├── module1.py | ├──dir2 | ├── __init__....
5 votes
2 answers
4k views

Intellisense terminal on vscode

How can I enable intellisense in the terminal in vscode? When I start typing, automatically hints come out on the side. I post an image as an example(In this image, I type with and alongside in light ...
0 votes
1 answer
12 views

VS code multiline quick open menu

Is there an extension or any other ways to display it in 2 or more rows?
-1 votes
0 answers
16 views

Python Graphic code not executing in VS Code

I am coding a program in Python and using tkinter as follows in VS Code. Earlier it used to execute just fine but when I try to execute it right now in VS Code it doesn't do anything. At the same time ...
0 votes
0 answers
31 views

I am receiving 'An error occurred reading file.' error in Bicep

User I used the following code in main.bicep: var groupAndPrincipalIDs = loadJsonContent('../groupAndPrincipalIDs.json') I have 4 pipelines which one of them is creating the 'groupAndPrincipalIDs....
0 votes
0 answers
25 views

ModuleNotFoundError when trying to debug a test

I am trying to debug a failing test method in VS Code but when I use the Debug Test action from the Testing sidebar or the context menu for the test method, it fails with the following error (found in ...
0 votes
0 answers
8 views

Weird box around text in problem tab vscode

Weird text selected box in problem tab. Try changing font, profile but nothing changed. Happened when i type something on keyboard, i think its a shortcut or something like that but i dont know how to ...
22 votes
13 answers
32k views

Could not locate .NET Core project. Assets were not generated

I just started learning C# a couple hours ago, but have since run into this error. Ctrl + Shift + P .NET:Generate Assets for Build and Debug But when I click it, an error pops up bottom right of the ...
0 votes
0 answers
16 views

Autocomplete selection issue on VSCode

I am using VS Code for my React (with typescript) app. Whenever I use autocomplete and enter the suggested option, VS Code selects the value (kind of), instead of showing me the typescript values for ...
-1 votes
0 answers
13 views

Incomplete debug console in VSCode while programming with flutter

I was told to fix a flutter web program made by someone else, as far as I know it is a web app flutter made using getX, strangely the debug console seems to be incomplete, it didn't show the usual ...
0 votes
1 answer
63 views

VSCode equivalent of Chrome's "Pretty Print" / "Format Code" functionality for debugging TypeScript/JavaScript code?

When debugging JavaScript code, you regularly encounter minified code. This code is hard to read for humans. To still "make sense" of the code while debugging, Chrome's debugger ships with a ...
2 votes
3 answers
2k views

VSCode, Failed to set up socket for dynamic port forward to remote port: connect ECONNREFUSED

I am trying to connect my VSCode to a raspberry pi4 via the Remote - SSH extension by Microsoft, but I get a ECONNREFUSED error every time. The error log: [14:49:20.954] Starting forwarding server. ...
22 votes
7 answers
26k views

VS Code terminal doesn't recognize PATH variables

I added a directory to my PATH but the terminal in my VS Code doesn't recognize a command(exe) that I'm trying to run from that directory. The terminal uses cmd not power shell. What am I missing?
-3 votes
0 answers
25 views

when i use vscode debug golang,some variable can't be seen,please help me

enter image description here i don't know the message:"(unreadable non-zero length array with nil base)" and "(unreadable could not find loclist entry at 0xbf3ed3 for address 0x2b1dd5a)&...
2 votes
2 answers
3k views

visual studio code pylance search folders

I have a project with some python in it - the python is part of a larger thing - there are several programs in several directories inside a root git - and there is some common code in yet another ...
6 votes
5 answers
3k views

Python unittest with test/ and src/ not finding src modules

I have a simple directory structure: proj/ src/ __init__.py foo.py bar.py test/ __init__.py test_foo.py test_foo.py import unittest import sys sys....
2 votes
2 answers
39 views

Handling '0 references' for php callbacks in visuel studiio code when

When editing wordpress code in Visual Studio Code, if I have a function definition and than I use it as a callback for a call to add_action or add_filter than because its used as a string its not ...
1174 votes
34 answers
1.1m views

"code ." is not working in on the command line for Visual Studio Code on OS X/Mac

The command code . doesn't work in this manual. All the other steps before that worked. How can I call the Visual Studio Code in an OS X terminal? pwd /Users/mona/nodejs/myExpressApp code . -bash: ...
0 votes
1 answer
51 views

unable to import azureml in vscode

I've installed python 3.8, from vscode terminal I created an env and seem to have successfully installed azureml as below: C:\Python38\python.exe -m venv tempml tempml\scripts\activate pip install ...
0 votes
1 answer
25 views

How to automate the template generation for Azure Logic App (Consumption)

I have an Azure Logic App (Consumption). I have Dev version and I would like to deploy it to test and then to production. So far I've been able to: export the template from the portal decompile it ...
-1 votes
0 answers
4 views

On Mac, I want "code ." to create a new dock entry

With project-1 open, I want terminal code . to launch project-2 in a new window (it does), and a new dock entry. I have 2 Mac machines. One exhibits the "New Dock Entry" behavior I want, ...
0 votes
0 answers
13 views

When build android ran into in_app_purchase_android:compileDebugUnitTestJavaWithJavac FAILED

I develop flutter with vscode, and use the in app purchase plugin. when I build the project, I ran into Error like this: Task :in_app_purchase_android:compileDebugUnitTestJavaWithJavac FAILED warning:...
-2 votes
0 answers
18 views

Does anyone know how I can remove this setting so it doesn't appear in my field of vision? [closed]

How can I remove this setting so it doesn't appear in my field of vision? I tried to remove it, but I always unconfigure other functions. When I'm typing the codes in my studies, I end up being caught ...
1 vote
1 answer
33 views

Where can I find where configuration-like information for VS Code is stored?

In VS Code, there are several places that store user settings. I am aware of at least settings.json state.vscdb the Settings button on the left panel. If I am looking for a setting, where should I ...
0 votes
1 answer
884 views

dotnet run command not listening on https

I am running a simple ASP.Net program on Windows and when I try to run the 'dotnet run' command, I can see it's listening only on http but not on https. I have also executed 'dotnet dev-certs https --...
-1 votes
0 answers
12 views

how to stop run dev server automatically when each key pressed in vscode?

How to stop run dev server automatically when each key pressed in vscode? I pressed some key binding when code? But I don't remind exactly what keys I pressed. I've searched from google about it. But ...
0 votes
3 answers
489 views

Where do code snippets reside in Visual Studio Code?

The only C/C++ extension I have is the official one from Microsoft. I do not have any other snippet/intellisense/autocompletion extension. See below all the extensions loaded: In trying to create ...
0 votes
0 answers
6 views

C# & VS Code - Is it possible to "Run Test and Analyze Coverage" from the menu?

On the testing menu above there's only a single option to run test Run (Default). Is there a way to create a new option like Run and Capture Coverage? If I click on Configure Test Profiles it only ...
83 votes
6 answers
123k views

How to install VS code extension manually?

I am not able to download any extension via VS Code on my office system due to the proxy. Is there a way that I can do it manually by downloading and placing the downloaded files at the right place?
193 votes
49 answers
896k views

Crbug/1173575, non-JS module files deprecated. chromewebdata/(index)꞉5305:9:5551

I just created a new project and have run it for the first time using F5 or Ctrl + F5. The result in Chrome is: The site can't be reached err_connection_refused I checked the option at the ...
0 votes
0 answers
9 views

Angular library with Storybook debugging in vscode not working

There are a lot of articles online about debugging storybook, Angular and vscode but none quite tackle my issue (I think) but I have tried all the recommended changes in them anyway without any luck. ...
0 votes
0 answers
1k views

How to enable openMP in visual studio code

I am trying to enable openMP in visual studio code. I could not find a guide to do this. Any help? I am trying to run a code that looks like this: //TIME LOOP: for (int nt = 0; nt < ...
0 votes
1 answer
31 views

How do I navigate VS Code debugger variables without the mouse?

I want to drill down into the variables shown during debugging in VS Code using the arrow keys or indeed anything but the mouse. I read the debugging docs.
0 votes
1 answer
12 views

When debugging in VS Code with an emulator, can I pin the emulator to a panel in VS code (rather than have it as a separate window?)

Is there a way to pin the emulation window to visual studio code, as a side panel (a bit like how you can have a 'widget inspector' panel). So I can view the UI of my flutter application. Currently I ...
0 votes
0 answers
9 views

run the python program using existing conda environment as a python interpreter

Within VScode, I am using an existing conda environment to run the Python program. I use the "python: select interpreter" to select an existing conda environment. After running, the code ...
2 votes
1 answer
32 views

Is it possible to swap the order of Code Action menu items in VS Code?

Is it possible to configure the order of Code Action menu items in VS Code? If not, can I somehow prevent Copilot from adding Code Action menu items while keeping Copilot itself enabled? I have zero ...
0 votes
1 answer
36 views

Why isn't the symbols.hidesExplorerArrows VS Code setting working for me?

I don't know in which version VS Code (currently I'm on version 1.82.2) deprecated this setting "symbols.hidesExplorerArrows": false, this was for hiding the arrows on the explorer pane. I ...
21 votes
8 answers
1k views

How can I use the keyboard to focus on the git commit message input in VS Code?

Is there any way to focus to this input by keyboard rather than mouse click in Visual Studio Code?
2 votes
2 answers
92 views

When using a Conda environment, VS Code terminal, and the Python extension (v2023.16), a "." is inserted to the PATH env var

I'm trying to use conda, python with VS Code. The shell I'm using in the integrated terminal is PowerShell. Everything works well in windows terminal, but after I relaunch vscode terminal, every conda ...
0 votes
0 answers
17 views

How to stop my jupyter notebook to print the color ansi code with the variable output

I am using Jupyter notebook v2023.8.1002501831 with VsCode v1.82.2. Every time I attribute a value to a variable, the default output of a variable also prints the ANSI colors: I want the output of ...
0 votes
0 answers
23 views

Using VSCode, how do I navigate to my robot file when I F12 or command click a python def

Description : As a user of PyCharm, when I perform a command click of a def, pycharm loads up the robot file that uses that function. But in VSCode, when I F12 or command click a python def, it does ...

1
2 3 4 5
1136