Fix maintainers-sync / CODEOWNERS job errors - #10385
Merged
Merged
Conversation
The "Update maintainers" and "Mark csc for no maintainer" steps glob
config/boards/*.{conf,wip,csc,eos,tvb}. With no *.wip boards left, the
unmatched *.wip stays literal and sed/grep error with "No such file or
directory"; under GitHub's default bash -e -o pipefail that fails the job
(exit 2).
Enable `shopt -s nullglob` in both steps so an empty support-level class
expands to nothing, and guard the demote grep with `|| true` so no
empty-maintainer match doesn't trip pipefail either.
Signed-off-by: Igor Pecovnik <igor@armbian.com>
Contributor
|
Important Review skippedAuto reviews are limited based on label configuration. 🏷️ Required labels (at least one) (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
When a board has no BOOTCONFIG set, the unquoted `expr $BOOTCONFIG : ...` drops the empty operand, so expr sees `: REGEX` and prints "syntax error: unexpected argument ...". The `|| true` swallowed the exit code but not the stderr noise (two lines during CODEOWNERS generation). Quote it so an empty value is a proper empty-string argument. Signed-off-by: Igor Pecovnik <igor@armbian.com>
Rewrite the generated PR body: an [!IMPORTANT] callout flagging it as auto-generated, a short "what changed" list (maintainers synced, unmaintained boards demoted to CSC, CODEOWNERS refreshed), the become-a-maintainer link, and references. Signed-off-by: Igor Pecovnik <igor@armbian.com>
Note in the auto-PR body that active maintainers are listed automatically on armbian.com/authors based on recent activity. Signed-off-by: Igor Pecovnik <igor@armbian.com>
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.
Two fixes for the scheduled Data: Sync maintainers job.
1. Job fails: no
.wipboards leftNow that the last
.wipboard became.csc, the brace-globconfig/boards/*.{conf,wip,csc,eos,tvb}leaves*.wipliteral (nonullglob), sosed/grepread a nonexistent path and GitHub's defaultbash -e -o pipefailaborts. Affects Update maintainers and Mark csc for no maintainer.Fix:
shopt -s nullglobin both steps (empty class → nothing), plus|| trueon the demotegrepso "nothing to demote" (grep exit 1) doesn't trippipefail.2.
expr: syntax errornoise during CODEOWNERS generationconfig/sources/families/include/rockchip64_common.inchadexpr $BOOTCONFIG : '...'unquoted. For a board with noBOOTCONFIG, the empty operand vanishes andexprsees: REGEX→ syntax error. The|| truehid the exit code but not the stderr. Quote it ("${BOOTCONFIG}") so an empty value is a proper empty-string argument.Verification
.wipfailure with a fixture lacking.wip; afternullglobthe resetsed, the per-board loop, and the demotegrepall run clean.exprerror with emptyBOOTCONFIG; quoted form yields empty (no error) and still extracts the SoC (rk3588-orangepi-5_defconfig→rk3588-orangepi-5) for a real value.bash -nclean.