-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmake: flash: three runners.yaml fixes #23027
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mbolivar
commented
Feb 21, 2020
There are two problems with the way runners.yaml is being created: 1. The dictionary which contains the arguments for each runner is using the runner's name converted to a C identifier instead of the runner's name itself. That causes west flash to fail when the two are different, e.g. for 'misc-flasher' (runner name), which is different than 'misc_flasher' (runner name as C identifier) 2. We need to make sure that the dictionary key maps to an empty list if there are no arguments, which normally doesn't happen since the runner usually at least takes the path of the file to flash or debug. It does happen in the case of misc-flasher, though, since the whole point of that runner is that it's an escape hatch for people with out of tree scripts that nevertheless want 'west flash' integration for things like sanitycheck device testing. 3. A copy/paste error is setting the debug runner to the flash runner. Fix them all. Fixes: zephyrproject-rtos#23004 Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
mbolivar
changed the title
cmake: flash: two runners.yaml fixes
cmake: flash: three runners.yaml fixes
Feb 21, 2020
carlescufi
approved these changes
Feb 21, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested, works for me. Thanks!
jhedberg
approved these changes
Feb 22, 2020
chen-png
approved these changes
Feb 24, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested, it solved #23004.
SebastianBoe
approved these changes
Feb 24, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There are three problems with the way runners.yaml is being created:
The dictionary which contains the arguments for each runner is
using the runner's name converted to a C identifier instead of the
runner's name itself. That causes west flash to fail when the two
are different, e.g. for 'misc-flasher' (runner name), which is
different than 'misc_flasher' (runner name as C identifier)
We need to make sure that the dictionary key maps to an empty list
if there are no arguments, which normally doesn't happen since the
runner usually at least takes the path of the file to flash or debug.
It does happen in the case of misc-flasher, though, since the whole
point of that runner is that it's an escape hatch for people with
out of tree scripts that nevertheless want 'west flash' integration
for things like sanitycheck device testing.
A copy/paste error is setting the debug runner to the flash runner.
Fix them all.
Fixes: #23004