-
Notifications
You must be signed in to change notification settings - Fork 392
Add a skill for closing obsolete issues #9812
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
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
2a845e7
Add a skill for closing obsolete issues
kenzieschmoll 16f978d
updates
kenzieschmoll 2b55140
updates
kenzieschmoll 0966567
handle deleted authors
kenzieschmoll fb83f5b
update triage.md
kenzieschmoll 1deb2ba
update owners in triage while I'm here
kenzieschmoll ead211d
update skill
kenzieschmoll b680c9f
update skill
kenzieschmoll 279fa29
review comments
kenzieschmoll 441d68a
drop references to agent tools
kenzieschmoll File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| --- | ||
| name: closing-obsolete-issues | ||
| description: Find and close obsolete, stale, or not reproducible issues in the flutter/devtools repository. | ||
| --- | ||
|
|
||
| # Closing Obsolete Issues | ||
|
|
||
| Use this skill to find old, outdated issues in the `flutter/devtools` repository that can be closed because they have been fixed, are stale, obsolete, or not reproducible. | ||
|
|
||
| ## Instructions | ||
|
|
||
| 1. **Identify Target Issues**: | ||
| - Use the GitHub CLI (`gh`) to search for the oldest open issues. | ||
| - Use any label that the user gives you, or none if the user does not specify any issue labels. | ||
| - Sort by creation date (`created-asc`) or last update (`updated-asc`) to find the most likely candidates for being outdated. | ||
| - Fetch at least 20-30 candidates. | ||
| - Example command (with label): `gh issue list --repo flutter/devtools --search "label:bug is:open sort:created-asc" --limit 30 | cat` | ||
| - Example command (without label): `gh issue list --repo flutter/devtools --search "is:open sort:created-asc" --limit 30 | cat` | ||
|
|
||
| 2. **Investigate Status**: | ||
| - For each candidate, analyze its description and comments. | ||
| - **Pro Tip**: Use the bundled script `scripts/fetch_issue_details.sh <number>` to get a comprehensive view of the issue and its comments. | ||
| - Compare the issue's request or reported bug with the current state of the codebase. | ||
| - Refer to `references/rationale_templates.md` for a library of common reasons issues become outdated in DevTools. | ||
| - **Safety Rule**: Do not assume a bug is fixed or obsolete just because the screen has been updated or the file modified. Verify if the specific bug behavior is still possible. Valid bugs or feature requests should not be closed as stale just because they are old or have no activity. Inactivity alone does not invalidate a feature request or bug report. | ||
|
|
||
| 3. **Draft and Review Closing Comments (CRITICAL MANDATE)**: | ||
| - For issues identified as candidates for closing, draft a detailed comment for each explaining *why* it can be closed. | ||
| - **Style Constraint**: DO NOT use em dashes (—) in the comments. Use hyphens (-) or colons (:) instead. | ||
| - **Template**: Consult `references/rationale_templates.md` for wording inspiration. | ||
| - Each comment MUST end with: "If there is more work to do here, please let us know by filing a new issue with up to date information. Thanks!" | ||
| - **User Approval Required**: You MUST present the identified issues (including URLs to the issues for easy navigation) and their drafted comments to the user and obtain explicit approval BEFORE running any command that closes an issue. | ||
|
|
||
| 4. **Iterate on Skill Knowledge (Learning Loop)**: | ||
| - If you discover a new, distinct category of closing rationale that is not covered in `references/rationale_templates.md`, **update the reference file** to include it. | ||
|
|
||
| 5. **Execute and Summarize**: | ||
| - Once approved, use `gh issue close` with the `-c` flag to post the comment and close the issue. | ||
| - Provide the user with a clean bulleted list of links to each closing comment. | ||
|
|
||
| ## Tips | ||
|
|
||
| - Use available file and content search tools (such as `grep`, `ripgrep`, or environment-specific | ||
| search tools) to check the current codebase for references to the issue or relevant code. | ||
| - Look for related PRs that might have fixed the issue but didn't close it automatically. | ||
| - **Pro Tip**: Use the bundled script `scripts/search_prs.sh <query>` to search for PRs in the repository. | ||
| - For issues reporting specific versions, check the current DevTools version in `packages/devtools_app/pubspec.yaml` | ||
| to determine if the reported version is very old. If the reported version is 1 or more major versions behind or 12 or more | ||
| minor versions behind the current version, this issue is a good candidate for being obsolete. | ||
41 changes: 41 additions & 0 deletions
41
.agents/skills/closing-obsolete-issues/references/rationale_templates.md
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| # Common Closing Rationales for DevTools | ||
|
|
||
| When investigating old issues in the Flutter DevTools repository, look for these common reasons they may be eligible for closing. Use these as templates for your closing comments. | ||
|
|
||
| ## 1. Superseded by New DevTools Features | ||
| DevTools has evolved significantly. Many old requests for features are now solved by newer implementations or entire new screens. | ||
| - **Example**: Requests for specific memory allocation tracking features that are covered by the new Tracing or Diff panes. | ||
| - **Rationale**: Point to the new feature or screen that fulfills the need (e.g., "This is now supported in the Memory screen's Tracing pane."). | ||
|
|
||
| ## 2. Observatory Deprecation | ||
| With the deprecation and removal of the Observatory UI in favor of DevTools, issues specifically requesting feature parity or fixing bugs in Observatory integration may be obsolete. | ||
| - **Rationale**: Note that Observatory is deprecated/removed and DevTools is the supported solution. | ||
|
|
||
| ## 3. Tooling Daemon (DTD) and IDE Integration | ||
| Issues about IDE integration or multi-package support might be resolved by the introduction of the Dart Tooling Daemon (DTD). | ||
| - **Rationale**: Explain that DTD now handles this integration or that workspace support has improved. | ||
|
|
||
| ## 4. UI Refactoring and Legacy Screens | ||
| Requests related to old UI patterns or legacy screens that have been completely rewritten or removed are obsolete. | ||
| - **Example**: The "Analysis" pane in the Memory screen no longer exists. | ||
| - **Rationale**: Note that the feature or screen has been refactored or removed. | ||
|
|
||
| ## 5. Resolved by Flutter SDK Updates | ||
| Some issues are caused by or fixed by changes in the Flutter SDK rather than DevTools itself. | ||
| - **Rationale**: If a bug was fixed in a specific Flutter version, mention it. | ||
|
|
||
| ## 6. Stale Feature Requests | ||
| Proposals or feature requests from several years ago with no recent activity or community interest may be closed if they no longer align with current priorities or have been superseded by general improvements. | ||
| - **Rationale**: Note that the issue is a stale feature request with no recent activity and that DevTools has evolved significantly since then. | ||
|
|
||
| ## 7. Very Old DevTools Version | ||
| Issues reported on very old versions of DevTools (check current version in `packages/devtools_app/pubspec.yaml` for comparison) may be closed if they are likely fixed or no longer relevant. | ||
| - **Rationale**: "This issue looks like it occurred on an old version of DevTools. Are you still experiencing this issue with DevTools on the latest Flutter stable? If so, please reopen and we will take a look. Thanks." | ||
|
|
||
| ## 8. Insufficient Information | ||
| Issues that lack clear descriptions, reproduction steps, or logs make it impossible to investigate. | ||
| - **Rationale**: "Without additional information, we cannot debug this issue. Please re-open if you can provide a description of your issue and repro steps. Thanks." | ||
|
|
||
| --- | ||
| **Reminder**: Every closing comment MUST end with: | ||
| "If there is more work to do here, please let us know by filing a new issue with up to date information. Thanks!" |
30 changes: 30 additions & 0 deletions
30
.agents/skills/closing-obsolete-issues/scripts/fetch_issue_details.sh
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| #!/bin/bash | ||
|
|
||
| # A script to fetch and format comprehensive issue details for investigation. | ||
| # Usage: ./fetch_issue_details.sh <issue_number> | ||
|
|
||
| ISSUE_NUMBER=$1 | ||
|
|
||
| if [ -z "$ISSUE_NUMBER" ]; then | ||
| echo "Usage: $0 <issue_number>" | ||
| exit 1 | ||
| fi | ||
|
|
||
| echo "--- INVESTIGATION FOR ISSUE #$ISSUE_NUMBER ---" | ||
| # Fetching all comments to ensure full context is captured. | ||
| gh issue view "$ISSUE_NUMBER" --repo flutter/devtools --json number,title,author,createdAt,labels,body,comments -t ' | ||
| Title: {{.title}} | ||
| Author: {{if .author}}{{.author.login}}{{else}}ghost{{end}} | ||
| Created: {{.createdAt}} | ||
| Labels: {{range .labels}}{{.name}}, {{end}} | ||
|
|
||
| Description: | ||
| {{.body}} | ||
|
|
||
| --- ALL COMMENTS --- | ||
| {{range .comments}} | ||
| {{if .author}}{{.author.login}}{{else}}ghost{{end}} ({{.createdAt}}): | ||
| {{.body}} | ||
| ------------------------------------------------------------ | ||
| {{end}} | ||
| ' | ||
|
kenzieschmoll marked this conversation as resolved.
|
||
21 changes: 21 additions & 0 deletions
21
.agents/skills/closing-obsolete-issues/scripts/search_prs.sh
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| #!/bin/bash | ||
|
|
||
| # A script to search for PRs in flutter/devtools. | ||
| # Usage: ./search_prs.sh <query> | ||
|
|
||
| QUERY=$1 | ||
|
|
||
| if [ -z "$QUERY" ]; then | ||
| echo "Usage: $0 <query>" | ||
| exit 1 | ||
| fi | ||
|
|
||
| echo "--- SEARCHING PRs FOR: $QUERY ---" | ||
| gh search prs "$QUERY" --repo flutter/devtools --limit 20 --json number,title,state,url,createdAt -t ' | ||
| {{range .}} | ||
| #{{.number}} {{.title}} ({{.state}}) | ||
| Url: {{.url}} | ||
| Created: {{.createdAt}} | ||
| ------------------------------------------------------------ | ||
| {{end}} | ||
| ' |
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.