This is an automated email from the ASF dual-hosted git repository. sjanc pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/mynewt-core.git
commit dddac2ff49d8b78da9e73fcb2352d6171319294d Author: Szymon Janc <[email protected]> AuthorDate: Wed Oct 21 16:27:35 2026 +0200 ci: Label all pull requests based on paths in PR maintenance Path based labeling was done only for pull requests with new head commit, detected by missing 'Check workflows' status. Label all pull requests on each run instead, so labeling doesn't depend on the status and labeler configuration changes are applied to open pull requests. Assisted-by: Claude:claude-opus-5-5 --- .github/scripts/pr_maintenance.py | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/.github/scripts/pr_maintenance.py b/.github/scripts/pr_maintenance.py index 217d37988..896996c23 100644 --- a/.github/scripts/pr_maintenance.py +++ b/.github/scripts/pr_maintenance.py @@ -30,17 +30,16 @@ is done through GitHub API using gh tool. - 'Check workflows' commit status reports whether .github of pull request head matches base branch ('workflows-update' label skips the check). -- Pull requests with new head commit are reported for path based - labeling, which is done by actions/labeler in the workflow. +- All pull requests are reported for path based labeling, which is + done by actions/labeler in the workflow. Pull requests without activity for MAX_AGE_DAYS are skipped, also when marked with 'stale' label (set by stale workflow) until new commit is pushed. -'Check workflows' status also marks pull request head as processed: it -is tied to head commit and its description contains base branch .github -tree it was checked against, so only new or changed pull requests are -processed. +'Check workflows' status is tied to head commit and its description +contains base branch .github tree it was checked against, so it is +reported only for new or changed pull requests. Usage: pr_maintenance.py check - update labels, write step outputs @@ -336,17 +335,12 @@ def check(): errors += update_outdated_label(pulls_ok) statuses = [s for s in map(workflows_status, pulls_ok) if s] statuses = statuses[:MAX_PULLS_PER_RUN] - reported = {s["sha"] for s in statuses} - - # No status on head commit means pull request was updated - labels = [str(p["number"]) for p in pulls - if not p["status"] and p["head"] in reported] for status in statuses: print(f"{status['sha']}: {status['description']}") return errors, { - "pr-numbers": "\n".join(labels), + "pr-numbers": "\n".join(str(p["number"]) for p in pulls), "statuses": json.dumps(statuses), }
