cdt: fix adding host: section, improve deduplication and handling empty lines#5835
Merged
beckermr merged 3 commits intoregro:mainfrom Mar 19, 2026
Merged
cdt: fix adding host: section, improve deduplication and handling empty lines#5835beckermr merged 3 commits intoregro:mainfrom
host: section, improve deduplication and handling empty lines#5835beckermr merged 3 commits intoregro:mainfrom
Conversation
Fix adding duplicate dependencies for replaced CDTs when the relevant package is already present in requirements. It's not a big deal, but can be avoided reasonably easily. Signed-off-by: Michał Górny <mgorny@quansight.com>
Detect empty lines at the end of `host:` subsection (which can be used to separate it from the following subsection), and insert new dependencies before them. This also permits us to remove special-handling empty lines at the end of requirement sections. Signed-off-by: Michał Górny <mgorny@quansight.com>
Signed-off-by: Michał Górny <mgorny@quansight.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5835 +/- ##
==========================================
+ Coverage 80.54% 80.57% +0.02%
==========================================
Files 146 146
Lines 17348 17358 +10
==========================================
+ Hits 13973 13986 +13
+ Misses 3375 3372 -3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
Author
|
Thanks! |
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.
Description:
Three fixes for the CDT migrator:
host:section to a recipe without one. Add a minimal test case (there is no real recipe like that).host:section prior to any trailing empty lines.Checklist:
Cross-refs, links to issues, etc: