-
Notifications
You must be signed in to change notification settings - Fork 144
feat: Add workflow to notify team about Good first issues #1123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add workflow to notify team about Good first issues #1123
Conversation
|
Hi, this is WorkflowBot.
|
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
WalkthroughAdds a GitHub Actions workflow and helper script that post a team notification comment when issues are labeled "Good First Issue" or "Good First Issue Candidate"; includes idempotency checks, error handling, and a changelog entry. Changes
Sequence Diagram(s)sequenceDiagram
participant GHEvents as GitHub Events (Issue labeled)
participant Workflow as GitHub Actions Workflow
participant Script as gfi_notify_team.js
participant GHAPI as GitHub API
GHEvents->>Workflow: deliver "issues" labeled event
Workflow->>Workflow: evaluate label (GFI or GFI Candidate)
alt label matches
Workflow->>Script: run script with context
Script->>Script: extract owner, repo, issue, label
Script->>GHAPI: list comments on issue
Script->>Script: scan for marker
alt marker not found
Script->>GHAPI: create comment with TEAM_ALIAS and message
Script->>Script: log success
else marker found
Script->>Script: exit (idempotent)
end
else label does not match
Workflow->>Workflow: skip job
end
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes
Suggested reviewers
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
.github/scripts/gfi_notify_team.js(1 hunks).github/workflows/bot-gfi-notify-team.yml(1 hunks)CHANGELOG.md(1 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
.github/scripts/gfi_notify_team.js (1)
.github/scripts/pr_inactivity_reminder.js (2)
owner(77-77)repo(78-78)
⏰ 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). (1)
- GitHub Check: Codacy Static Code Analysis
🔇 Additional comments (11)
CHANGELOG.md (1)
44-44: LGTM!The changelog entry clearly documents the new GFI notification workflow and follows the established format.
.github/scripts/gfi_notify_team.js (6)
3-4: Note: Team alias may change in future governance PR.The team alias is correctly defined per the current requirements. However, the PR objectives mention that "the team name may be renamed in a related governance PR." Be prepared to update this constant if the team name changes.
6-30: LGTM!The
notifyTeamhelper function is well-structured with clear formatting, proper error handling, and a success/failure return value.
32-40: LGTM!Proper payload extraction and validation with defensive early returns for missing data.
42-49: LGTM!The message logic correctly implements the requirements from issue #1115, with appropriate messages for each label type.
51-57: Excellent idempotency implementation!The marker-based duplicate detection with pagination ensures notifications are posted only once, even if the label is removed and re-added.
68-70: LGTM!Proper top-level error handling ensures graceful failure without crashing the workflow.
.github/workflows/bot-gfi-notify-team.yml (4)
1-6: LGTM!The workflow trigger is correctly configured to run on issue labeling events.
8-10: LGTM!Permissions follow the principle of least privilege, granting only what's necessary for the workflow to function.
12-19: LGTM!The job-level conditional provides efficient early exit for non-matching labels, saving compute resources before the script even runs.
21-37: LGTM!The workflow steps are correctly configured with proper security hardening, repository checkout, and script execution via GitHub Script action.
exploreriii
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @kplnosmn94-droid
This looks great and like it will work nicely!
Can we fix the name please and make sure the phrasing is clear as the GFI supprot team is cross sdk but we are postinf from the Python SDK
Signed-off-by: Osman Kaplan <[email protected]>
Signed-off-by: Osman Kaplan <[email protected]>
bf4f66e to
551f2e9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
CHANGELOG.md (1)
47-47: Add space before issue reference for consistency.Minor formatting: add a space before the issue reference to match the style of other changelog entries (e.g., line 45).
🔎 Apply this diff:
-- Add a workflow to notify the team when issues are labeled as "good first issues" or identified as candidates for that label: `bot-gfi-notify-team.yml`(#1115) +- Add a workflow to notify the team when issues are labeled as "good first issues" or identified as candidates for that label: `bot-gfi-notify-team.yml` (#1115)
📜 Review details
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
.github/scripts/gfi_notify_team.js(1 hunks).github/workflows/bot-gfi-notify-team.yml(1 hunks)CHANGELOG.md(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/bot-gfi-notify-team.yml
🧰 Additional context used
🧬 Code graph analysis (1)
.github/scripts/gfi_notify_team.js (1)
.github/scripts/pr_inactivity_reminder.js (2)
owner(77-77)repo(78-78)
⏰ 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). (1)
- GitHub Check: Codacy Static Code Analysis
🔇 Additional comments (3)
.github/scripts/gfi_notify_team.js (3)
15-15: Verify the comment signature.The signature "Python SDK team" was previously questioned. Confirm this is the intended bot identity or consider alternatives like "Good First Issue Bot" or "Automated Notification System" for clarity.
Based on learnings, exploreriii asked: "Python SDK team?" suggesting uncertainty about this signature choice.
60-68: Well done addressing the previous review feedback.The return value from
notifyTeamis now properly captured and checked before logging the summary, resolving the concern from the previous review.
4-4: The team alias@hiero-ledger/hiero-sdk-good-first-issue-supportis correctly configured in governance and does not require changes. The team exists in current governance configuration and is properly assigned to the hiero-sdk-python repository with triage permissions for Good First Issue management.Likely an incorrect or invalid review comment.
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #1123 +/- ##
=======================================
Coverage 91.04% 91.04%
=======================================
Files 139 139
Lines 8409 8409
=======================================
Hits 7656 7656
Misses 753 753 🚀 New features to boost your workflow:
|
exploreriii
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect! Amazing! This will be incredibly helpful, if you can think of any additional workflows to automate or improve the user experience let us know, thank you
…er#1123) Signed-off-by: Osman Kaplan <[email protected]> Signed-off-by: prajeeta pal <[email protected]>
This pull request introduces an automated workflow to immediately notify the good first issue support team when an issue is labeled as "Good First Issue" or "Good First Issue Candidate" in the repository. The implementation includes a new GitHub Actions workflow and a supporting notification script, ensuring the team is promptly alerted to help new contributors.
Workflow Automation:
Added a new GitHub Actions workflow (
.github/workflows/bot-gfi-notify-team.yml
) that triggers when an issue is labeled. It checks specifically for Good First Issue or Good First Issue Candidate labels and executes the notification script.
Related issue(s):
Fixes #1115
Checklist
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.