edge-case-hunter

Detect unhandled edge cases and boundary conditions in code diffs across five analysis dimensions.

10|3|Updated Mar 7, 2026
One-click install
npx skills add https://github.com/Cynthia1070711/PHYCOOL_Tools --skill edge-case-hunter-cynthia1070711
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: edge-case-hunter
Source: https://github.com/Cynthia1070711/PHYCOOL_Tools/tree/main/config-templates/claude/skills/edge-case-hunter
Command: npx skills add https://github.com/Cynthia1070711/PHYCOOL_Tools --skill edge-case-hunter-cynthia1070711

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Code reviews often miss unhandled boundary conditions—null inputs, race conditions, missing transactions, enum branches left silently unhandled—leading to production bugs like double charges, data loss, and silent failures. This Skill systematically walks every branching path in a diff or file and reports only the unhandled edge cases. ## Core Features & Use Cases - Five-Dimension Analysis: Covers Scalability (N+1 queries, missing pagination), DataConsistency (race conditions, missing transactions, named-set generalization), MigrationIntegrity (EF migration mismatches), ErrorHandling (missing timeouts, swallowed exceptions), and SkillFORBIDDEN (platform-specific forbidden patterns). - Structured JSON Output: Returns findings as a JSON array with location, trigger condition, guard snippet, consequence, severity, and dimension—directly writable to a review_findings database schema. - Standalone or Pipeline Use: Works independently on any diff, file path, or function, with no isolation restrictions, and supports optional also_consider hints for extra analysis scope. - Use Case: Paste a pull request diff for a payment service and receive a JSON list of unhandled paths, such as a concurrent double-charge risk flagged CRITICAL with a suggested distributed-lock guard. ## Quick Start Ask the AI to run edge-case-hunter on a specific diff or file path and return the JSON findings array.

Frequently Asked Questions about edge-case-hunter

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I find unhandled edge cases in a code diff?

Provide the diff as input and the Skill walks every branching path reachable from the changed lines, reporting only boundaries lacking an explicit guard. Findings are returned as a JSON array with location, severity, and a minimal fix snippet.

What kinds of bugs does edge case analysis detect?

It detects N+1 queries, missing pagination, race conditions, missing transactions, broken EF migrations, swallowed exceptions, missing timeouts, and partially special-cased enum or status-code sets. Each finding maps to one of five dimensions: Scalability, DataConsistency, MigrationIntegrity, ErrorHandling, or SkillFORBIDDEN.

Can I use edge-case-hunter outside a review pipeline?

Yes, the standalone mode has no isolation restrictions, so it can freely read spec documents, acceptance criteria, and story descriptions to improve analysis quality. It accepts a diff, a file path, or a function as input.

What output format does the edge case review produce?

It returns only a JSON array where each object has six fields: location, trigger_condition, guard_snippet, potential_consequence, severity, and dimension. An empty array is valid when no unhandled paths are found, and results map directly to a review_findings database table.

What happens when the input file is missing or empty?

The Skill halts and returns a single INFO-severity JSON finding explaining that the input was empty, undecodable, or the file was not found. No further analysis steps are executed after a halt condition triggers.