Skip to content

mbed-tools configure fails due to multiple mbed-os paths being searched #323

Open
@OllyMcBrideOB

Description

@OllyMcBrideOB

Issue
The same error as #234 (see error message below), possibly caused by using a shared instance of mbed-os.

Error
ValueError: Setting <random configuration setting> already defined. You cannot duplicate config settings!
(The setting name changes every time the command is executed)

Details
I believe this issue is caused when assemble_config() finds the mbed-os/ path within program.root, and then the mbed-os/ path is also passed in via program.mbed_os.root.

config = assemble_config(
target_build_attributes, [program.root, program.mbed_os.root], program.files.app_config_file
)

In the above snipped, if I remove program.mbed_os.root everything works correctly.

To Reproduce

  1. Navigate to mbed-os-example-blinky
  2. Use shared instance of mbed-os
  3. Enter mbed-tools configure -m NRF52_DK -t GCC_ARM

Expected behavior
The mbed-tools configure -m NRF52_DK -t GCC_ARM command should configure the mbed-os-example-blinky project for CMake.

Desktop (please complete the following information):

  • OS: Windows
  • Version: 21H1

Mbed (please complete the following information):

  • Device: NRF52_DK
  • Mbed OS Version: [e.g. 6.8.0]
  • Mbed CLI 2 Version: 7.50.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions