An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

throwsanalyzer

A production-ready Roslyn analyzer providing comprehensive exception handling analysis for C# code with 30 diagnostic rules and 16 automated code fixes. Features: • 30 diagnostic rules covering all exception patterns • 16 automated code fixes for one-click issue resolution • Exception flow analysis across method calls • Async/await exception pattern detection • Iterator (yield) exception analysis • Lambda and event handler exception detection • Best practices and design pattern suggestions • Hot path performance analysis • Result<T> pattern recommendations Detects: • Unhandled exceptions and missing try-catch blocks • Rethrow anti-patterns (throw ex vs throw) • Unreachable and empty catch clauses • Async void exceptions and unobserved tasks • Exceptions in loops (performance issues) • Custom exception naming violations • Exception-based control flow • Undocumented public API exceptions Automated Fixes: • Wrap code in try-catch blocks • Fix rethrow statements to preserve stack traces • Convert async void to async Task • Add XML exception documentation • Rename exception types to follow conventions • Move validation outside loops • Add Task observation (await, continuations) • And more! Perfect for: Code quality enforcement, automated code reviews, CI/CD integration, and teaching exception best practices.

Ecosystem
nuget.org
Latest Release
1.0.0-beta.2
4 months ago
Versions
2
Links
Registry nuget.org
Source Repository
JSON API View JSON
CodeMeta codemeta.json
Package Details
PURL pkg:nuget/throwsanalyzer
spec
License MIT
First Release 4 months ago
Last Synced 7 days ago