Skip to content

[ci] Enabled issue autoassignment bots#105

Merged
nemesifier merged 1 commit into
openwisp:masterfrom
Eeshu-Yadav:ci/bot-autoassign
May 14, 2026
Merged

[ci] Enabled issue autoassignment bots#105
nemesifier merged 1 commit into
openwisp:masterfrom
Eeshu-Yadav:ci/bot-autoassign

Conversation

@Eeshu-Yadav
Copy link
Copy Markdown
Contributor

@Eeshu-Yadav Eeshu-Yadav commented May 14, 2026

Checklist

  • I have read the OpenWISP Contributing Guidelines.
  • I have manually tested the changes proposed in this pull request.
  • I have written new test cases for new code and/or updated existing tests for changes to existing code.
  • I have updated the documentation.

This PR adds the GitHub Actions workflows to auto-assign issues, manage PR-issue linking, handle PR reopening reassignment, and manage stale PRs.
These workflows check out openwisp/openwisp-utils to run the bot Python scripts, ensuring uniform behavior across all repositories.
Related to the auto-assignment issue bot implementation.

Copilot AI review requested due to automatic review settings May 14, 2026 09:29
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 14, 2026

Review Change Stack

📝 Walkthrough

Walkthrough

This pull request adds four new GitHub Actions workflows to automate issue and pull request management. The workflows integrate with a shared bot utility from the openwisp-utils repository. Three workflows handle event-driven automation: issue comment assignment, PR-to-issue linking, and PR reopening reassignment. A fourth workflow manages stale PRs on a daily schedule. All workflows share similar permission scoping, concurrency controls, and credential passing patterns.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Suggested reviewers

  • nemesifier
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The PR description covers the main changes (adding 4 GitHub Actions workflows for automation) and references a related issue, but leaves two critical checklist items uncompleted: test cases and documentation updates. Clarify whether test cases and documentation updates are truly not needed for these workflow additions, or complete those checklist items before merging.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title '[ci] Enabled issue autoassignment bots' correctly uses the 'ci' type prefix and clearly describes the main change: adding GitHub Actions workflows for issue autoassignment.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Bug Fixes ✅ Passed This PR adds new GitHub Actions workflows for bot automation, not bug fixes. The Bug Fixes check is conditional and not applicable here.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds four GitHub Actions workflows that delegate to a reusable workflow in openwisp/openwisp-utils to provide bot-driven automation for issue assignment, PR-issue linking, PR reopen reassignment, and stale PR management.

Changes:

  • Adds issue assignment bot triggered on issue comments.
  • Adds PR-issue auto-link workflow on PR open/reopen/close and a PR reopen reassignment workflow.
  • Adds scheduled stale PR management workflow.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
.github/workflows/bot-autoassign-issue.yml Triggers issue_assignment bot on new issue comments (non-PR).
.github/workflows/bot-autoassign-pr-issue-link.yml Runs issue_assignment bot when PRs are opened/reopened/closed-unmerged.
.github/workflows/bot-autoassign-pr-reopen.yml Reassigns on PR reopen and handles PR author comment activity via pr_reopen.
.github/workflows/bot-autoassign-stale-pr.yml Daily scheduled stale_pr bot run.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@kilo-code-bot
Copy link
Copy Markdown

kilo-code-bot Bot commented May 14, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

These workflow files correctly integrate with the OpenWISP bot automation system.

Files Reviewed (4 files)
  • .github/workflows/bot-autoassign-issue.yml - Handles issue assignment via comments
  • .github/workflows/bot-autoassign-pr-issue-link.yml - Links PRs to issues and manages assignments on PR open/close
  • .github/workflows/bot-autoassign-pr-reopen.yml - Handles reassignment when PRs are reopened
  • .github/workflows/bot-autoassign-stale-pr.yml - Scheduled workflow for stale PR management

All workflows:

  • Use the verified reusable workflow from openwisp/openwisp-utils@master
  • Have appropriate permissions scoped (contents: read, issues: write, pull-requests: read/write)
  • Use proper concurrency controls to prevent race conditions
  • Correctly pass required secrets (OPENWISP_BOT_APP_ID, OPENWISP_BOT_PRIVATE_KEY)

Reviewed by kimi-k2.5-0127 · 116,089 tokens

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/bot-autoassign-issue.yml:
- Line 14: Replace the floating reference "uses:
openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml@master"
with a pinned commit SHA (for example, change `@master` to @<commit-sha>) so the
reusable workflow is fixed to a specific commit; optionally add a trailing
comment indicating the corresponding tag/version (e.g., "# v1.2.3") for
readability.

