Why does a new VSCode extension created with yeoman generator immediately not find vscode when starting debug?
Clean install of node, yeoman, and generator "code".
While I can continue to debug with this error, why isn't vscode found? Is it extraneous if debugging actually works?
Type Ctrl+` to get the console and then npm i whereupon you will get a message similar to this
Detected VS Code engine version: ^1.31.0 Found minimal version that
qualifies engine range: 1.31.0 Fetching vscode.d.ts from:
https://raw.githubusercontent.com/Microsoft/vscode/7c66f58312b48ed8ca4e387ebd9ffe9605332caa/src/vs/vscode.d.ts
vscode.d.ts successfully installed!
After that things should be hunky dory.
Related
When I am configuring the CMake for vscode,I encounter a very puzzling problem.I follow the steps of Microsoft's vscode official documentation to configure CMake for vscode,and everything is good.I can finish the 'F5' debugging operation and running the project in the vscode.
However,later while configuring vscode for cmake with "cmake.generator": "Ninja" and using the CMake:Configure command, vscode generates an error——
Unable to determine what CMake generator to use. Please install or configure a preferred generator, or update settings. json, your Kit configuration or Path variable
The following output[1] of the CMake Tools Extension indicated that it tried to find the new CMake generator but not found.
Command 'CMAKE:Configure' result in an error (No usable generator found.)
[rollbar] Unhandled exception: Unhandled Promise rejection: configure Error: No usable generator found.
I read the CMake official doucument,searched the problem in google but I can't find out why.
[1] the detailed error prompts
After installing code-oss on Manjaro Linux along with the Jupyter extension for code and jupyter-notebooks itself, the extension seems to error when I try to do anything Jupyter related inside code. If I try to create a new notebook from the command pallete, it pops up a dialog saying this:
Command 'Jupyter: Create New Jupyter Notebook' resulted in an error (command 'jupyter.createnewnotebook' not found)
Code then tells me that the extension activation failed and to open the chrome developer console for more information. This is what the chrome console then says:
extension activation failed Error: Extension 'ms-toolsai.jupyter' CANNOT use API proposal: notebookEditor. Its package.json#enabledApiProposals-property declares: but NOT notebookEditor. The missing proposal MUST be added and you must start in extension development mode or use the following command line switch: --enable-proposed-api ms-toolsai.jupyter
Initial Pop-up error
Chrome Console error
You can solve that problem by inserting"enable-proposed-api": ["ms-toolsai.jupyter"] in the start settings of vs code. So press CTRL+ALT+P -> "Preference: Configure Runtime Arguments" then insert the upper line. After that restart vscode.
Had the same problem and found out this is happening because of the open source version of code - OSS. It does not have the proper config in the product.json.
The accepted solution to add to Runtime Arguments unfortunately didn't work on Arch.
Easiest solution for me was to install code-features from AUR.
You can find more info on arch wiki site
Or directly on microsoft docs regarding oss code issues.
The solution to add "enable-proposed-api": ["ms-toolsai.jupyter"] to the runtime of vscode didn't work for me on Arch linux. But when I started vscode from the command line using the argument "--enable-proposed-api ms-toolsai.jupyter" the problem was solved. So I created a custom desktop launcher for this:
Fist, copy the desktop launcher to your applications folder
$ cp /usr/share/applications/code-oss.desktop ~/.local/share/applications/.
Then edit the new file:
$ nano ~/.local/share/applications/code-oss.desktop
Now add "--enable-proposed-api ms-toolsai.jupyter" to both of the Exec lines like so:
[Desktop Entry]
Name=Code - OSS
Comment=Code Editing. Redefined.
GenericName=Text Editor
Exec=/usr/bin/code-oss --enable-proposed-api ms-toolsai.jupyter --unity-launch %F
Icon=com.visualstudio.code.oss
Type=Application
StartupNotify=false
StartupWMClass=Code
Categories=TextEditor;Development;IDE;
MimeType=text/plain;application/x-code-oss-workspace;
Actions=new-empty-window;
Keywords=vscode;
[Desktop Action new-empty-window]
Name=New Empty Window
Exec=/usr/bin/code-oss --enable-proposed-api ms-toolsai.jupyter --new-window %F
Icon=com.visualstudio.code.oss
I restarted my computer and the problem was solved.
I am junior QA Tester, started working with Cypress and IDE Visual Studio, after updating Cypress 5.2.0, I got a strange error like the following:
It looks like this is your first time using Cypress: 5.2.0
✖ Verifying Cypress can run /Users/viktoriiahanke/Library/Caches/Cypress/5.2.0/Cypress.app
→ Cypress Version: 5.2.0
Cypress failed to start.
This is usually caused by a missing library or dependency.
The error below should indicate which dependency is missing.
https://on.cypress.io/required-dependencies
If you are using Docker, we provide containers with all required dependencies installed.
----------
Command was killed with SIGKILL (Forced termination): /Users/viktoriiahanke/Library/Caches/Cypress/5.2.0/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=563
----------
Platform: darwin (19.6.0)
Cypress Version: 5.2.0
I have already tried to delete Cypress and install it with npm from the beginning, but Cypress itself is working, when I download it manually , but when I try to start it in console or in Visual Studio Console it is not opening, writing me that I miss dependencies like above.
Did anyone have such problem before?
Run this command in the terminal export NODE_TLS_REJECT_UNAUTHORIZED=0
and then try installing again.
I think it had been updated from a previous version, 3.1.3. Go into cache and delete all versions of cypress then re-install.
Maybe that there are missing some vital folders/files like integration, cypress.json... Try to run the 'npm install' command in the terminal for installing the dependencies.
Also, maybe if you start from an existing project, it will be fine (run npm install command also).
I keep using vscode debug for long time. But it began to fails to use debug from yesterday.
It reports that The terminal process failed to launch: A native exception occurred during launch (File not found: ).
I can use powershell in terminal.
I have tried solution in (https://code.visualstudio.com/docs/supporting/troubleshoot-terminal-launch), but none of them works.
Code -version: 1.47.3
Operating System version: windows 10 1909 build 18363.959
all extensions:
albert.TabOut
christian-kohler.path-intellisense
CoenraadS.bracket-pair-colorizer-2
Equinusocio.vsc-community-material-theme
Equinusocio.vsc-material-theme
equinusocio.vsc-material-theme-icons
eryouhao.brackets-light-pro
formulahendry.code-runner
formulahendry.terminal
Gruntfuggly.todo-tree
HookyQR.beautify
James-Yu.latex-workshop
kisstkondoros.vscode-gutter-preview
manasxx.background-cover
marlosirapuan.nord-deep
MS-CEINTL.vscode-language-pack-zh-hans
ms-python.python
ms-python.vscode-pylance
ms-vscode.cpptools
naumovs.color-highlight
niudai.vscode-zhihu
nnthink.aixcoder
redhat.java
skacekachna.win-opacity
sldobri.nord-5-stars
TabNine.tabnine-vscode
VisualStudioExptTeam.vscodeintellicode
vscjava.vscode-java-debug
vscjava.vscode-java-dependency
vscjava.vscode-java-pack
vscjava.vscode-java-test
vscjava.vscode-maven
vscode-icons-team.vscode-icons
wix.vscode-import-cost
yzhang.markdown-all-in-one
zhuangtongfa.material-theme
setting.json:
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.exe"
In my case this problem arising after updating VS Code version to 1.54.3 on Ubuntu 18.04.
This problem is resolved by restarting VS Code after the update.
Yep, that's kinda what my problem was...PS had been blocked at a system-admin level.
Make sure that you can actually run PS from the command-line or start window.
Win10 popup
I fixed it by change "terminal.integrated.inheritEnv" to false in setting.json.
I also had the same issue and asked the question one week before yet didn't get solution.
here is link of my question
[link]Visual Studio (VS-code) code terminal is failed to launch
1 solution i got:
the issue arises when you delete some of it's files before by mistake and you don't know try to remember that or simply recover your pc to 3 weeks ago atleat so all files will be placed suitably.
I had the error. To fix it, I looked at all the terminal settings in VSCode and checked out the ones that weren't set to the default value. Eventually, I found that the path to my PowerShell had changed to the preview version I had installed. Reverting this to its default got it working again. Hope this helps someone.
I am new to python and writing my first python file using Visual Studio Code. Till yesterday the code was working fine. But today it is starting to give ModuleNotFoundError. I double-checked the package and the package is there under lib folder of the virtual environment. Moreover, IntelliSense is also working fine, whenever I write import it shows the requests module in the available list. I am facing problems with IntelliSense also, as sometimes it stops working for no reason.
The major change that I did before executing the code is the integration of GitLab with my project.
Python Version: 3.6.2
Operating System: Windows
Git Version: 2.23.0
Pylint Version: 2.3.1
pip Version: 19.2.2
Requests Version: 2.22.0
Pytest Version: 5.1.1
Enabled Extensions:
Npm
Npm Intellisense
Ayu
Code Runner
AYU
Markdownlint
Predawn Themekit
Python by Microsoft
Can anyone have gone through with the same problem? Please help me to resolve this issue.
Attachments
Issue resolved I was running it using Ctrl+Alt+N (code-runner shortcut to run a project)which was creating this issue. But running the file in terminal using Run Python File in Terminal (option in the context menu when we do right-click in source .py file) giving me the expected result without any error.
Then I googled for how to alter this behavior so that I can get the same results by using Ctrl+Alt+N as well.
I found that; I need to add the following script under user's settings.json.
"code-runner.executorMap": {
"python": "h:\\practice\\virtualenv\\Scripts\\activate.bat && python -u"
}
Here is my complete user's settings.json
{
"workbench.colorTheme": "Predawn",
"workbench.iconTheme": "ayu",
"window.zoomLevel": 0,
"code-runner.executorMap": {
"python": "h:\\practice\\virtualenv\\Scripts\\activate.bat && python -u"
}
}