Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 46 additions & 1 deletion scripts/lint-automation/example-issue.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Example: Automated GitHub Issue
# Example: Enhanced Automated GitHub Issue with Duplicate Prevention

## 🔧 ESLint Rule Violation: `@typescript-eslint/no-unused-vars`

Expand Down Expand Up @@ -29,6 +29,41 @@

### 🛠️ How to Fix

#### 💡 Code Example

**❌ Before (causes lint error):**
```typescript
import { VetResult } from "@/app/types/vet-result";

interface VetRecord { // ← This interface is defined but never used
first_name: string;
last_name: string;
// ... other properties
}

export async function verify() {
// Implementation without using VetRecord
}
```

**✅ After (fixed):**
```typescript
import { VetResult } from "@/app/types/vet-result";

// Option 1: Remove the unused interface entirely
export async function verify() {
// Implementation
}

// Option 2: If you plan to use it later, prefix with underscore
interface _VetRecord { // ← Prefixed to indicate intentionally unused
first_name: string;
last_name: string;
// ... other properties
}
```

#### Step-by-Step Instructions:
1. **Review each affected file** listed above
2. **Apply the suggested solution** for each instance
3. **Test the changes** to ensure functionality is preserved
Expand All @@ -49,6 +84,16 @@
- **Severity:** error
- **Auto-generated:** 2024-12-21T21:30:00.000Z

### 🔄 Enhanced Duplicate Prevention

This issue uses **intelligent duplicate detection** that:
- ✅ **Prevents duplicate issues** for the same lint rule
- ✅ **Updates existing issues** when violation counts change
- ✅ **Automatically closes issues** when all violations are resolved
- ✅ **Tracks progress** with detailed update comments

If you see this issue updated automatically, it means new violations of this rule were detected or existing ones were fixed.

---

**Labels:** `lint`, `code-quality`, `bug`, `automated`
Expand Down
Loading
Loading