VScode Error: extension failed XHR Failed (Ubuntu Virtual Machine)

In the process of learning Linux embedded development, I encountered the following problems: after installing VS code in the Ubuntu virtual machine, it need to install appropriate plug-ins. At this point, vscode fails to expand XHR Failed, as shown in the figure:

And press the F1 key inside Vs code to open Developer:Toggle Developer Tools, enter the Console to query the reason, The error shown in the figure below appears (That is, Ubuntu system will point the domain name to the specified IP solve this problem):

After searching the Internet for many solutions, the following operations can solve the problem:

1. Open the hosts file in the Ubuntu terminal

sudo gedit /etc/hosts

2. Add the corresponding relationship between IP and domain name in the file as follows, and save the hosts fileļ¼š

13.107.42.18 marketplace.visualstudio.com

3. Restart Ubuntu.

Read More:

Leave a Reply

Your email address will not be published. Required fields are marked *