Kconfig PROBLEMS and errors on MacOS Visual Studio Code not seen on Windows or Linux

Hi,

I get the following Kconfig OUTPUT messages after starting VS Code on MacOS:

Info - 4:48:18 PM] Server starting
[Info - 4:48:18 PM] workspaceFolders: [{'uri': 'file:///opt/nordic/ncs/v2.5.0', 'name': 'v2.5.0'}]
[Info - 4:48:18 PM] Creating context file:///opt/nordic/ncs/v2.5.0/nrf/applications/asset_tracker_v2/build
[Info - 4:48:18 PM] Main build: /opt/nordic/ncs/v2.5.0/nrf/applications/asset_tracker_v2/build
[Info - 4:48:18 PM] file:///opt/nordic/ncs/v2.5.0/nrf/applications/asset_tracker_v2/prj.conf
file:///opt/nordic/ncs/v2.5.0/nrf/applications/asset_tracker_v2/boards/nrf9160dk_nrf9160_ns.conf
file:///opt/nordic/ncs/v2.5.0/nrf/applications/asset_tracker_v2/boards/nrf9160dk_nrf9160_ns_0_14_0.conf
[Info - 4:48:18 PM] Parsing...
[Info - 4:48:18 PM] Reloading Zephyr python modules...
[Info - 4:48:18 PM] boards/arm/nrf9160dk_nrf9160/Kconfig.defconfig:40: error: couldn't parse 'default $(dt_chosen_reg_size_hex,$(DT_CHOSEN_Z_CODE_PARTITION))': macro expanded to blank string
[Info - 4:48:18 PM] Encountered a parsing error, closing 2 files
[Info - 4:48:18 PM] Status: False
And this shows up as a PROBLEM in that terminal tab. It is really ugly. Also, at the bottom right of VS Code, just left of the notification bell, there is a red "errors" field. I have never seen this on Windows or Linux. My MacOS version is Sequoia 15.0.1. I think I found a Devzone ticket from years ago about the same problem, but I don't recall seeing a solution.
Thanks,
Burt Silverman
ps, if I run python3 --version in a terminal window, it shows as 3.9.6.
  • I tried v2.5.2 and I still see the error. Maybe it only shows on Intel based Mac. I see they python script where the error is printed, so maybe I will try putting a few extra prints into the log to see if it happens more than I realize even outside of VS Code, but I haven't looked closely enough at the log messages.

    I will open a new ticket for the guiconfig issue.

    Burt

  • Oh, wait, this has nothing to do with "build". This has to do with the nRF Kconfig extension. And it does not work (except with v2.7.0 SDK) on my Intel based Mac as it is described here https://github.com/NordicPlayground/vscode-nrf-kconfig where it is stated

    Note: DeviceTree choice macros, like $(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_CODE_PARTITION)) are not supported, and their configuration values will not be evaluated.

    The problem is that they are being evaluated, and the evaluation fails, with every SDK level I have tried other than v2.7.0. And then I do not have the possibility of doing an nRF Kconfig GUI.

    Oyvind, does one of your colleagues have an Intel based Mac to eliminate the possibility that there is some bad platform specific code in the nRF Kconfig extension? Otherwise I would like your developers to take a look.

    I wish my team would migrate to v2.7.0 but the folks in charge have decided to stick with v2.5.0 for now. They are not crazy about merging:-(.

    Thanks, Oyvind.

    Burt

  • Burt, I finally got some answers to this issue. This issue is according to our SW team not platform specific, but is also an issue on other OS although giving a different error/failure. 

    That said, none of us are able to reproduce the issue, but our SW team are aware of it and currently working on a fix to be released with NCS v2.8.0.

  • Thanks very much, Oyvind. That's nice to hear that the SW team plans to fix it in v2.8.0.

    I think it has to do with the words I copied from documentation above:

    Note: DeviceTree choice macros, like $(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_CODE_PARTITION)) are not supported, and their configuration values will not be evaluated.

    It appears to me that that sentence up to "are not supported," is accurate, but for some reason the configuration values were being evaluated (or an attempt was made), on my Mac. Or the attempt was made on all platforms, but the results were hidden from VS Code in all cases but my Mac. Anyway, I will go ahead and close the ticket.

Related