Always "The build configuration is stale. Run a pristine build" in newer versions of nrf connect for vs code

hi!

I get the message "The build configuration is stale. Run a pristine build" even after rebuilding in all versions of nrf connect for vs code after 2023.7.129.

I have tried to remove the workspace and start over but the problem is still there.

I also tried the 2024.5.37 pre-release version to see if the problem is still there.

I tested create a new application based on the "hello world" sample with the same result.

As soon as I switch back to 2023.7.129 the source folder/files show up as expected.

BR,
Mårten

  • Hi

    Thanks for the reply.

    As far as I can remember I have installed both versions thru the "Toolchain Manager" (currently running official version v1.4.1).

    Maybe nothing but the version shows differently in the nrf-connect section and in the toolchains section in the support information of the new version (but not the old).

    I have also tried to remove the v2.6.0 version and reinstalling it (also remving the file in the download folder) and it still shows this version.

    The file I have in the download folder is ncs-toolchain-x86_64-linux-2be090971e.tar.gz

    Old version
    ...
      "toolchains": [
        {
          "version": "2.4.0",
          "path": "/home/marten/other/ncs/toolchains/1f9b40e71a"
        },
        {
          "version": "2.6.20240304",
          "path": "/home/marten/other/ncs/toolchains/2be090971e"
        }
      ],
    ....
    "config": {
        "nordic-semiconductor.nrf-connect": {
          "topdir": "",
          "toolchain": {
            "path": "${nrf-connect.toolchain:2.6.20240304}"
          },
    ....
        "toolchainPath": "/home/marten/other/ncs/toolchains/2be090971e",
        "toolchainBinPath": "/home/marten/other/ncs/toolchains/2be090971e/opt/zephyr-sdk/arm-zephyr-eabi/bin",
        "toolchainVersion": "2.6.20240304"
    ....

    New version:
    ....
      "toolchains": [
        {
          "version": "2.6.0",
          "path": "/home/marten/other/ncs/toolchains/2be090971e"
        },
        {
          "version": "2.4.0",
          "path": "/home/marten/other/ncs/toolchains/1f9b40e71a"
        }
      ],
    ...
      "config": {
        "nordic-semiconductor.nrf-connect": {
          "topdir": "",
          "toolchain": {
            "path": "${nrf-connect.toolchain:2.6.20240304}"
          },
    ....
        "toolchainPath": "/home/marten/other/ncs/toolchains/2be090971e",
        "toolchainBinPath": "/home/marten/other/ncs/toolchains/2be090971e/opt/zephyr-sdk/arm-zephyr-eabi/bin",
        "toolchainVersion": "2.6.0"
    ....

    BR,
    Mårten

  • Hello Mårten,

    I have asked the respective team. I will let you know the updatesoon. 

  • Hello Mårten,

    It seems like the toolchain was not installed by nrfutil toolchain-manager, or not properly installed. You can try to remove that toolchain and install it again. Please do not to use the toolchain manager app, rather use the Manage toolchains menu in VS Code.

  • Hi!

    That seems to have solved the issue, at least after realizing that the "manage toolchin" does not "default" to the location where the other toolchain was installed but must change the path manually to make it install to the same "toolchains" directory (where I had enough space).

    BR,

    Mårten

  • Same problem this morning, chasing this issue now for a couple of hours. vscode crashed during some editing, after restarting vscode I got stuck with this ""The build configuration is stale. Run a pristine build" issue. After cleaning caches and build directories for some time I stumbled across the fact that the "nRF Connect for VS Code" extensions has been auto-updated to "Version 2024.11.22" and likely got active at the vscode restart. Issue seems related to that vscode now determines that something changed during the build and always considers the build stale. Forcing the extension back to "Version 2024.9.31" solves my problem.

    I have these two config variables in my prj.conf:

    CONFIG_SOC_NRF52832_ALLOW_SPIM_DESPITE_PAN_58=y
    CONFIG_NRFX_PPI=y
    Extensions "Version 2024.11.22" emits a warning that these two config options changes to "n" during the build, which I believe is false. At least there is no sign in build output that this would be the case and the working version of the extension "Version 2024.9.31" does not detect this either. I'm just guessing this might be the reason why this "The build configuration is stale. Run a pristine build" appears all the time.
    I really don't understand why defaults in this environment is set to auto-update, who actually wants a development environment that self-updates silently in the back throwing the developer into new issue like this? This is really frustrating and non-productive.
Related