Skip to content

Conversation

carlescufi
Copy link
Member

See commit messages.

Until now, for historical reasons (see
f42cef9 and
58e0e31), the use of the --erase-mode
command-line switch was reserved for the nRF54L family. But in fact this
can be used (instead of --erase) for any of the Nordic ICs. This patch
extends the usage of this switch regardless of family.

Signed-off-by: Carles Cufi <[email protected]>
Add a new parameter to the ZephyrBinaryRunner init() method to specify
whether this should be a dry run. The default is still taken from the
_DRY_RUN global, but can be overridden by subclasses.

Since the new dry_run parameter has a default value this should not
break backwards compatibility with out-of-tree runners.

Signed-off-by: Carles Cufi <[email protected]>
@@ -483,12 +485,15 @@ class ZephyrBinaryRunner(abc.ABC):
commands in its constructor. The actual command execution is
handled in the run() method.'''

def __init__(self, cfg: RunnerConfig):
def __init__(self, cfg: RunnerConfig, dry_run: bool=_DRY_RUN):
Copy link
Member Author

@carlescufi carlescufi Oct 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pdgendt I am fairly sure this will not break out-of-tree runners, but FYI. Also, CC @mbolivar.

@zephyrbot zephyrbot added the area: West West utility label Oct 21, 2025
@marc-hb marc-hb removed their request for review October 21, 2025 17:48
@pdgendt pdgendt assigned carlescufi and unassigned pdgendt Oct 22, 2025
pdgendt
pdgendt previously approved these changes Oct 22, 2025
In order to allow for users to invoke "west flash" without actual
hardware connected but still running the logic and pregeneration of
commands.

Signed-off-by: Carles Cufi <[email protected]>
@carlescufi
Copy link
Member Author

@pdgendt I realized I was missing parts of the implementation I had not committed. Can you please take another look?

@carlescufi carlescufi requested a review from pdgendt October 23, 2025 16:51
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: West West utility

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants