Skip to content

Error Handling - Custom exception classes and retry logic #124

@Haydart

Description

@Haydart

name: Error Handling - Custom exception classes and retry logic
status: open
created: 2025-09-19T16:02:24Z
updated: 2025-09-19T16:42:04Z
github: #124
depends_on: [127]
parallel: false
conflicts_with: []

Error Handling - Custom exception classes and retry logic

Objective

Implement simple error handling with basic custom exception classes and simple retry logic for Solana blockchain operations.

Acceptance Criteria

Custom Exception Classes

  • SolanaServiceError - Base exception for all service errors
  • RPCError - RPC connection and communication failures
  • ValidationError - Address and data validation failures
  • NetworkError - Network connectivity issues

Simple Retry Logic

  • Basic exponential backoff (max 3 attempts)
  • Retry only for network/RPC errors
  • No retry for validation errors

Technical Requirements

Simple Integration

  • Basic integration with SolanaBlockchainService
  • Wrap RPC calls with basic error handling
  • Simple error messages

Basic Error Context

  • Include basic error information in messages
  • Simple error types for programmatic handling

Implementation Notes

Error Categories

  1. Network Errors - RPC timeouts, connection failures (retry)
  2. Validation Errors - Invalid addresses, bad format (no retry)

Retry Strategy

  • Simple Backoff: 1s, 2s, 4s (max 3 attempts)
  • No Configuration: Fixed retry pattern

No External Integrations

  • Standalone error handling
  • No domain exceptions integration
  • No pump.fun compatibility needed

Files to Create/Modify

  • src/services/solana_exceptions.py (new)
  • Update src/services/solana_blockchain_service.py to use error handling

Dependencies

Testing Requirements

  • Unit tests for exception classes
  • Basic retry logic testing
  • Simple error handling tests

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions