feat: add monthly milestone bot with Discord notification#2087
Open
Patrick-Augusto wants to merge 7 commits into
Open
feat: add monthly milestone bot with Discord notification#2087Patrick-Augusto wants to merge 7 commits into
Patrick-Augusto wants to merge 7 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Adds an automated monthly milestone creator that runs on the 1st of each month (or manually), reading objectives from a YAML config and notifying Discord on completion.
Changes:
- New GitHub Actions workflow scheduled monthly with manual dispatch inputs for month/year.
- New github-script-based JS module that creates/updates a GitHub milestone with layered YAML parsing fallbacks and Discord webhook retries.
- New
milestone-config.ymldefining default objectives and per-month overrides.
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| milestone-config.yml | Declares default objectives and June 2026 milestone entry. |
| .github/workflows/monthly-milestone.yml | Schedules monthly run, installs yaml package, invokes the script. |
| .github/scripts/create-monthly-milestone.js | Implements config loading, milestone create/update, and Discord notification. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Add milestone-config.yml for maintainers to define monthly objectives - Add create-monthly-milestone.js with 3 redundancy layers: - YAML parsing fallback (npm yaml -> line-by-line parser -> hardcoded defaults) - Idempotent milestone sync (create -> update on conflict) - Discord webhook retry with exponential backoff - Add monthly-milestone.yml workflow (cron: 1st of month at 08:00 UTC + manual dispatch)
…reator - Remove unused 'i' index from map callback - Read and respect Discord 'Retry-After' and 'X-RateLimit-Reset-After' rate-limit headers in milliseconds with safety buffer - Precisely inspect errors for HTTP 422 'already_exists' instead of assuming all 422s are duplicates - Paginate all pages of milestones via github.paginate instead of limiting to the first page (max 100) - Install yaml package with --no-save in the workflow to prevent workspace/checkout pollution - Make fallback YAML line parser extremely robust and permissive (support unquoted values, single/double quotes, and any indentation) - Change milestone due_on time component to T08:00:00Z to prevent date shifting and match GitHub's default storage format
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
The flowchart PNG was removed by the maintainer in 5cc2807. Drop the comment that referenced it from monthly-milestone.yml so we don't point to a file that no longer exists. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
f3f137f to
9ccde09
Compare
|
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.



Feature Description 📝
A bot-driven automation system that creates a new GitHub Milestone every month with predefined objectives, and automatically posts a formatted summary to a dedicated Discord channel.
📊 Bot Workflow Diagram
Motivation 🌟
Currently, monthly milestones are created manually, which introduces delays, formatting inconsistencies, and limited community visibility. This automation:
Changes
New Files (4 files, 0 existing files modified)
milestone-config.yml.github/scripts/create-monthly-milestone.js.github/workflows/monthly-milestone.yml.github/milestone_bot_flowchart.pngRedundancy Layers
yamlnpm packagemilestone-config.ymldefault_objectivesfrom configHow It Works
On the 1st of each month (or manual trigger), the bot:
Month YYYYwith a due date on the last day of that monthmilestone-config.ymlUpon milestone creation, posts to Discord with:
Setup Required
Testing
node -c).ymlfilesActions → Monthly Milestone Creator → Run workflowFixes #2073