C/C++ extensions fail to install
From @csteres-cpi on May 5, 2017 1:14
- VSCode Version:
Version 1.12.1 Commit f6868fce3eeb16663840eb82123369dec6077a9b Date 2017-05-04T21:21:43.120Z Shell 1.6.6 Renderer 56.0.2924.87 Node 7.4.0
- OS Version: Ubuntu (note this is running in a VirtualBox guest VM under Windows 10) % uname -a Linux CSteresUbuntu32 4.4.0-77-generic #98-Ubuntu SMP Wed Apr 26 08:33:44 UTC 2017 i686 i686 i686 GNU/Linux
Steps to Reproduce:
- Installed fresh copy of VScode using .deb package
- Installed C/C++ extensions 0.11.0; restart vscode
- When VScode starts up it tries to update dependencies; sometimes if fails during downloadPackages (varies as to which package it fails on:
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Linux)' (6972 KB) .................... Done! Downloading package 'ClangFormat (Linux)' (731 KB) .................... Done! Downloading package 'Mono Framework Assemblies' (4751 KB) ....................Failed at stage: downloadPackages Error: read ECONNRESET at exports._errnoException (util.js:1022:11) at TLSWrap.onread (net.js:572:26)
Finished
3b: sometimes it manages to download all four package dependencies but fails on the install of one of them, for example:
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Linux)' (6972 KB) .................... Done! Downloading package 'ClangFormat (Linux)' (731 KB) .................... Done! Downloading package 'Mono Framework Assemblies' (4751 KB) .................... Done! Downloading package 'Mono Runtime (Linux / x86)' (1420 KB) .................... Done!
Installing package 'C/C++ language components (Linux)' Installing package 'ClangFormat (Linux)' Installing package 'Mono Framework Assemblies' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
- In addition to this, the C/Cpp Language Server output shows errors:
[6:11:53 PM] Connection to server is erroring. Shutting down server. [6:11:53 PM] Connection to server is erroring. Shutting down server. [6:11:53 PM] Connection to server is erroring. Shutting down server.
Copied from original issue: Microsoft/vscode#25960
@csteres-cpi We don't know yet why you're experiencing download/install failures, and a significant amount of other users are failing as well, so it's something we need to investigate more or provide some additional bundled .vsix link. However, the language server processes for C++ won't run on 32-bit Linux, so our extension wouldn't work for you even if you did download it successfully, unless you only intend to use the debugger.
Also getting the same error:
Downloading package 'C/C++ language components (Windows)' Failed at stage: downloadPackages
Error: read ECONNRESET
at exports._errnoException (util.js:1022:11)
at TLSWrap.onread (net.js:572:26)
Finished
Windows 7 64-bit
I got the same error.
vscode: 1.12.2 windows 10 x64 version 1703
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
me too
Updating C/C++ dependencies... Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
I also face this error. This error show every time the VSCode startup.
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
me too
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done!
Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done!
Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)'
Failed at stage: installPackages
Error: end of central directory record signature not found
Finished
me too
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4663 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Warning: File 'C:\Users\iuuni.vscode\extensions\ms-vscode.cpptools-0.11.4\bin\Microsoft.VSCode.CPP.Extension.exe' already exists and was not updated. Failed at stage: installPackages Error: invalid local file header signature: 0x16d537e7
Finished
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' (4922 KB) ............. Failed. Retrying...(4922 KB) .................... Done! Downloading package 'ClangFormat (Windows)' (905 KB) .................... Done! Downloading package 'Visual Studio Windows Debugger' (12081 KB) .................... Done!
Installing package 'C/C++ language components (Windows)' Failed at stage: installPackages Error: invalid central directory file header signature: 0x3411450a
Finished
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' Failed. Retrying... Failed. Retrying... Failed. Retrying...Waiting 8 seconds... Failed. Retrying...Waiting 16 seconds... Failed. Retrying...Waiting 32 seconds... Failed at stage: downloadPackages Error: read ECONNRESET at exports._errnoException (util.js:1022:11) at TLSWrap.onread (net.js:572:26)
Finished
The failure rate from these download errors is pretty low and some people report it working after retrying later, but we're still not sure why users are hitting this and we're investigating using different download mechanisms to improve the success rate.
I've same problem for days.....
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' Failed. Retrying... Failed. Retrying... Failed. Retrying...Waiting 8 seconds... Failed. Retrying...Waiting 16 seconds... Failed. Retrying...Waiting 32 seconds... Failed at stage: downloadPackages Error: connect ETIMEDOUT 104.115.242.199:443 at Object.exports._errnoException (util.js:1022:11) at exports._exceptionWithHostPort (util.js:1045:20) at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
Finished
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Linux)' (7208 KB) .................... Done! Downloading package 'ClangFormat (Linux)' (770 KB) .................... Done! Downloading package 'Mono Framework Assemblies' (4751 KB) .................... Failed. Retrying...(4751 KB) .................... Failed. Retrying...(4751 KB) .................... Done! Downloading package 'Mono Runtime (Linux / x86_64)' (1450 KB) .................... Done!
Installing package 'C/C++ language components (Linux)' Failed at stage: installPackages Error: end of central directory record signature not found
Finished
Updating C/C++ dependencies...
Downloading package 'C/C++ language components (Windows)' Failed. Retrying... Failed. Retrying... Failed. Retrying...Waiting 8 seconds... Failed. Retrying...Waiting 16 seconds... Failed. Retrying...Waiting 32 seconds... Failed at stage: downloadPackages Error: connect ETIMEDOUT 23.219.34.138:443 at Object.exports._errnoException (util.js:1050:11) at exports._exceptionWithHostPort (util.js:1073:20) at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1097:14)
Finished installing dependencies
If the extension is installed offline (using vsix) what are the steps to update the language components?
@kubaroth It's not recommended to install the .vsix offline. You should install the .vsix online with a machine with a matching OS and then zip/tar the installed folder and unzip the installed folder to the extensions folder on the offline machine. Are you able to do that? If not, you'd need to open the package.json to find all the runtimeDependencies you need to manually download and unzip into the extension folder on the target machine and then add an install.lock file and maybe chmod to make the binary files executable.
Thanks, I did try the latter - manual download but I had no luck. As I'm still not familiar with the process I wasn't sure if all the dependencies should be copied in the ./bin directory. Does the package.json specifies the exact destination? I will try the former solution as well, but I'm afraid It may not work as the offline machine runs different Linux distro.
@kubaroth The files should be unzipped into the main extension directory. The zip files have the folders inside them already, such as bin. Different Linux distros should be acceptable for the 1st solution as long as the bitness matches.
@csteres-cpi We're shipping a offline .vsix option with all the OS dependencies pre-included with our next update (0.14.4) so people can just download/install that if they're having problems downloading/installing the dependencies via the "online" installer. We're using https://github.com/Microsoft/vscode-cpptools/issues/298 to track that.
Fixed with 0.14.4. Offline installers are at https://github.com/Microsoft/vscode-cpptools/releases .