error-handling-patterns

Design error handling strategies with exceptions, Result types, retries, and circuit breakers.

Updated May 16, 2026
One-click install
npx skills add https://github.com/p-o-ke-nae/pokemondamagecalculatorforstory --skill error-handling-patterns-p-o-ke-nae
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: error-handling-patterns
Source: https://github.com/p-o-ke-nae/pokemondamagecalculatorforstory/tree/main/.github/skills/error-handling-patterns
Command: npx skills add https://github.com/p-o-ke-nae/pokemondamagecalculatorforstory --skill error-handling-patterns-p-o-ke-nae

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you design safer, clearer, and more resilient error handling so applications fail predictably, recover cleanly, and remain easier to debug.

Core Features & Use Cases

  • Error Modeling: Choose between exceptions, Result types, and custom error classes based on the kind of failure you need to represent.
  • Recovery Patterns: Apply retries, circuit breakers, graceful degradation, and cleanup flows to keep systems stable under failure.
  • Cross-Language Guidance: Use practical patterns for Python, TypeScript, Rust, and Go when building APIs, async workflows, and distributed services.
  • Use Case: When a payment or network call fails in production, this Skill helps you preserve context, surface meaningful messages, and decide whether to retry, fall back, or re-raise.

Quick Start

Use this skill to review a code path for error-handling gaps and suggest concrete improvements for propagation, logging, recovery, and cleanup.

Frequently Asked Questions about error-handling-patterns

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

FAQPage Schema
How do I design error handling strategies for distributed systems and async workflows?

Error handling strategies for distributed systems use propagation rules, retries, circuit breakers, and graceful degradation to keep systems stable. This Skill designs robust patterns for async workflows, APIs, and background jobs to ensure predictable failures and clean recovery.

When should I use Result types instead of exceptions for error modeling?

Use Result types instead of exceptions when you need explicit, typed error modeling without control flow interruption. This Skill helps choose between exceptions, Result types, and custom error classes based on the specific failure type and production-grade validation requirements.

How do I preserve context and add meaningful logging when a network call fails in production?

Preserve context during a network call failure by applying context-preserving logging and typed error modeling. This Skill reviews code paths to suggest concrete improvements for propagation, cleanup, and surfacing meaningful messages when payments or network requests fail.

Does this error handling approach work with Python, TypeScript, Rust, and Go?

Yes, cross-language guidance applies practical error handling patterns for Python, TypeScript, Rust, and Go. This Skill provides specific recovery patterns, custom error classes, and propagation rules tailored to building APIs and distributed services in these languages.

What's the best way to implement retries and circuit breakers for background jobs?

The best way to implement retries and circuit breakers for background jobs is applying recovery patterns that decide whether to retry, fall back, or re-raise. This Skill designs cleanup flows and stability mechanisms for systems under failure.

Why does my application crash unpredictably instead of failing gracefully during dependency failures?

Applications crash unpredictably when lacking graceful degradation and typed error propagation. This Skill designs robust error handling strategies with cleanup flows and recovery patterns so applications fail predictably, recover cleanly, and remain easier to debug.