cancel
Showing results for 
Search instead for 
Did you mean: 

STM32CubeIDE Extension Stuck in "Infinite Loading" and Fails to Recognize CMake Projects

LiHua
Associate II

When opening a project directory in VS Code, the STM32CubeIDE for Visual Studio Code extension gets stuck in an infinite loading state (as shown in the screenshot below).

LiHua_0-1771511437856.png

Symptoms:

  • "Go to Definition" does not work.

  • The Build Analyzer view does not appear.

  •  clicking the "Build" button still triggers a successful compilation.

  • Most dependent extensions, such as STM32Cube CMake Support, remain inactive

LiHua_1-1771511614227.png

Here is the log output from STM32Cube Core during the failed loading:

LiHua_3-1771511803828.png

I discovered that if I completely disconnect my PC from the internet before launching VS Code, the extension reports a network error but then successfully initializes after a short period. Once initialized offline, all features (including Go to Definition) work perfectly.

Here are the logs from a successful (offline) launch:

LiHua_2-1771511706245.png

My computer’s network connection is working fine. I tested this URL in the VS Code command line —developer.st.com/bundles/BundleRepositoryIndex.json — and it downloads normally. I’ve tried both the latest version (3.7.0) and the older version (3.6.4), but neither fixed the issue. Right now, the only way I can open it is by disconnecting my computer from the network. Is there any way to solve this problem?

 

 

12 REPLIES 12

@Julien D wrote:

Hi @LiHua,

Does "STM32Cube CMake Support" never activate even if you don't have any folder/workspace opened in VSCode ?


No, this extension only fails to activate when I open an STM32 project. If I don’t open any folder, or if I open a folder that does not contain an STM32 project, it activates immediately:

ok_1.png

I also tried creating a new STM32 project with the MCU STM32G431VBT6. The first time I opened it, the extension activated successfully and quite quickly:

yes_1.png

first_open_1.png

However, after closing VSCode and opening it again, it gets stuck during activation on the STMicroelectronics.stm32cube-ide-build-cmake extension:

failed_1.png

Julien D
ST Employee

Do you see any interesting information, such as errors, in the Developer Tools console during the startup period?
(See Help > Toggle Developer Tools > Console tab)

Feel free to send it to me via private message if you consider the content should not be posted here.

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Thank you for your suggestion.

In VSCode Developer Tools, I found the following two warnings:

data-collector/detect-st-user-service: DNS lookup failed for [obfuscated-url]: Error: getaddrinfo ENOTFOUND [obfuscated-url]
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:111:26)

and

data-collector/detect-st-user-service: DNS reverse lookup failed: getHostByAddr ENOTFOUND 192.168.1.8

So I changed my computer’s DNS setting from manual IPv4 (8.8.8.8) to DHCP, and now all the extensions can open and run normally.

Since my STM32CubeMX software had always been able to access the internet and update normally, I hadn’t considered this DNS issue before.