Bugfix: Fail build early if MAVLink generation has an error#23313
Merged
Bugfix: Fail build early if MAVLink generation has an error#23313
Conversation
Without this flag the command silently succeeds even though the logs contains an error. It's much more developer friendly to fail early in case of an error. The log path is then also shown in the console output.
This was referenced Jun 21, 2024
Member
Author
|
Suggested a new default here: ArduPilot/pymavlink#952 |
sfuhrer
approved these changes
Jun 24, 2024
Contributor
sfuhrer
left a comment
There was a problem hiding this comment.
Thanks for taking the time to improve the developer experience for the next one who runs into the problem after me..
Member
Author
|
This was solved in a better way now upstream. See #23490 |
Ali-barari
pushed a commit
to Ali-barari/AvesAID
that referenced
this pull request
Apr 29, 2025
Without this flag the command silently succeeds even though the logs contains an error. It's much more developer friendly to fail early in case of an error. The log path is then also shown in the console output.
This file contains hidden or 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
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.
Solved Problem
The mavlink generator command silently succeeds even though the logs could contain errors.
When working through a hard to debug error I found that the generation command for a dialect can silently fail and since the uavionix dialect is still included in most places the some builds succeed without the primary dialect included while other specific test builds that don't contain the uavionix dialect (mavlink FTP test) fail unexpectedly.
Solution
Use ArduPilot/pymavlink#863 to flag the error. I'll propose to make that default in pymavlink.
It's much more developer friendly to fail early in case of an error. The log path is then also shown in the console output.
Changelog Entry
Test coverage
I ran this locally while debugging and lo and behold, it shows an error and the reference to the log output.