In @.github/workflows/bot-autoassign-pr-issue-link.yml:
- Line 15: The workflow currently references the reusable workflow with the
openwisp-utils path pinned to `@master`; change that reference to a specific
commit SHA or a versioned tag instead of `@master` (update the uses line that
mentions openwisp-utils/.github/workflows/reusable-bot-autoassign.yml@master) so
the workflow is pinned to an immutable revision; pick and insert the chosen
commit SHA or released tag for stability and security.

In @.github/workflows/bot-autoassign-pr-reopen.yml:
- Line 25: The workflow currently references the reusable workflow with a
floating ref ("uses:
openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml@master");
change this to a fixed commit SHA or a versioned tag to avoid upstream
breakage—update the "uses" entry to point to a specific commit SHA (or an agreed
tag) for openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml,
and commit that pinned ref so CI always runs against the immutable upstream
revision.
- Line 17: Replace the floating reference to the reusable workflow
"openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml@master"
with a pinned identifier (a specific commit SHA or a tagged release) so the
workflow is immutable; update the "uses:" value to the chosen commit SHA or tag
and verify the workflow still runs correctly in CI after the change.

In @.github/workflows/bot-autoassign-stale-pr.yml:
- Line 15: The workflow references a mutable branch in the reusable workflow
declaration (`uses:
openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml@master`);
change that `@master` ref to an immutable ref (preferably a commit SHA, or
alternatively a pinned release tag) so the reusable workflow is pinned and
reproducible—update the `uses:` line to use the chosen SHA or tag and commit the
change.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: aee8bf82-adf4-420f-ba41-e72cb9dddabe

📥 Commits

Reviewing files that changed from the base of the PR and between e2ba0ed and d56712f.

📒 Files selected for processing (4)
  • .github/workflows/bot-autoassign-issue.yml
  • .github/workflows/bot-autoassign-pr-issue-link.yml
  • .github/workflows/bot-autoassign-pr-reopen.yml
  • .github/workflows/bot-autoassign-stale-pr.yml
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (7)
  • GitHub Check: Upload results
  • GitHub Check: Build ubuntu2204
  • GitHub Check: Build debian12
  • GitHub Check: Build ubuntu2404
  • GitHub Check: Build debian11
  • GitHub Check: Build debian13
  • GitHub Check: Kilo Code Review
🔇 Additional comments (5)
.github/workflows/bot-autoassign-issue.yml (1)

1-20: LGTM!

.github/workflows/bot-autoassign-pr-issue-link.yml (2)

1-21: LGTM!


10-10: ⚡ Quick win

Verify whether including ${{ github.event.action }} in concurrency group is intentional.

The concurrency group differs from other bot workflows in the repository: bot-autoassign-issue.yml and bot-autoassign-pr-reopen.yml do not include action and serialize all operations on the same issue/PR, whereas this workflow allows opened, reopened, and closed events on the same PR to run concurrently (each has a different group key). If the bot modifies shared state (issue assignments, labels, etc.), concurrent execution could cause race conditions. Clarify whether this pattern is intentional or should match the serialization approach of other bot workflows.

.github/workflows/bot-autoassign-pr-reopen.yml (2)

14-30: LGTM!


10-10: ⚡ Quick win

The actual implementation of the pr_reopen command is in the external openwisp-utils repository, which is not available to review here.

While the permission difference between this workflow (pull-requests: write) and the PR-issue linking workflow (pull-requests: read) suggests different permission requirements, the specific operations performed by the pr_reopen command cannot be verified from this repository's codebase alone. To confirm whether write access is necessary, the implementation in openwisp/openwisp-utils/.github/workflows/reusable-bot-autoassign.yml needs to be reviewed.

Comment thread .github/workflows/bot-autoassign-issue.yml
Comment thread .github/workflows/bot-autoassign-pr-issue-link.yml
Comment thread .github/workflows/bot-autoassign-pr-reopen.yml
Comment thread .github/workflows/bot-autoassign-pr-reopen.yml
Comment thread .github/workflows/bot-autoassign-stale-pr.yml
@nemesifier
Copy link
Copy Markdown
Member

@coderabbitai resolve

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 14, 2026

✅ Actions performed

Comments resolved and changes approved.

@nemesifier nemesifier merged commit ce263d3 into openwisp:master May 14, 2026
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants