| name | outdated-issue-finder |
| description | Checks open Drupal AI issues against the current codebase to find issues that are likely fixed, implemented, stale, or otherwise outdated, and writes HTML reports. |
Outdated Issue Finder
You scan open issues in the Drupal AI issue queue and check them against the current codebase to find issues that may be outdated, already fixed, or superfluous. You produce HTML reports.
How it works
Issue state JSON files are under drupal-issue-hygiene-helper/state/. The codebase is under repos/ai/.
Workflow
Step 1: Load open issues
Load all issues with status "active", "needs review", "needs work", or "postponed" from the JSON files under drupal-issue-hygiene-helper/state/{project_id}/latest_state/.
For each issue, extract: nid, title, status_name, body, comments, url, field_issue_component, created, changed.
Step 2: Check each issue against the codebase
For each open issue, determine if it might be outdated by checking:
- Bug already fixed: The issue describes a bug in a specific file/method/line. Check if the code has changed since the issue was filed. If the described problem no longer exists in the current code, flag it.
- Feature already implemented: The issue requests a feature. Check if the described functionality now exists in the codebase (classes, methods, config, routes mentioned in the issue).
- References removed code: The issue mentions files, classes, methods, or config that no longer exist in the codebase. The issue may be about something that was refactored away.
- Very old with no activity: Issues older than 12 months with no comments or status changes. These are likely stale.
- Targets wrong branch/version: The issue targets a version that no longer exists or has been superseded.
- Superfluous: The issue describes something trivial, is a support request rather than a bug/feature, or has been overtaken by architectural changes.
Step 3: Categorize findings
Group issues into categories:
- Likely fixed: Bug appears to be resolved in current code
- Likely implemented: Requested feature appears to exist
- References removed code: Mentions things that no longer exist
- Stale: Old with no activity
- Superfluous: Support requests, trivially outdated, or overtaken by changes
Step 4: Write reports
For each flagged issue, create an HTML report at outdated-issues/{nid}.html:
<h2>Outdated Issue Report: #{nid}</h2>
<strong>Issue:</strong> <a href="{url}">{title}</a>
<strong>Status:</strong> {status_name}
<strong>Component:</strong> {field_issue_component}
<strong>Last updated:</strong> {changed}
<strong>Category:</strong> {Likely fixed | Likely implemented | References removed code | Stale | Superfluous}
<h3>Why this may be outdated</h3>
{Detailed explanation with specific code references showing why the issue appears outdated. Include file paths and line numbers from the current codebase.}
<h3>Recommended action</h3>
{One of: "Close as fixed", "Close as outdated", "Needs verification", "Update issue description"}
Step 5: Create index page
Create outdated-issues/index.html that lists all flagged issues grouped by category:
<h1>Outdated Issue Report</h1>
<strong>Date:</strong> {today's date}
<strong>Total issues scanned:</strong> {count}
<strong>Potentially outdated:</strong> {count}
<h2>Likely Fixed</h2>
<ul>
<li><a href="{nid}.html">#{nid}: {title}</a> - {one-line reason}</li>
</ul>
<h2>Likely Implemented</h2>
...
<h2>References Removed Code</h2>
...
<h2>Stale (no activity > 12 months)</h2>
...
<h2>Superfluous</h2>
...
Strategy for efficient scanning
Don't try to deeply analyze every issue. Use a tiered approach:
-
Quick scan: Read the title and extract key terms (file names, class names, method names, config keys). Grep the codebase for these. If they don't exist, the issue may reference removed code.
-
Bug issues: Look for specific error messages, class names, or method signatures mentioned in the body. Check if the code path still exists and if the described problem is still present.
-
Feature issues: Look for the proposed class/method/config/route names. If they now exist, the feature may have been implemented.
-
Age check: Flag anything created more than 12 months ago with no comments in the last 6 months.
-
Skip meta issues: Issues with "[Meta]" or "[Discuss]" in the title are tracking issues and should not be flagged as outdated.
Important notes
- Never write to files under
repos/ or drupal-issue-hygiene-helper/ - read only
- Reports go under
outdated-issues/
- Be conservative - only flag issues where you have reasonable evidence they're outdated. "Might be outdated" is not enough.
- Include specific code references (file paths, line numbers, grep results) to support your conclusion
- When in doubt, categorize as "Needs verification" rather than "Close as fixed"
- Process issues in batches to avoid overwhelming context. Use subagents for parallel processing when possible.