Open alog243 opened 5 months ago
Looks like this is the same as https://github.com/LOLINTERNETZ/vscodeoffline/pull/60
I think this passes now with PR #60 merged, but I don't use the extensions to triple check
python3 sync.py --extension-name ms-vscode.cpptools --update-extensions --prerelease-extensions
VSCode ver: 1.85.2 C/C++ Extension (ms-vscode.cpptools) ver: 1.18.5
https://github.com/microsoft/vscode-cpptools/blob/b742a191ee543a1d8df255a2420a5bfe33672e2d/Extension/src/LanguageServer/extension.ts#L1293
In this function preReleaseCheck, the extension performs an API query to the marketplace to see if a prerelease version of the extension is available. On vscodeoffline this returns a 500 server error wrapped in json. Since node-fetch doesn't treat 3xx-5xx return codes as exceptions, this isn't caught and the error json object causes an unhandled exception (line 1295 above), which prevents the C/C++ extension from loading.
This can be fixed by returning an empty json object for this endpoint (the query parameters can be seen starting on line 1281).