VSC Remote SSH - How to fix reconnection problems? - visual-studio-code

When using VSC Remote SSH, I am constantly getting the error "Cannot reconnect. Please reload the window.". Upon clicking "Reload Window", the window reloads and I receive the same error.
Sometimes I am also getting the following notification: "The terminal process failed to launch: A native exception occurred during launch (forkpty(3) failed)."
More errors showing here:
screenshot
I tried to find the solution but nothing worked for me, any suggestions? I tried:
Reinstalling extension
Deleting the VS Code + cache directory on the server
Restarting server
Update 17-01: Today it worked fine for around 2 hours. It randomly stopped working while I was typing a few lines of code without doing something else like saving, adding or delete files. The message is still te same and did not found any solution yet.

I had this same issue recently, for me it looks like disabling the wix.vs-code.import-cost extension remedied the issue.
This is probably because I am using private registries for npm packages and that could easily cause issues if attempting to load the private modules from any public source, but I didn't really look into it, so this is just my best guess.

Related

SignatureIntegrityCheckFailed error when downloading VS Code extensions

I just formatted my computer and installed VS Code, but when I went to download some extension, an error appeared and asked to check the "log", and then an error appeared in the console.
image of the error that appears in the console
I tried searching the program files but found nothing.
2023-02-08 19:01:39.542 [error] SignatureIntegrityCheckFailed:
Signature: SignatureIntegrityCheckFailed
at yt.download (vscode-file://vscode-app/c:/Users/User/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/code/electron-browser/sharedProcess/sharedProcessMain.js:62:17985)
at async $.h (vscode-file://vscode-app/c:/Users/User/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/code/electron-browser/sharedProcess/sharedProcessMain.js:90:171351)
Just a workaround. There is an issue raised but long inactive issue
Try this, this worked for me after all the other struggle with this bug.
"Programs\Microsoft VS Code\Code.exe" --ignore-certificate-errors
The security part of this is that, your trust store or at least the one VS code is using is not able to verify the authenticity. So be mindful of the risk involved.
So basically, we are working around this.

Why am I getting an error when loading webviews in VS Code?

I'm using a portable install of VS Code 1.56.1 on Windows 10. Whenever open an extension from the marketplace, I get the following error:
Error loading webview: Error: Could not register service workers: TypeError: Failed to register a ServiceWorker for scope ('vscode-webview://extensioneditor/') with script ('vscode-webview://extensioneditor/service-worker.js?platform=electron&id=extensionEditor&vscode-resource-origin=https%3A%2F%2FextensionEditor.vscode-webview-test.com'): ServiceWorker cannot be started.
Same thing happens for other things using webviews, with a slightly different path (like VS Code release notes). I'm able to install plugins and view the Feature Contributions tab, but I cannot view the Details and Changelog tabs.
Any thoughts on what could be causing this? This is on a managed machine where security settings might be changing. I'm using a portable install because my installed version stopped working out of the blue last week and this was supposed to be the workaround until that was figured out.
I was getting the same error, it looks like an issue introduced on version 1.56.0.
For me the fix was running VS Code without elevated permissions.
I always run as administrator and running without it fixed the issue for me.
I had this problem, in terminal use code . --no-sandbox
Updating python3 to the most recent version may also help.

A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found

I tried internet search on this issue and it is very common with many suggestions. The problem started with an update to VS2019 in which I paused because my projects in VSCode were breaking.I did a system restore and when I tried to start VSCode I got a message saying my installation was corrupt. So I reinstalled to the latest version and now get this error.
A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found...
I found 3 extensions that needed updating so I do so but did not fix this problem. Do not know if I need to update the .Net Core since it looks like a version mismatch. It seems these updates are wreckless since they always cause thing to go wrong.s
If you are facing this problem, it means you are using Windows.
This official microsoft live share github page explains how to fix the issue: https://github.com/MicrosoftDocs/live-share/issues/102
Especially, check out this comment: https://github.com/MicrosoftDocs/live-share/issues/102#issuecomment-366509735
make vscode is up to date
uninstall live share from vscode
close vscode completely
restart vscode as administrator
reinstall live share
I should add:
close completely vscode and restart it

Eclipse does not recognize my changes in src folder, throws the same error

I'm having a hard time using eclipse because of the following issue.
It goes like this. I'll code and try to run it. Then, it will throw some errors (of any kind). And so, after I have changed a part of the code, comment out which codes I suspect makes the error, or delete something, I then restart the websphere application server in order to republish my work. Next is to test my work using SoapUI then all of a sudden eclipse throws an error which is the same as before. I've tried to search in here answers to this questions but it involves codes which don't need in my project and also answers that I can't understand well (since I am very new to programming). However, I have found a way to resolve this but it's very inconvenient. To be able for eclipse to detect changes in the src folder, I should restart eclipse after editing my codes then remove my project in the server, start the server and then publish my work in websphere all over again. It solves my problem but I do all of these stuff every now and then even if I only comment out a single line in the code. What I want is to avoid doing this process of resolving the issue since it consumes so much of my time whenever I republish the project in the server.
Can somebody help me with this? Any suggestions would be very helpful. Thanks a lot!
It is a bit strange that you need to restart eclipse. The normal way would be to just re run your application server.
Try only he 3 second steps you mentioned (remove my project in the server, start the server and then publish my work in websphere) and if that works try again without removing the project. Just restart the servers.
And let us know if that worked!

Eclipse EGit pushing latest commit hangs plink.exe

Yesterday I setup EGit and PuTTY so I can share my latest changes to the code to my RPi which then packs my binary into a executable jar, and with quiet alot of extra work, I got it working to some extent, I could successfully push my local resipotory to github, and my RPi could fetch the latest commit if needed. But I still had some minor problems with my RPi executing my code and compiling etc.
However, today everything suddenly stopped working, I could no more push my local resipotory to github for whatever reason and I have just not been able to figure it out (the funny thing about ALL this is that I thought it would be very beneficial if my RPi could stay up to date with my latest code so I wouldn't have to manually export my code to the RPi by remote desktop and dropbox, but it turned out to be even more complicated than I thought it was).
The most annoying thing is that it was working just fine yesterday, I did change a few things in my project within eclipse but other than that, everything should've been the same. Basically EGit first told me that the server host key was not cached. And I resolved that by calling plink git#github.com from the command line. After that I was left with another problem: PuTTY Fatal Error: Disconnected: No supported authentication methods available, and after Googleing the problem for a good hour or so, I found out that Pageant had apparently no private key in the Pageant key list. So I had to convert the id_dsa private key generated by eclipse to a PuTTY Private Key File, which resolved that issue, after launching EGit again, I first thought it would work, but oh no! I've never been so wrong in all my life. I tried to push my local resipotory to github, but it got stuck at getting remote branches information, so I tried to cancel it. But it didn't work, I couldn't close the wizard due the process had to be cancelled first. So I had to manually TERMINATE the plink.exe process to close the wizard.
I would be so thankful if anyone could help me out here. Thanks in advance!